@provoly/hypervisor 0.0.13 → 0.0.15

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 (36) hide show
  1. package/assets/svgs/caret_bottom.svg +3 -0
  2. package/assets/svgs/caret_top.svg +3 -0
  3. package/esm2022/src/lib/event/detail/event-detail.component.mjs +24 -4
  4. package/esm2022/src/lib/event/filters/choice/choice-filter.component.mjs +35 -0
  5. package/esm2022/src/lib/event/filters/date/date-filter.component.mjs +38 -0
  6. package/esm2022/src/lib/event/filters/event-filters.component.mjs +31 -0
  7. package/esm2022/src/lib/event/filters/hvy-unit-filter.class.mjs +13 -0
  8. package/esm2022/src/lib/event/list/event-list.component.mjs +7 -6
  9. package/esm2022/src/lib/event/public-api.mjs +4 -1
  10. package/esm2022/src/lib/general/column-order/column-order.component.mjs +30 -0
  11. package/esm2022/src/lib/general/public-api.mjs +2 -1
  12. package/esm2022/src/lib/hypervisor.module.mjs +21 -5
  13. package/esm2022/src/lib/store/event/event.actions.mjs +3 -1
  14. package/esm2022/src/lib/store/event/event.effects.mjs +2 -1
  15. package/esm2022/src/lib/store/event/event.reducer.mjs +6 -1
  16. package/esm2022/src/lib/store/event/event.selectors.mjs +4 -2
  17. package/esm2022/src/lib/store/event/event.service.mjs +5 -2
  18. package/fesm2022/provoly-hypervisor.mjs +193 -26
  19. package/fesm2022/provoly-hypervisor.mjs.map +1 -1
  20. package/package.json +1 -1
  21. package/src/lib/event/detail/event-detail.component.d.ts +2 -0
  22. package/src/lib/event/filters/choice/choice-filter.component.d.ts +20 -0
  23. package/src/lib/event/filters/date/date-filter.component.d.ts +14 -0
  24. package/src/lib/event/filters/event-filters.component.d.ts +14 -0
  25. package/src/lib/event/filters/hvy-unit-filter.class.d.ts +9 -0
  26. package/src/lib/event/public-api.d.ts +3 -0
  27. package/src/lib/general/column-order/column-order.component.d.ts +16 -0
  28. package/src/lib/general/public-api.d.ts +1 -0
  29. package/src/lib/hypervisor.module.d.ts +13 -9
  30. package/src/lib/store/event/event.actions.d.ts +13 -0
  31. package/src/lib/store/event/event.effects.d.ts +3 -0
  32. package/src/lib/store/event/event.reducer.d.ts +6 -3
  33. package/src/lib/store/event/event.selectors.d.ts +8 -5
  34. package/styles/components/_index.scss +2 -0
  35. package/styles/components/_o-hvy-column-order.scss +26 -0
  36. package/styles/components/_o-hvy-event-filters.scss +12 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@provoly/hypervisor",
