ca-components 0.0.89 → 0.0.91

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 (103) hide show
  1. package/esm2022/lib/components/ca-activity-log-list/ca-activity-log-list.component.mjs +84 -9
  2. package/esm2022/lib/components/ca-activity-log-list/config/activity-log-search-filter.config.mjs +16 -0
  3. package/esm2022/lib/components/ca-activity-log-list/config/index.mjs +2 -0
  4. package/esm2022/lib/components/ca-activity-log-list/models/company-user-avatar-file.model.mjs +2 -0
  5. package/esm2022/lib/components/ca-activity-log-list/models/company-user.model.mjs +1 -1
  6. package/esm2022/lib/components/ca-activity-log-list/models/index.mjs +2 -1
  7. package/esm2022/lib/components/ca-activity-log-list/utils/pipes/company-user-name-transform.pipe.mjs +20 -0
  8. package/esm2022/lib/components/ca-activity-log-list/utils/pipes/index.mjs +2 -1
  9. package/esm2022/lib/components/ca-chart/ca-chart.component.mjs +57 -12
  10. package/esm2022/lib/components/ca-chart/config/ca-base-chart-dataset.config.mjs +3 -3
  11. package/esm2022/lib/components/ca-chart/config/index.mjs +1 -1
  12. package/esm2022/lib/components/ca-chart/enums/chart-colors-enum.mjs +3 -1
  13. package/esm2022/lib/components/ca-chart/enums/chart-event-properties-enum.mjs +5 -0
  14. package/esm2022/lib/components/ca-chart/enums/chart-event-types-enum.mjs +5 -0
  15. package/esm2022/lib/components/ca-chart/enums/chart-plugin-ids-enum.mjs +6 -0
  16. package/esm2022/lib/components/ca-chart/enums/chart-types-enum.mjs +1 -1
  17. package/esm2022/lib/components/ca-chart/enums/cubic-interpolation-mode-enum.mjs +1 -1
  18. package/esm2022/lib/components/ca-chart/enums/index.mjs +4 -1
  19. package/esm2022/lib/components/ca-chart/models/chart-base-dataset.model.mjs +1 -1
  20. package/esm2022/lib/components/ca-chart/models/chart-data.model.mjs +1 -1
  21. package/esm2022/lib/components/ca-chart/models/chart-line-dataset.model.mjs +1 -1
  22. package/esm2022/lib/components/ca-chart/models/index.mjs +1 -1
  23. package/esm2022/lib/components/ca-chart/utils/guards/chart-type.guard.mjs +2 -2
  24. package/esm2022/lib/components/ca-chart/utils/guards/index.mjs +2 -2
  25. package/esm2022/lib/components/ca-chart/utils/helpers/chart.helper.mjs +55 -9
  26. package/esm2022/lib/components/ca-chart/utils/helpers/index.mjs +2 -2
  27. package/esm2022/lib/components/ca-filters/components/ca-user-filter/models/index.mjs +3 -0
  28. package/esm2022/lib/components/ca-right-side-panel/ca-right-side-panel.component.mjs +46 -12
  29. package/esm2022/lib/components/ca-right-side-panel/components/ca-right-side-panel-menu/ca-right-side-panel-menu.component.mjs +10 -7
  30. package/esm2022/lib/components/ca-right-side-panel/components/ca-right-side-panel-top-bar/ca-right-side-panel-top-bar.component.mjs +208 -22
  31. package/esm2022/lib/components/ca-right-side-panel/config/ca-right-side-panel.config.mjs +2 -2
  32. package/esm2022/lib/components/ca-right-side-panel/enums/activity-log-sort-type.enum.mjs +6 -0
  33. package/esm2022/lib/components/ca-right-side-panel/enums/filter-type.enum.mjs +8 -0
  34. package/esm2022/lib/components/ca-right-side-panel/enums/index.mjs +5 -1
  35. package/esm2022/lib/components/ca-right-side-panel/enums/modules-filter-item-label.enum.mjs +5 -0
  36. package/esm2022/lib/components/ca-right-side-panel/enums/right-side-panel-current-tab.enum.mjs +1 -1
  37. package/esm2022/lib/components/ca-right-side-panel/enums/selected-module.enum.mjs +2 -2
  38. package/esm2022/lib/components/ca-right-side-panel/enums/time-filter-type.enum.mjs +11 -0
  39. package/esm2022/lib/components/ca-right-side-panel/models/action-filter/action-filter-input-data.model.mjs +2 -0
  40. package/esm2022/lib/components/ca-right-side-panel/models/activity-log-filter-params.model.mjs +2 -0
  41. package/esm2022/lib/components/ca-right-side-panel/models/activity-log-filter.model.mjs +2 -0
  42. package/esm2022/lib/components/ca-right-side-panel/models/index.mjs +10 -1
  43. package/esm2022/lib/components/ca-right-side-panel/models/module-filter/module-filter-activity-log.model.mjs +2 -0
  44. package/esm2022/lib/components/ca-right-side-panel/models/module-filter/module-filter-input-data.model.mjs +2 -0
  45. package/esm2022/lib/components/ca-right-side-panel/models/navigation-item.model.mjs +1 -1
  46. package/esm2022/lib/components/ca-right-side-panel/models/time-filter/time-filter-event.model.mjs +2 -0
  47. package/esm2022/lib/components/ca-right-side-panel/models/user-filter/user-filter-avatar-file.model.mjs +2 -0
  48. package/esm2022/lib/components/ca-right-side-panel/models/user-filter/user-filter-data.model.mjs +2 -0
  49. package/esm2022/lib/components/ca-right-side-panel/models/user-filter/user-filter-input-data.model.mjs +2 -0
  50. package/esm2022/lib/components/ca-right-side-panel/utils/svg-routes/index.mjs +2 -0
  51. package/esm2022/lib/components/ca-right-side-panel/utils/svg-routes/right-side-panel-top-bar-svg.routes.mjs +10 -0
  52. package/fesm2022/ca-components.mjs +546 -79
  53. package/fesm2022/ca-components.mjs.map +1 -1
  54. package/lib/components/ca-activity-log-list/ca-activity-log-list.component.d.ts +28 -4
  55. package/lib/components/ca-activity-log-list/config/activity-log-search-filter.config.d.ts +5 -0
  56. package/lib/components/ca-activity-log-list/config/index.d.ts +1 -0
  57. package/lib/components/ca-activity-log-list/models/company-user-avatar-file.model.d.ts +9 -0
  58. package/lib/components/ca-activity-log-list/models/company-user.model.d.ts +2 -1
  59. package/lib/components/ca-activity-log-list/models/index.d.ts +1 -0
  60. package/lib/components/ca-activity-log-list/utils/pipes/company-user-name-transform.pipe.d.ts +7 -0
  61. package/lib/components/ca-activity-log-list/utils/pipes/index.d.ts +1 -0
  62. package/lib/components/ca-chart/ca-chart.component.d.ts +3 -1
  63. package/lib/components/ca-chart/config/ca-base-chart-dataset.config.d.ts +1 -1
  64. package/lib/components/ca-chart/enums/chart-colors-enum.d.ts +3 -1
  65. package/lib/components/ca-chart/enums/chart-event-properties-enum.d.ts +3 -0
  66. package/lib/components/ca-chart/enums/chart-event-types-enum.d.ts +3 -0
  67. package/lib/components/ca-chart/enums/chart-plugin-ids-enum.d.ts +4 -0
  68. package/lib/components/ca-chart/enums/index.d.ts +3 -0
  69. package/lib/components/ca-chart/models/chart-base-dataset.model.d.ts +2 -1
  70. package/lib/components/ca-chart/models/chart-data.model.d.ts +1 -1
  71. package/lib/components/ca-chart/models/chart-line-dataset.model.d.ts +5 -1
  72. package/lib/components/ca-chart/utils/guards/chart-type.guard.d.ts +1 -1
  73. package/lib/components/ca-chart/utils/guards/index.d.ts +1 -1
  74. package/lib/components/ca-chart/utils/helpers/chart.helper.d.ts +7 -1
  75. package/lib/components/ca-chart/utils/helpers/index.d.ts +1 -1
  76. package/lib/components/ca-filters/ca-filter.component.d.ts +2 -2
  77. package/lib/components/ca-filters/components/ca-user-filter/models/index.d.ts +2 -0
  78. package/lib/components/ca-right-side-panel/ca-right-side-panel.component.d.ts +11 -5
  79. package/lib/components/ca-right-side-panel/components/ca-right-side-panel-menu/ca-right-side-panel-menu.component.d.ts +2 -1
  80. package/lib/components/ca-right-side-panel/components/ca-right-side-panel-top-bar/ca-right-side-panel-top-bar.component.d.ts +37 -8
  81. package/lib/components/ca-right-side-panel/enums/activity-log-sort-type.enum.d.ts +4 -0
  82. package/lib/components/ca-right-side-panel/enums/filter-type.enum.d.ts +6 -0
  83. package/lib/components/ca-right-side-panel/enums/index.d.ts +4 -0
  84. package/lib/components/ca-right-side-panel/enums/modules-filter-item-label.enum.d.ts +3 -0
  85. package/lib/components/ca-right-side-panel/enums/selected-module.enum.d.ts +1 -1
  86. package/lib/components/ca-right-side-panel/enums/time-filter-type.enum.d.ts +9 -0
  87. package/lib/components/ca-right-side-panel/models/action-filter/action-filter-input-data.model.d.ts +7 -0
  88. package/lib/components/ca-right-side-panel/models/activity-log-filter-params.model.d.ts +11 -0
  89. package/lib/components/ca-right-side-panel/models/activity-log-filter.model.d.ts +6 -0
  90. package/lib/components/ca-right-side-panel/models/index.d.ts +9 -0
  91. package/lib/components/ca-right-side-panel/models/module-filter/module-filter-activity-log.model.d.ts +6 -0
  92. package/lib/components/ca-right-side-panel/models/module-filter/module-filter-input-data.model.d.ts +5 -0
  93. package/lib/components/ca-right-side-panel/models/navigation-item.model.d.ts +1 -1
  94. package/lib/components/ca-right-side-panel/models/time-filter/time-filter-event.model.d.ts +8 -0
  95. package/lib/components/ca-right-side-panel/models/user-filter/user-filter-avatar-file.model.d.ts +9 -0
  96. package/lib/components/ca-right-side-panel/models/user-filter/user-filter-data.model.d.ts +7 -0
  97. package/lib/components/ca-right-side-panel/models/user-filter/user-filter-input-data.model.d.ts +7 -0
  98. package/lib/components/ca-right-side-panel/utils/svg-routes/index.d.ts +1 -0
  99. package/lib/components/ca-right-side-panel/utils/svg-routes/right-side-panel-top-bar-svg.routes.d.ts +9 -0
  100. package/package.json +2 -3
  101. package/src/assets/ca-components/svg/common/ic_action.svg +3 -0
  102. package/src/assets/ca-components/svg/common/ic_module.svg +5 -0
  103. package/src/assets/ca-components/svg/right-side-panel/ic_reload_refresh.svg +3 -0
