@yuuvis/client-framework 2.14.0 → 2.16.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.
Files changed (31) hide show
  1. package/common/lib/common.module.d.ts +4 -2
  2. package/common/lib/components/index.d.ts +1 -0
  3. package/common/lib/components/scroll-buttons/scroll-buttons.component.d.ts +25 -0
  4. package/common/lib/directives/index.d.ts +1 -0
  5. package/common/lib/directives/scroll-buttons.directive.d.ts +20 -0
  6. package/fesm2022/yuuvis-client-framework-autocomplete.mjs +13 -4
  7. package/fesm2022/yuuvis-client-framework-autocomplete.mjs.map +1 -1
  8. package/fesm2022/yuuvis-client-framework-common.mjs +249 -7
  9. package/fesm2022/yuuvis-client-framework-common.mjs.map +1 -1
  10. package/fesm2022/yuuvis-client-framework-forms.mjs +4 -4
  11. package/fesm2022/yuuvis-client-framework-forms.mjs.map +1 -1
  12. package/fesm2022/yuuvis-client-framework-object-preview.mjs +1 -1
  13. package/fesm2022/yuuvis-client-framework-object-preview.mjs.map +1 -1
  14. package/fesm2022/yuuvis-client-framework-object-relationship.mjs +1 -1
  15. package/fesm2022/yuuvis-client-framework-object-relationship.mjs.map +1 -1
  16. package/fesm2022/yuuvis-client-framework-popout.mjs +9 -3
  17. package/fesm2022/yuuvis-client-framework-popout.mjs.map +1 -1
  18. package/fesm2022/yuuvis-client-framework-split-view.mjs +107 -8
  19. package/fesm2022/yuuvis-client-framework-split-view.mjs.map +1 -1
  20. package/fesm2022/yuuvis-client-framework-widget-grid.mjs +7 -1
  21. package/fesm2022/yuuvis-client-framework-widget-grid.mjs.map +1 -1
  22. package/lib/assets/i18n/de.json +2 -0
  23. package/lib/assets/i18n/en.json +2 -0
  24. package/package.json +5 -5
  25. package/popout/index.d.ts +1 -0
  26. package/popout/lib/fullscreen.directive.d.ts +4 -0
  27. package/popout/lib/popout.module.d.ts +2 -1
  28. package/split-view/lib/split-view.component.d.ts +91 -9
  29. package/widget-grid/lib/widget-grid-workspaces/widget-grid-workspaces.interface.d.ts +1 -1
  30. package/widget-grid/lib/widget-grid.component.d.ts +1 -1
  31. package/widget-grid/lib/widget-grid.interface.d.ts +2 -1
@@ -1,27 +1,54 @@
1
1
  import { AfterViewInit } from '@angular/core';
2
- import { SplitComponent, SplitDirection } from 'angular-split';
2
+ import { SplitAreaSize, SplitComponent, SplitDirection } from 'angular-split';
3
3
  import { SplitAreaDirective } from './split-area.directive';
4
4
  import { SplitViewLayoutSettings, SplitViewOutputData } from './split-view.interface';
5
5
  import * as i0 from "@angular/core";
6
6
  /**
7
7
  * Component for creating a split view with resizable areas.
8
8
  *
9
+ * Each area is defined using the `yuvSplitArea` directive on an `ng-template`.
10
+ * Areas can be resized by dragging the gutter between them.
11
+ *
12
+ * ### Basic usage
13
+ * ```html
14
+ * <yuv-split-view>
15
+ * <ng-template yuvSplitArea [size]="20">Aside</ng-template>
16
+ * <ng-template yuvSplitArea [size]="80">Main</ng-template>
17
+ * </yuv-split-view>
18
+ * ```
19
+ *
20
+ * ### Collapsible areas
21
+ * Areas can be shown, hidden, or toggled programmatically. Use a template
22
+ * reference variable to call the visibility methods from the template:
23
+ *
9
24
  * ```html
10
- * <yuv-split-view>
11
- * <ng-template yuvSplitArea [size]="20">Aside area</ng-template>
12
- * <ng-template yuvSplitArea [size]="80">Main area</ng-template>
13
- * </yuv-split-view>
25
+ * <yuv-split-view #sv>
26
+ * <ng-template yuvSplitArea [size]="25">
27
+ * <button (click)="sv.hideArea(0)">Collapse</button>
28
+ * Left pane
29
+ * </ng-template>
30
+ * <ng-template yuvSplitArea [size]="75">
31
+ * <button (click)="sv.showArea(0)">Expand left</button>
32
+ * Main pane
33
+ * </ng-template>
34
+ * </yuv-split-view>
14
35
  * ```
15
- * If you set a `layoutSettingsID` it will be used to store the state of
16
- * the split view (area sizes and visibility) in localStorage everytime it
17
- * changes. The component will then also load and apply that state once the
18
- * component is loaded.
19
36
  *
37
+ * ### Persisting layout state
38
+ * Set `layoutSettingsID` to persist area sizes and visibility to
39
+ * localStorage. The saved state is automatically restored on init.
40
+ *
41
+ * ```html
42
+ * <yuv-split-view [layoutSettingsID]="'my-layout'">
43
+ * ...
44
+ * </yuv-split-view>
45
+ * ```
20
46
  */