3
- "version": "0.0.13",
3
+ "version": "0.0.15",
4
4
  "peerDependencies": {
5
5
  "@angular/cdk": "16.x || 17.x",
6
6
  "@angular/common": "16.x || 17.x",
@@ -25,6 +25,7 @@ export declare class EventDetailComponent extends SubscriptionnerDirective {
25
25
  field: string;
26
26
  code: string;
27
27
  }[][];
28
+ canCloseSome: boolean;
28
29
  set events(events: HypEventDetails[]);
29
30
  set procedure(procedure: HypProcedure);
30
31
  set cancelModifications(evt: any);
@@ -40,6 +41,7 @@ export declare class EventDetailComponent extends SubscriptionnerDirective {
40
41
  description: boolean;
41
42
  address: boolean;
42
43
  source: boolean;
44
+ domain: boolean;
43
45
  eqName: boolean;
44
46
  eqEntity: boolean;
45
47
  startDate: boolean;
@@ -0,0 +1,20 @@
1
+ import { HvyFilterParams, HvyUnitFilterComponent } from '../hvy-unit-filter.class';
2
+ import { Store } from '@ngrx/store';
3
+ import * as i0 from "@angular/core";
4
+ export type HvyChoiceFilter = {
5
+ key: string;
6
+ children?: {
7
+ key: string;
8
+ }[];
9
+ }[];
10
+ export declare class ChoiceFilterComponent extends HvyUnitFilterComponent {
11
+ private store;
12
+ prop: string;
13
+ value: string[];
14
+ choices: HvyChoiceFilter;
15
+ constructor(store: Store);
16
+ getParams(): HvyFilterParams;
17
+ reset(): void;
18
+ static ɵfac: i0.ɵɵFactoryDeclaration<ChoiceFilterComponent, never>;
19
+ static ɵcmp: i0.ɵɵComponentDeclaration<ChoiceFilterComponent, "hvy-choice-filter", never, { "prop": { "alias": "prop"; "required": false; }; "choices": { "alias": "choices"; "required": false; }; }, {}, never, never, false, never>;
20
+ }
@@ -0,0 +1,14 @@
1
+ import { HvyFilterParams, HvyUnitFilterComponent } from '../hvy-unit-filter.class';
2
+ import { Store } from '@ngrx/store';
3
+ import * as i0 from "@angular/core";
4
+ export declare class DateFilterComponent extends HvyUnitFilterComponent {
5
+ private store;
6
+ prop: string;
7
+ value: string;
8
+ constructor(store: Store);
9
+ getParams(): HvyFilterParams;
10
+ reset(): void;
11
+ triggerChange($event: Event): void;
12
+ static ɵfac: i0.ɵɵFactoryDeclaration<DateFilterComponent, never>;
13
+ static ɵcmp: i0.ɵɵComponentDeclaration<DateFilterComponent, "hvy-date-filter", never, { "prop": { "alias": "prop"; "required": false; }; }, {}, never, never, false, never>;
14
+ }
@@ -0,0 +1,14 @@
1
+ import { QueryList } from '@angular/core';
2
+ import { SubscriptionnerDirective } from '@provoly/dashboard';
3
+ import { HvyUnitFilterComponent } from './hvy-unit-filter.class';
4
+ import { Store } from '@ngrx/store';
5
+ import * as i0 from "@angular/core";
6
+ export declare class EventFiltersComponent extends SubscriptionnerDirective {
7
+ private store;
8
+ filters: QueryList<HvyUnitFilterComponent>;
9
+ constructor(store: Store);
10
+ filter(): void;
11
+ reset(): void;
12
+ static ɵfac: i0.ɵɵFactoryDeclaration<EventFiltersComponent, never>;
13
+ static ɵcmp: i0.ɵɵComponentDeclaration<EventFiltersComponent, "hvy-event-filters", never, {}, {}, ["filters"], ["*"], false, never>;
14
+ }
@@ -0,0 +1,9 @@
1
+ import { SubscriptionnerDirective } from '@provoly/dashboard';
2
+ export type HvyFilterParams = {
3
+ [key: string]: string[];
4
+ };
5
+ export declare class HvyUnitFilterComponent extends SubscriptionnerDirective {
6
+ constructor();
7
+ getParams(): HvyFilterParams;
8
+ reset(): void;
9
+ }
@@ -1,2 +1,5 @@
1
1
  export * from './detail/event-detail.component';
2
2
  export * from './list/event-list.component';
3
+ export * from './filters/event-filters.component';
4
+ export * from './filters/date/date-filter.component';
5
+ export * from './filters/choice/choice-filter.component';
@@ -0,0 +1,16 @@
1
+ import { Store } from '@ngrx/store';
2
+ import { SubscriptionnerDirective } from '@provoly/dashboard';
3
+ import * as i0 from "@angular/core";
4
+ export declare class ColumnOrderComponent extends SubscriptionnerDirective {
5
+ private store;
6
+ field: string;
7
+ sortValue: {
8
+ field: string;
9
+ order: string;
10
+ } | undefined;
11
+ constructor(store: Store);
12
+ sort(order: string): void;
13
+ isActive(order: string): boolean;
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<ColumnOrderComponent, never>;
15
+ static ɵcmp: i0.ɵɵComponentDeclaration<ColumnOrderComponent, "hvy-column-order", never, { "field": { "alias": "field"; "required": false; }; }, {}, never, ["*"], false, never>;
16
+ }
@@ -7,3 +7,4 @@ export * from './for-datetime-local-pipe/for-datetime-local.pipe';
7
7
  export * from './icon-display/icon-display.component';
8
8
  export * from './status-display/status-display.component';
9
9
  export * from './progress-display/progress-display.component';
10
+ export * from './column-order/column-order.component';
@@ -12,14 +12,18 @@ import * as i7 from "./general/icon-pipe/event-icon.pipe";
12
12
  import * as i8 from "./general/for-datetime-local-pipe/for-datetime-local.pipe";
13
13
  import * as i9 from "./general/status-display/status-display.component";
14
14
  import * as i10 from "./general/progress-display/progress-display.component";
15
- import * as i11 from "@ngrx/store";
16
- import * as i12 from "@ngrx/effects";
17
- import * as i13 from "@angular/common";
18
- import * as i14 from "@provoly/dashboard";
19
- import * as i15 from "@provoly/dashboard/components/checkbox";
20
- import * as i16 from "@angular/forms";
21
- import * as i17 from "@angular/router";
22
- import * as i18 from "@provoly/dashboard/components/sinceDate";
15
+ import * as i11 from "./general/column-order/column-order.component";
16
+ import * as i12 from "./event/filters/event-filters.component";
17
+ import * as i13 from "./event/filters/date/date-filter.component";
18
+ import * as i14 from "./event/filters/choice/choice-filter.component";
19
+ import * as i15 from "@ngrx/store";
20
+ import * as i16 from "@ngrx/effects";
21
+ import * as i17 from "@angular/common";
22
+ import * as i18 from "@provoly/dashboard";
23
+ import * as i19 from "@provoly/dashboard/components/checkbox";
24
+ import * as i20 from "@angular/forms";
25
+ import * as i21 from "@angular/router";
26
+ import * as i22 from "@provoly/dashboard/components/sinceDate";
23
27
  export declare class PvyHypervisorModule {
24
28
  private baseConfig;
25
29
  private store;
@@ -31,6 +35,6 @@ export declare class PvyHypervisorModule {
31
35
  url: string;
32
36
  }, store: Store<any>, i18nService: PryI18nService);
33
37
  static ɵfac: i0.ɵɵFactoryDeclaration<PvyHypervisorModule, never>;
34
- static ɵmod: i0.ɵɵNgModuleDeclaration<PvyHypervisorModule, [typeof i1.EventDetailComponent, typeof i2.EventListComponent, typeof i3.IconDisplayComponent, typeof i4.EventSummaryItemComponent, typeof i5.EventSummaryListComponent, typeof i6.EventSummaryPageComponent, typeof i7.EventIconPipe, typeof i8.ForDatetimeLocalPipe, typeof i9.StatusDisplayComponent, typeof i10.ProgressDisplayComponent], [typeof i11.StoreFeatureModule, typeof i11.StoreFeatureModule, typeof i11.StoreFeatureModule, typeof i12.EffectsFeatureModule, typeof i13.NgForOf, typeof i13.AsyncPipe, typeof i14.PryI18nModule, typeof i14.PryCoreModule, typeof i13.AsyncPipe, typeof i14.PryCoreModule, typeof i13.NgStyle, typeof i15.PryCheckboxModule, typeof i16.FormsModule, typeof i17.RouterLink, typeof i18.PrySinceDateModule, typeof i13.DatePipe, typeof i14.PryIconModule, typeof i13.KeyValuePipe, typeof i14.PrySelectModule, typeof i16.FormsModule, typeof i13.JsonPipe, typeof i14.PryDatePickerModule, typeof i14.PryI18nModule, typeof i14.PryIconModule], [typeof i1.EventDetailComponent, typeof i2.EventListComponent, typeof i3.IconDisplayComponent, typeof i4.EventSummaryItemComponent, typeof i5.EventSummaryListComponent, typeof i6.EventSummaryPageComponent, typeof i7.EventIconPipe, typeof i8.ForDatetimeLocalPipe, typeof i9.StatusDisplayComponent, typeof i10.ProgressDisplayComponent]>;
38
+ static ɵmod: i0.ɵɵNgModuleDeclaration<PvyHypervisorModule, [typeof i1.EventDetailComponent, typeof i2.EventListComponent, typeof i3.IconDisplayComponent, typeof i4.EventSummaryItemComponent, typeof i5.EventSummaryListComponent, typeof i6.EventSummaryPageComponent, typeof i7.EventIconPipe, typeof i8.ForDatetimeLocalPipe, typeof i9.StatusDisplayComponent, typeof i10.ProgressDisplayComponent, typeof i11.ColumnOrderComponent, typeof i12.EventFiltersComponent, typeof i13.DateFilterComponent, typeof i14.ChoiceFilterComponent], [typeof i15.StoreFeatureModule, typeof i15.StoreFeatureModule, typeof i15.StoreFeatureModule, typeof i16.EffectsFeatureModule, typeof i17.NgForOf, typeof i17.AsyncPipe, typeof i18.PryI18nModule, typeof i18.PryCoreModule, typeof i17.AsyncPipe, typeof i18.PryCoreModule, typeof i17.NgStyle, typeof i19.PryCheckboxModule, typeof i20.FormsModule, typeof i21.RouterLink, typeof i22.PrySinceDateModule, typeof i17.DatePipe, typeof i18.PryIconModule, typeof i17.KeyValuePipe, typeof i18.PrySelectModule, typeof i20.FormsModule, typeof i17.JsonPipe, typeof i18.PryDatePickerModule, typeof i18.PryI18nModule, typeof i18.PryIconModule], [typeof i1.EventDetailComponent, typeof i2.EventListComponent, typeof i3.IconDisplayComponent, typeof i4.EventSummaryItemComponent, typeof i5.EventSummaryListComponent, typeof i6.EventSummaryPageComponent, typeof i7.EventIconPipe, typeof i8.ForDatetimeLocalPipe, typeof i9.StatusDisplayComponent, typeof i10.ProgressDisplayComponent, typeof i11.ColumnOrderComponent, typeof i12.EventFiltersComponent, typeof i13.DateFilterComponent, typeof i14.ChoiceFilterComponent]>;
35
39
  static ɵinj: i0.ɵɵInjectorDeclaration<PvyHypervisorModule>;
36
40
  }
@@ -1,5 +1,6 @@
1
1
  import { HypEventDetails } from '../../model/event/hyp-event-detail.interface';
2
2
  import { HypProcedure } from '../../model/hyp-procedure.interface';
3
+ import { HvyFilterParams } from '../../event/filters/hvy-unit-filter.class';
3
4
  export declare const EventActions: {
4
5
  load: import("@ngrx/store").ActionCreator<"[Event] Load Events", (props: {
5
6
  next?: boolean | undefined;
@@ -93,4 +94,16 @@ export declare const EventActions: {
93
94
  }) => {
94
95
  error: string;
95
96
  } & import("@ngrx/store/src/models").TypedAction<"[Event] Close failure">>;
97
+ sort: import("@ngrx/store").ActionCreator<"[Event] set log event sorting", (props: {
98
+ field: string;
99
+ order: string;
100
+ }) => {
101
+ field: string;
102
+ order: string;
103
+ } & import("@ngrx/store/src/models").TypedAction<"[Event] set log event sorting">>;
104
+ setFilters: import("@ngrx/store").ActionCreator<"[Event] set filters", (props: {
105
+ filters: HvyFilterParams;
106
+ }) => {
107
+ filters: HvyFilterParams;
108
+ } & import("@ngrx/store/src/models").TypedAction<"[Event] set filters">>;
96
109
  };
@@ -39,6 +39,9 @@ export declare class EventEffects {
39
39
  close$: import("rxjs").Observable<import("@ngrx/store/src/models").TypedAction<"[Event] Close success"> | ({
40
40
  error: string;
41
41
  } & import("@ngrx/store/src/models").TypedAction<"[Event] Close failure">)> & import("@ngrx/effects").CreateEffectMetadata;
42
+ sort$: import("rxjs").Observable<{
43
+ next?: boolean | undefined;
44
+ } & import("@ngrx/store/src/models").TypedAction<"[Event] Load Events">> & import("@ngrx/effects").CreateEffectMetadata;
42
45
  constructor(actions$: Actions, eventService: EventService, store: Store);
43
46
  static ɵfac: i0.ɵɵFactoryDeclaration<EventEffects, never>;
44
47
  static ɵprov: i0.ɵɵInjectableDeclaration<EventEffects>;
@@ -1,19 +1,22 @@
1
1
  import { Action } from '@ngrx/store';
2
2
  import { HypEventDetails } from '../../model/event/hyp-event-detail.interface';
3
3
  import { HypProcedure } from '../../model/hyp-procedure.interface';
4
+ import { HvyFilterParams } from '../../event/filters/hvy-unit-filter.class';
4
5
  export declare const eventFeatureKey = "@hvy/event";
5
6
  export interface EventState {
6
7
  events: HypEventDetails[];
7
8
  noMoreEvents: boolean;
8
9
  loading: boolean;
9
- filters: {
10
- [key: string]: string[];
11
- };
10
+ filters: HvyFilterParams;
12
11
  selectedIds: string[];
13
12
  details: {
14
13
  event?: HypEventDetails;
15
14
  procedure?: HypProcedure;
16
15
  };
16
+ sort?: {
17
+ field: string;
18
+ order: string;
19
+ };
17
20
  }
18
21
  export declare const eventInitialState: EventState;
19
22
  export declare function eventReducer(state: EventState, action: Action): EventState;
@@ -4,11 +4,7 @@ export declare const EventSelectors: {
4
4
  events: import("@ngrx/store").MemoizedSelector<object, import("@provoly/hypervisor").HypEventDetails[], (s1: EventState) => import("@provoly/hypervisor").HypEventDetails[]>;
5
5
  selectedIds: import("@ngrx/store").MemoizedSelector<object, string[], (s1: EventState) => string[]>;
6
6
  loading: import("@ngrx/store").MemoizedSelector<object, boolean, (s1: EventState) => boolean>;
7
- filters: import("@ngrx/store").MemoizedSelector<object, {
8
- [key: string]: string[];
9
- }, (s1: EventState) => {
10
- [key: string]: string[];
11
- }>;
7
+ filters: import("@ngrx/store").MemoizedSelector<object, import("../../event/filters/hvy-unit-filter.class").HvyFilterParams, (s1: EventState) => import("../../event/filters/hvy-unit-filter.class").HvyFilterParams>;
12
8
  details: import("@ngrx/store").MemoizedSelector<object, {
13
9
  event?: import("@provoly/hypervisor").HypEventDetails | undefined;
14
10
  procedure?: import("@provoly/hypervisor").HypProcedure | undefined;
@@ -17,4 +13,11 @@ export declare const EventSelectors: {
17
13
  procedure?: import("@provoly/hypervisor").HypProcedure | undefined;
18
14
  }>;
19
15
  noMoreEvents: import("@ngrx/store").MemoizedSelector<object, boolean, (s1: EventState) => boolean>;
16
+ sort: import("@ngrx/store").MemoizedSelector<object, {
17
+ field: string;
18
+ order: string;
19
+ } | undefined, (s1: EventState) => {
20
+ field: string;
21
+ order: string;
22
+ } | undefined>;
20
23
  };
@@ -10,3 +10,5 @@
10
10
  @use "./o-hvy-event-summary-page" as *;
11
11
  @use "./o-hvy-events-table" as *;
12
12
  @use "./o-progressbar" as *;
13
+ @use "./o-hvy-column-order" as *;
14
+ @use "./o-hvy-event-filters" as *;
@@ -0,0 +1,26 @@
1
+ @use 'node_modules/@provoly/dashboard/styles/abstracts' as *;
2
+ @use 'node_modules/@provoly/dashboard/styles-theme/abstracts-theme/variables.theme' as *;
3
+
4
+ .o-hvy-column-order {
5
+ display: flex;
6
+ flex-direction: row;
7
+ align-items: center;
8
+ gap: toRem(5);
9
+
10
+ &__chevrons {
11
+ display: flex;
12
+ flex-direction: column;
13
+ align-items: center;
14
+ margin-top: toRem(-8);
15
+
16
+ .a-icon {
17
+ background-color: themed($theme-map, 'color', 'grey', 200);
18
+ }
19
+
20
+ .-active {
21
+ .a-icon {
22
+ background-color: themed($theme-map, 'color', 'accent', 100);
23
+ }
24
+ }
25
+ }
26
+ }
@@ -0,0 +1,12 @@
1
+ @use 'node_modules/@provoly/dashboard/styles/abstracts' as *;
2
+ @use 'node_modules/@provoly/dashboard/styles-theme/abstracts-theme/variables.theme' as *;
3
+
4
+ .o-hvy-event-filters {
5
+ display: flex;
6
+ flex-direction: row;
7
+ gap: toRem(10);
8
+
9
+ &__buttons {
10
+ margin-left: auto;
11
+ }
12
+ }