@@ -1,13 +1,37 @@
1
- import { OnInit } from '@angular/core';
1
+ import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
2
+ import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';
2
3
  import { ActivityLogItem } from './models';
3
4
  import { RightSidePanelCurrentTab } from '../ca-right-side-panel/enums';
5
+ import { ICaInput } from '../ca-input/config';
4
6
  import * as i0 from "@angular/core";
5
- export declare class CaActivityLogListComponent implements OnInit {
7
+ export declare class CaActivityLogListComponent implements OnInit, OnDestroy {
8
+ private formBuilder;
9
+ RightSidePanelCurrentTab: typeof RightSidePanelCurrentTab;
10
+ activityLogSearchConfig: ICaInput;
11
+ searchForm: UntypedFormGroup;
12
+ searchButtonSvg: string;
13
+ showSearch: boolean;
14
+ hoveredItemId: number;
15
+ hoveredUserName?: string;
16
+ focusedItemId: number;
17
+ _selectedTab: RightSidePanelCurrentTab;
18
+ private destroy$;
6
19
  activityLogList: ActivityLogItem[];
7
- selectedTab: RightSidePanelCurrentTab;
20
+ set selectedTab(value: RightSidePanelCurrentTab);
21
+ searchText: EventEmitter<string>;
22
+ constructor(formBuilder: UntypedFormBuilder);
8
23
  ngOnInit(): void;
24
+ ngOnDestroy(): void;
25
+ private createForm;
9
26
  private filterActivityLogListDate;
10
27
  trackByIdentity(index: number): number;
28
+ private setActivityLogSearch;
29
+ openSearchInput(): void;
30
+ hoverItem(activityLogItem: ActivityLogItem): void;
31
+ leaveItem(): void;
32
+ private setHoveredUserName;
33
+ activityLogItemFocus(activityLogItemId: number): void;
34
+ private watchSearchFormValueChanges;
11
35
  static ɵfac: i0.ɵɵFactoryDeclaration<CaActivityLogListComponent, never>;
12
- static ɵcmp: i0.ɵɵComponentDeclaration<CaActivityLogListComponent, "lib-ca-activity-log-list", never, { "activityLogList": { "alias": "activityLogList"; "required": false; }; "selectedTab": { "alias": "selectedTab"; "required": false; }; }, {}, never, never, true, never>;
36
+ static ɵcmp: i0.ɵɵComponentDeclaration<CaActivityLogListComponent, "lib-ca-activity-log-list", never, { "activityLogList": { "alias": "activityLogList"; "required": false; }; "selectedTab": { "alias": "selectedTab"; "required": false; }; }, { "searchText": "searchText"; }, never, never, true, never>;
13
37
  }
@@ -0,0 +1,5 @@
1
+ import { ICaInput } from '../../ca-input/config';
2
+ export declare class ActivityLogSearchFilterConfig {
3
+ static getActivityLogSearch(): ICaInput;
4
+ static getSearchButtonSvg(): string;
5
+ }
@@ -0,0 +1 @@
1
+ export * from './activity-log-search-filter.config';
@@ -0,0 +1,9 @@
1
+ export interface CompanyUserAvatarFile {
2
+ fileId: number;
3
+ fileName: string;
4
+ url: string;
5
+ fileSize: number;
6
+ tags: string[];
7
+ tagGeneratedByUser: boolean;
8
+ updatedAt: Date;
9
+ }
@@ -1,7 +1,8 @@
1
+ import { CompanyUserAvatarFile } from './company-user-avatar-file.model';
1
2
  export interface CompanyUser {
2
3
  id: number;
3
4
  userId: number;
4
5
  fullName: string;
5
- avatarFile: string | null;
6
+ avatarFile: CompanyUserAvatarFile | null;
6
7
  departmentId: number | null;
7
8
  }
@@ -4,3 +4,4 @@ export * from './activity-log-item.model';
4
4
  export * from './activity-log-list-data.model';
5
5
  export * from './company-user.model';
6
6
  export * from './entity-type-activity.model';
7
+ export * from './company-user-avatar-file.model';
@@ -0,0 +1,7 @@
1
+ import { PipeTransform } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export declare class CompanyUserNameTransformPipe implements PipeTransform {
4
+ transform(value: string): string;
5
+ static ɵfac: i0.ɵɵFactoryDeclaration<CompanyUserNameTransformPipe, never>;
6
+ static ɵpipe: i0.ɵɵPipeDeclaration<CompanyUserNameTransformPipe, "companyUserNameTransform", true>;
7
+ }
@@ -1,3 +1,4 @@
1
1
  export * from './action-log-name-transform.pipe';
2
2
  export * from './activity-log-date-transform.pipe';
3
3
  export * from './tab-title-transform.pipe';
4
+ export * from './company-user-name-transform.pipe';
@@ -1,5 +1,5 @@
1
1
  import { AfterViewInit, ElementRef } from '@angular/core';
2
- import { ChartOptions, ChartType } from 'chart.js';
2
+ import { ChartOptions, ChartType } from 'chart.js/auto';
3
3
  import { IChartData, IBaseDataset } from './models';
4
4
  import * as i0 from "@angular/core";
5
5
  export declare class CaChartComponent implements AfterViewInit {
@@ -14,6 +14,7 @@ export declare class CaChartComponent implements AfterViewInit {
14
14
  private _chartType;
15
15
  private _chartData;
16
16
  private _chartOptions;
17
+ private plugins?;
17
18
  private _isDatasetHovered;
18
19
  private originalChartDataset;
19
20
  constructor();
@@ -22,6 +23,7 @@ export declare class CaChartComponent implements AfterViewInit {
22
23
  private createChart;
23
24
  private setChartOptionsProperties;
24
25
  private setChartDataProperties;
26
+ private setChartPluginsProperties;
25
27
  private setMultipleYAxis;
26
28
  static ɵfac: i0.ɵɵFactoryDeclaration<CaChartComponent, never>;
27
29
  static ɵcmp: i0.ɵɵComponentDeclaration<CaChartComponent, "app-ca-chart", never, { "chartHeight": { "alias": "chartHeight"; "required": false; }; "chartType": { "alias": "chartType"; "required": false; }; "chartData": { "alias": "chartData"; "required": false; }; "chartOptions": { "alias": "chartOptions"; "required": false; }; "isDatasetHovered": { "alias": "isDatasetHovered"; "required": false; }; }, {}, never, never, true, never>;
@@ -1,4 +1,4 @@
1
- import { IBaseDataset } from "../models";
1
+ import { IBaseDataset } from '../models';
2
2
  export declare class CaBaseChartDatasetConfig {
3
3
  static getBaseChartDatasetConfig(): IBaseDataset;
4
4
  }
@@ -1,3 +1,5 @@
1
1
  export declare enum ChartColorsStringEnum {
2
- WHITE = "#FFFFFF"
2
+ WHITE = "#FFFFFF",
3
+ HOVER_SEGMENT = "#EEEEEE",
4
+ TRANSPARENT = "transparent"
3
5
  }
@@ -0,0 +1,3 @@
1
+ export declare enum ChartEventProperties {
2
+ X = "x"
3
+ }
@@ -0,0 +1,3 @@
1
+ export declare enum ChartEventTypesStringEnum {
2
+ MOUSE_OUT = "mouseout"
3
+ }
@@ -0,0 +1,4 @@
1
+ export declare enum ChartPluginIdsStringEnum {
2
+ HIGHLIGHT_SEGMENT_ON_HOVER = "highlightSegmentOnHover",
3
+ HIGHLIGHT_POINT_ON_HOVER = "highlightPointOnHover"
4
+ }
@@ -1,3 +1,6 @@
1
1
  export * from './chart-types-enum';
2
2
  export * from './cubic-interpolation-mode-enum';
3
3
  export * from './chart-colors-enum';
4
+ export * from './chart-plugin-ids-enum';
5
+ export * from './chart-event-types-enum';
6
+ export * from './chart-event-properties-enum';
@@ -1,5 +1,6 @@
1
+ import { ChartTypeRegistry } from 'chart.js';
1
2
  export interface IBaseDataset {
2
- type: keyof any;
3
+ type: keyof ChartTypeRegistry;
3
4
  label: string;
4
5
  data: number[];
5
6
  borderColor?: string;
@@ -1,4 +1,4 @@
1
- import { IBaseDataset } from "./chart-base-dataset.model";
1
+ import { IBaseDataset } from './chart-base-dataset.model';
2
2
  export interface IChartData<DatasetType extends IBaseDataset> {
3
3
  labels: string[];
4
4
  datasets: DatasetType[];
@@ -1,8 +1,12 @@
1
- import { IBaseDataset } from "./chart-base-dataset.model";
1
+ import { IBaseDataset } from './chart-base-dataset.model';
2
2
  export interface ILineDataset extends IBaseDataset {
3
3
  tension?: number;
4
4
  cubicInterpolationMode?: string;
5
5
  pointRadius?: number;
6
+ pointBorderWidth?: number;
7
+ pointBorderColor?: string;
8
+ pointBackgroundColor?: string;
9
+ pointHoverRadius?: number;
6
10
  spanGaps?: boolean;
7
11
  showLine?: boolean;
8
12
  fill?: boolean;
@@ -1,4 +1,4 @@
1
- import { IBaseDataset, ILineDataset } from "../../models";
1
+ import { IBaseDataset, ILineDataset } from '../../models';
2
2
  export declare class ChartTypeGuard {
3
3
  static isLineDataset(dataset: IBaseDataset): dataset is ILineDataset;
4
4
  }
@@ -1 +1 @@
1
- export * from "./chart-type.guard";
1
+ export * from './chart-type.guard';
@@ -1,8 +1,14 @@
1
- import { ElementRef } from "@angular/core";
1
+ import { ElementRef } from '@angular/core';
2
+ import Chart, { CategoryScale, ChartArea, LinearScale } from 'chart.js/auto';
3
+ import { IBaseDataset, IChartData } from '../../models';
2
4
  export declare class ChartHelper {
3
5
  static hexToRgba(colorHex: string, opacity?: number): string;
4
6
  static rgbToRgba(rgb: string | undefined, opacity: number): string;
5
7
  static calculateMinValue(data: number[]): number;
6
8
  static calculateMaxValue(data: number[]): number;
7
9
  static createGradient(chartContext: CanvasRenderingContext2D, chartCanvas: ElementRef, color1: string, color2: string): CanvasGradient;
10
+ static calculateTickPositions(xScale: CategoryScale | LinearScale): number[];
11
+ static highlightSegment(ctx: CanvasRenderingContext2D, xScale: CategoryScale | LinearScale, chartArea: ChartArea, chartHeight: number, index: number): void;
12
+ static highlightPoint(ctx: CanvasRenderingContext2D, chart: Chart, index: number, chartData: IChartData<IBaseDataset>): void;
13
+ private static getSegmentPosition;
8
14
  }
@@ -1 +1 @@
1
- export * from "./chart.helper";
1
+ export * from './chart.helper';
@@ -55,8 +55,8 @@ export declare class CaFilterComponent implements OnDestroy {
55
55
  icon: string;
56
56
  usaStates: ArrayStatus[];
57
57
  canadaStates: ArrayStatus[];
58
- setFilter: EventEmitter<filterOutput | filterOutputWithParams>;
59
- clearAll: EventEmitter<filterOutput | filterOutputWithParams>;
58
+ setFilter: EventEmitter<filterOutputWithParams | filterOutput>;
59
+ clearAll: EventEmitter<filterOutputWithParams | filterOutput>;
60
60
  private destroy$;
61
61
  isSearchExpanded: boolean;
62
62
  isFilterActive: boolean;
@@ -0,0 +1,2 @@
1
+ export * from './ca-user-data.model';
2
+ export * from './ca-user-group.model';
@@ -1,18 +1,24 @@
1
- import { OnInit } from '@angular/core';
1
+ import { EventEmitter } from '@angular/core';
2
2
  import { ActivityLogItem } from '../ca-activity-log-list/models';
3
+ import { ActionFilterInputData, ActivityLogFilterParams, ModuleFilterInputData, UserFilterInputData } from './models';
3
4
  import { RightSidePanelCurrentTab, SelectedModule } from './enums';
4
5
  import * as i0 from "@angular/core";
5
- export declare class CaRightSidePanelComponent implements OnInit {
6
+ export declare class CaRightSidePanelComponent {
7
+ _activityLogFilterParams: ActivityLogFilterParams;
6
8
  data: ActivityLogItem[];
9
+ usersFilter: UserFilterInputData[];
10
+ modulesFilter: ModuleFilterInputData[];
11
+ actionsFilter: ActionFilterInputData[];
12
+ activityLogFilterParams: EventEmitter<ActivityLogFilterParams>;
7
13
  selectedNav?: SelectedModule;
8
14
  selectedTab: RightSidePanelCurrentTab;
9
15
  isPinned: boolean;
10
16
  SelectedModule: typeof SelectedModule;
11
- ngOnInit(): void;
12
- private setSelectedTab;
13
17
  selectedNavEvent(selectedNav: SelectedModule): void;
14
18
  selectedTabEvent(selectedTab: RightSidePanelCurrentTab): void;
15
19
  pinSidebarEvent(isPinned: boolean): void;
20
+ setActivityLogFilterParams(activityLogFilterParams: ActivityLogFilterParams): void;
21
+ searchEvent(searchText: string): void;
16
22
  static ɵfac: i0.ɵɵFactoryDeclaration<CaRightSidePanelComponent, never>;
17
- static ɵcmp: i0.ɵɵComponentDeclaration<CaRightSidePanelComponent, "lib-ca-right-side-panel", never, { "data": { "alias": "data"; "required": false; }; }, {}, never, never, true, never>;
23
+ static ɵcmp: i0.ɵɵComponentDeclaration<CaRightSidePanelComponent, "lib-ca-right-side-panel", never, { "data": { "alias": "data"; "required": false; }; "usersFilter": { "alias": "usersFilter"; "required": false; }; "modulesFilter": { "alias": "modulesFilter"; "required": false; }; "actionsFilter": { "alias": "actionsFilter"; "required": false; }; }, { "activityLogFilterParams": "activityLogFilterParams"; }, never, never, true, never>;
18
24
  }
@@ -15,7 +15,8 @@ export declare class CaRightSidePanelMenuComponent implements OnInit {
15
15
  itemList: NavigationItem[];
16
16
  ngOnInit(): void;
17
17
  private setItemList;
18
- toggleMenu(): void;
18
+ openMenu(): void;
19
+ closeMenu(): void;
19
20
  itemClickEvent(item: NavigationItem): void;
20
21
  navItemClickEvent(item: NavigationItem): void;
21
22
  closeModule(): void;
@@ -1,15 +1,44 @@
1
- import { EventEmitter } from '@angular/core';
2
- import { RightSidePanelCurrentTab } from '../../enums';
1
+ import { ChangeDetectorRef, EventEmitter } from '@angular/core';
2
+ import { ActivityLogSortType, RightSidePanelCurrentTab, SelectedModule } from '../../enums';
3
+ import { ActionFilterInputData, ActivityLogFilter, ActivityLogFilterParams, ModuleFilterInputData, TimeFilterEvent, UserFilterInputData } from '../../models';
4
+ import { UserGroup } from '../../../ca-filters/components/ca-user-filter/models';
5
+ import { ArrayStatus } from 'projects/ca-components/src/lib/models/array-status.model';
6
+ import { filterOutputWithParams } from 'projects/ca-components/src/lib/models/filter-output-params.model';
7
+ import { filterOutput } from 'projects/ca-components/src/lib/models/filter-output.model';
8
+ import { RightSidePanelTopBarSvgRoutes } from '../../utils/svg-routes';
3
9
  import * as i0 from "@angular/core";
4
10
  export declare class CaRightSidePanelTopBarComponent {
5
- canSeeUserTabs: boolean;
11
+ private cdr;
6
12
  currentTab: RightSidePanelCurrentTab;
13
+ hoveredTab: RightSidePanelCurrentTab | null;
7
14
  RightSidePanelCurrentTab: typeof RightSidePanelCurrentTab;
8
- private _selectedModuleTitle?;
9
- set selectedModuleTitle(value: string);
15
+ _usersFilter: UserGroup[];
16
+ _modulesFilter: UserGroup[];
17
+ _actionsFilter: ArrayStatus[];
18
+ SelectedModule: typeof SelectedModule;
19
+ activitySortOrderAsc: boolean;
20
+ RightSidePanelTopBarSvgRoutes: typeof RightSidePanelTopBarSvgRoutes;
21
+ _activityLogFilterParams: ActivityLogFilterParams;
22
+ ActivityLogSortType: typeof ActivityLogSortType;
23
+ selectedModule: SelectedModule;
24
+ set usersFilter(value: UserFilterInputData[]);
25
+ set modulesFilter(value: ModuleFilterInputData[]);
26
+ set actionsFilter(value: ActionFilterInputData[]);
10
27
  selectedTab: EventEmitter<RightSidePanelCurrentTab>;
11
- setSettings(): void;
12
- switchTab(): void;
28
+ activityLogFilterParams: EventEmitter<ActivityLogFilterParams>;
29
+ constructor(cdr: ChangeDetectorRef);
30
+ switchTab(tab: RightSidePanelCurrentTab): void;
31
+ private transformUsersFilter;
32
+ private transformModulesFilter;
33
+ private transformActionsFilter;
34
+ setUserFilters(filter: ActivityLogFilter | any): void;
35
+ setModuleFilters(filter: ActivityLogFilter | any): void;
36
+ setTimeFilters(filter: TimeFilterEvent | any): void;
37
+ clearAll(values: filterOutputWithParams | filterOutput | any): void;
38
+ sortDate(): void;
39
+ onHoverTab(hoveredTab: RightSidePanelCurrentTab): void;
40
+ onHoverLeave(): void;
41
+ reloadActivities(): void;
13
42
  static ɵfac: i0.ɵɵFactoryDeclaration<CaRightSidePanelTopBarComponent, never>;
14
- static ɵcmp: i0.ɵɵComponentDeclaration<CaRightSidePanelTopBarComponent, "lib-ca-right-side-panel-top-bar", never, { "selectedModuleTitle": { "alias": "selectedModuleTitle"; "required": false; }; }, { "selectedTab": "selectedTab"; }, never, never, true, never>;
43
+ static ɵcmp: i0.ɵɵComponentDeclaration<CaRightSidePanelTopBarComponent, "lib-ca-right-side-panel-top-bar", never, { "selectedModule": { "alias": "selectedModule"; "required": false; }; "usersFilter": { "alias": "usersFilter"; "required": false; }; "modulesFilter": { "alias": "modulesFilter"; "required": false; }; "actionsFilter": { "alias": "actionsFilter"; "required": false; }; }, { "selectedTab": "selectedTab"; "activityLogFilterParams": "activityLogFilterParams"; }, never, never, true, never>;
15
44
  }
@@ -0,0 +1,4 @@
1
+ export declare enum ActivityLogSortType {
2
+ ASCENDING = "Ascending",
3
+ DESCENDING = "Descending"
4
+ }
@@ -0,0 +1,6 @@
1
+ export declare enum FilterType {
2
+ USER = "userFilter",
3
+ MODULE = "moduleFilter",
4
+ ACTION = "actionFilter",
5
+ TIME = "timeFilter"
6
+ }
@@ -1,2 +1,6 @@
1
1
  export * from './right-side-panel-current-tab.enum';
2
2
  export * from './selected-module.enum';
3
+ export * from './filter-type.enum';
4
+ export * from './activity-log-sort-type.enum';
5
+ export * from './time-filter-type.enum';
6
+ export * from './modules-filter-item-label.enum';
@@ -0,0 +1,3 @@
1
+ export declare enum ModulesFilterItemLabel {
2
+ LIST = "List"
3
+ }
@@ -1,7 +1,7 @@
1
1
  export declare enum SelectedModule {
2
2
  COMPANY_INFO = "Company Info",
3
3
  DIVISION_INFO = "Division Info",
4
- DOCUMENTS = "Documents",
4
+ DOCUMENT = "Document",
5
5
  LOCATION = "Location",
6
6
  INSURANCE_POLICY = "Insurance Policy",
7
7
  FACTORING_COMPANY = "Factoring Company",
@@ -0,0 +1,9 @@
1
+ export declare enum TimeFilterType {
2
+ TODAY = "Today",
3
+ YESTERDAY = "Yesterday",
4
+ THIS_WEEK = "This Week",
5
+ LAST_WEEK = "Last Week",
6
+ THIS_MONTH = "This Month",
7
+ LAST_MONTH = "Last Month",
8
+ CUSTOM = "Custom"
9
+ }
@@ -0,0 +1,7 @@
1
+ import { ActionLog } from '../../../ca-activity-log-list/models';
2
+ export interface ActionFilterInputData {
3
+ logoName: string;
4
+ name: string;
5
+ actionLogs: ActionLog;
6
+ count: number;
7
+ }
@@ -0,0 +1,11 @@
1
+ import { ActivityLogSortType, RightSidePanelCurrentTab } from '../enums';
2
+ export interface ActivityLogFilterParams {
3
+ companyUserIds: number[];
4
+ actionLogIds: number[];
5
+ entityTypeActivityIds: number[];
6
+ sort: ActivityLogSortType;
7
+ userFilterType: RightSidePanelCurrentTab;
8
+ dateFrom: Date | null;
9
+ dateTo: Date | null;
10
+ search?: string | null;
11
+ }
@@ -0,0 +1,6 @@
1
+ export interface ActivityLogFilter {
2
+ filterType: string;
3
+ action: string;
4
+ queryParams: number[];
5
+ subType: string;
6
+ }
@@ -1 +1,10 @@
1
1
  export * from './navigation-item.model';
2
+ export * from './activity-log-filter-params.model';
3
+ export * from './activity-log-filter.model';
4
+ export * from './user-filter/user-filter-avatar-file.model';
5
+ export * from './user-filter/user-filter-data.model';
6
+ export * from './user-filter/user-filter-input-data.model';
7
+ export * from './module-filter/module-filter-activity-log.model';
8
+ export * from './module-filter/module-filter-input-data.model';
9
+ export * from './action-filter/action-filter-input-data.model';
10
+ export * from './time-filter/time-filter-event.model';
@@ -0,0 +1,6 @@
1
+ export interface ModuleFilterActivityLog {
2
+ id: number;
3
+ companyId: number;
4
+ name: string;
5
+ logoName: string;
6
+ }
@@ -0,0 +1,5 @@
1
+ import { ModuleFilterActivityLog } from '../';
2
+ export interface ModuleFilterInputData {
3
+ activityLogType: ModuleFilterActivityLog;
4
+ count: number;
5
+ }
@@ -1,4 +1,4 @@
1
- import { SelectedModule } from "../enums";
1
+ import { SelectedModule } from '../enums';
2
2
  export interface NavigationItem {
3
3
  icon: string;
4
4
  title: SelectedModule;
@@ -0,0 +1,8 @@
1
+ export interface TimeFilterEvent {
2
+ filterType: string;
3
+ action: string;
4
+ queryParams: {
5
+ timeSelected: string;
6
+ };
7
+ subType: string;
8
+ }
@@ -0,0 +1,9 @@
1
+ export interface UserFilterAvatarFile {
2
+ fileId: number;
3
+ fileName: string;
4
+ url: string;
5
+ fileSize: number;
6
+ tags: string[];
7
+ tagGeneratedByUser: boolean;
8
+ updatedAt: Date;
9
+ }
@@ -0,0 +1,7 @@
1
+ import { UserFilterAvatarFile } from '../';
2
+ export interface UserFilterData {
3
+ id: number;
4
+ fullName: string;
5
+ avatarFile: UserFilterAvatarFile;
6
+ count: number;
7
+ }
@@ -0,0 +1,7 @@
1
+ import { UserFilterData } from '../';
2
+ export interface UserFilterInputData {
3
+ id: number;
4
+ name: string;
5
+ count: number;
6
+ users: UserFilterData[];
7
+ }
@@ -0,0 +1 @@
1
+ export * from './right-side-panel-top-bar-svg.routes';
@@ -0,0 +1,9 @@
1
+ export declare class RightSidePanelTopBarSvgRoutes {
2
+ static icons: {
3
+ sortArrowFilter: string;
4
+ };
5
+ static folders: {
6
+ common: string;
7
+ actions: string;
8
+ };
9
+ }
package/package.json CHANGED
@@ -1,14 +1,13 @@
1
1
  {
2
2
  "name": "ca-components",
3
- "version": "0.0.89",
3
+ "version": "0.0.91",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^16.2.0",
6
6
  "@angular/core": "^16.2.0",
7
7
  "@angular/animations": "^16.2.0",
8
8
  "@angular/google-maps": "^16.2.2",
9
9
  "@ng-bootstrap/ng-bootstrap": "^15.1.0",
10
- "angular-svg-icon": "^16.1.0",
11
- "chart.js": "^4.4.5"
10
+ "angular-svg-icon": "^16.1.0"
12
11
  },
13
12
  "dependencies": {
14
13
  "tslib": "^2.3.0"
@@ -0,0 +1,3 @@
1
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M14.2259 2.49038C14.4354 2.00387 14.2792 1.43569 13.8495 1.12319C13.4198 0.810691 12.8339 0.8391 12.4326 1.18711L3.34167 9.14166C2.98656 9.45416 2.85872 9.95487 3.02562 10.3952C3.19252 10.8355 3.61866 11.1338 4.09096 11.1338H8.05048L5.31965 17.5046C5.11014 17.9911 5.26639 18.5593 5.69607 18.8718C6.12576 19.1843 6.7117 19.1559 7.11298 18.8078L16.2039 10.8533C16.559 10.5408 16.6868 10.0401 16.5199 9.59975C16.353 9.15941 15.9304 8.86467 15.4546 8.86467H11.4951L14.2259 2.49038Z" fill="black"/>
3
+ </svg>
@@ -0,0 +1,5 @@
1
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M13 6C13 7.65685 11.6569 9 10 9C8.34315 9 7 7.65685 7 6C7 4.34315 8.34315 3 10 3C11.6569 3 13 4.34315 13 6Z" fill="black"/>
3
+ <path d="M8 14C8 15.6569 6.65685 17 5 17C3.34315 17 2 15.6569 2 14C2 12.3431 3.34315 11 5 11C6.65685 11 8 12.3431 8 14Z" fill="black"/>
4
+ <path d="M18 14C18 15.6569 16.6569 17 15 17C13.3431 17 12 15.6569 12 14C12 12.3431 13.3431 11 15 11C16.6569 11 18 12.3431 18 14Z" fill="black"/>
5
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M16.03 16.6753L16.0478 16.662C16.0885 16.6219 16.1209 16.5741 16.143 16.5213C16.1651 16.4686 16.1764 16.412 16.1764 16.3548C16.1764 16.2976 16.1651 16.241 16.143 16.1882C16.1209 16.1355 16.0885 16.0877 16.0478 16.0476L14.6033 14.6031C14.5256 14.525 14.421 14.4793 14.3108 14.4754C14.2007 14.4715 14.0931 14.5096 14.01 14.582C12.9032 15.5592 11.4764 16.0965 10 16.092C9.00706 16.0906 8.02948 15.8467 7.15227 15.3815C6.27506 14.9163 5.52479 14.2438 4.9667 13.4225C4.40861 12.6012 4.05959 11.6561 3.95 10.6692C3.84041 9.68232 3.97357 8.68361 4.3379 7.75991C4.70222 6.83622 5.28668 6.01552 6.04045 5.36916C6.79422 4.72281 7.69447 4.27038 8.66293 4.05122C9.63139 3.83206 10.6387 3.85281 11.5973 4.11165C12.5559 4.3705 13.4368 4.85961 14.1633 5.53644L16.2222 3.48756C14.9562 2.27689 13.3643 1.46201 11.6419 1.14283C9.91953 0.823662 8.14141 1.01408 6.52564 1.69073C4.90986 2.36738 3.52668 3.50085 2.5457 4.95214C1.56472 6.40344 1.02859 8.10947 1.00307 9.86101C0.977535 11.6126 1.46371 13.3335 2.40197 14.8128C3.34024 16.292 4.6898 17.4653 6.28516 18.1888C7.88053 18.9122 9.65234 19.1544 11.3833 18.8856C13.1143 18.6167 14.7292 17.8486 16.03 16.6753ZM18.1289 8.542C18.243 8.54244 18.3561 8.52035 18.4617 8.47701C18.5673 8.43367 18.6633 8.36992 18.7443 8.28941C18.8252 8.2089 18.8894 8.11322 18.9333 8.00785C18.9772 7.90248 18.9999 7.78948 19 7.67533L19 2.80756C18.9995 2.63526 18.948 2.46697 18.852 2.3239C18.756 2.18084 18.6198 2.06941 18.4605 2.00369C18.3012 1.93796 18.1261 1.92088 17.9571 1.95459C17.7882 1.9883 17.633 2.0713 17.5111 2.19311L12.6467 7.05644C12.5247 7.17825 12.4417 7.33354 12.4081 7.50261C12.3746 7.67168 12.392 7.84691 12.4582 8.00607C12.5244 8.16522 12.6363 8.30113 12.7799 8.39655C12.9234 8.49196 13.0921 8.54259 13.2644 8.542H18.1289Z" fill="black"/>
3
+ </svg>