21
47
  export declare class SplitViewComponent implements AfterViewInit {
22
48
  #private;
23
49
  splitAreas: import("@angular/core").Signal<readonly SplitAreaDirective[]>;
24
50
  asSplitComponent: import("@angular/core").Signal<SplitComponent>;
51
+ splitAreaSizes: SplitAreaSize[];
25
52
  /**
26
53
  * The split views direction. Could be 'horizontal' or 'vertical'. Defaults to 'horizontal'.
27
54
  */
@@ -32,6 +59,9 @@ export declare class SplitViewComponent implements AfterViewInit {
32
59
  * Size of the gutter in Pixel (defaults to 16).
33
60
  */
34
61
  gutterSize: import("@angular/core").InputSignal<number>;
62
+ /**
63
+ * If true, the gutter can only be moved in steps of 1%.
64
+ */
35
65
  restrictMove: import("@angular/core").InputSignal<boolean>;
36
66
  /**
37
67
  * Disable the dragging feature (remove cursor/image on gutters).
@@ -70,6 +100,58 @@ export declare class SplitViewComponent implements AfterViewInit {
70
100
  dragging: import("@angular/core").WritableSignal<boolean>;
71
101
  onDragStart(e: SplitViewOutputData): void;
72
102
  onDragEnd(e: SplitViewOutputData): void;
103
+ /**
104
+ * Show a previously hidden split area, restoring it to its last known size.
105
+ *
106
+ * ```html
107
+ * <button (click)="sv.showArea(0)">Show left pane</button>
108
+ * ```
109
+ * @param index Zero-based index of the split area to show
110
+ */
111
+ showArea(index: number): void;
112
+ /**
113
+ * Hide a split area by collapsing it to zero width/height. The adjacent
114
+ * areas will expand to fill the freed space.
115
+ *
116
+ * ```html
117
+ * <button (click)="sv.hideArea(0)">Hide left pane</button>
118
+ * ```
119
+ * @param index Zero-based index of the split area to hide
120
+ */
121
+ hideArea(index: number): void;
122
+ /**
123
+ * Toggle the visibility of a split area. If the area is currently visible
124
+ * it will be collapsed; if it is hidden it will be restored.
125
+ *
126
+ * ```html
127
+ * <button (click)="sv.toggleArea(0)">Toggle left pane</button>
128
+ * ```
129
+ * @param index Zero-based index of the split area to toggle
130
+ */
131
+ toggleArea(index: number): void;
132
+ /**
133
+ * Returns whether a split area is currently visible. Useful for
134
+ * conditionally rendering expand/collapse buttons in the template.
135
+ *
136
+ * ```html
137
+ * @if (!sv.isAreaVisible(0)) {
138
+ * <button (click)="sv.showArea(0)">Expand left</button>
139
+ * }
140
+ * ```
141
+ * @param index Zero-based index of the split area to check
142
+ * @returns `true` if the area is visible, `false` if hidden
143
+ */
144
+ isAreaVisible(index: number): boolean;
145
+ /** @deprecated Use `showArea()` / `hideArea()` instead */
146
+ splitAreaSetVisibility(index: number, visible: boolean): void;
147
+ /** @deprecated Use `toggleArea()` instead */
148
+ splitAreaToggleVisibility(index: number): void;
149
+ /**
150
+ * Programmatically apply layout settings (area sizes, visibility, disabled state).
151
+ * This is called automatically on init when `layoutSettingsID` is set, but can
152
+ * also be used to restore a specific layout configuration at any time.
153
+ * @param settings The layout settings to apply
154
+ */
73
155
  applyLayoutSettings(settings: SplitViewLayoutSettings): void;
74
156
  ngAfterViewInit(): void;
75
157
  static ɵfac: i0.ɵɵFactoryDeclaration<SplitViewComponent, never>;
@@ -10,7 +10,7 @@ export interface WidgetGridWorkspace {
10
10
  }
11
11
  export interface WidgetGridWorkspaceConfig {
12
12
  currentWorkspace?: string;
13
- workspaces: Array<WidgetGridWorkspace>;
13
+ workspaces: WidgetGridWorkspace[];
14
14
  }
15
15
  export interface WidgetGridWorkspaceOptions {
16
16
  gridConfig?: Partial<WidgetGridConfig>;
@@ -7,7 +7,7 @@ export declare class YuvWidgetGridComponent {
7
7
  gridsterItems: import("@angular/core").Signal<GridsterItemComponent>;
8
8
  widgetPicker: import("@angular/core").Signal<TemplateRef<any>>;
9
9
  options: GridsterConfig;
10
- gridConfig: import("@angular/core").InputSignal<WidgetGridConfig | undefined>;
10
+ gridConfig: import("@angular/core").InputSignal<Partial<WidgetGridConfig> | undefined>;
11
11
  _editMode: import("@angular/core").WritableSignal<boolean>;
12
12
  /**
13
13
  * Whether or not to enable edit mode. In edit mode controls
@@ -1,6 +1,6 @@
1
1
  import { InputSignal, OutputEmitterRef, Type } from '@angular/core';
2
2
  import { FormControlStatus } from '@angular/forms';
3
- import { GridsterItem } from 'angular-gridster2';
3
+ import { GridsterItem, GridType } from 'angular-gridster2';
4
4
  import { AttributesMap } from 'ng-dynamic-component';
5
5
  export interface GridWidget<T> {
6
6
  id: string;
@@ -43,6 +43,7 @@ export interface WidgetGridConfig {
43
43
  gap?: number;
44
44
  newItemWidth?: number;
45
45
  newItemHeight?: number;
46
+ gridType: GridType;
46
47
  }
47
48
  export interface WidgetPickerOptions {
48
49
  pickerData?: WidgetPickerData;