@libs-ui/components-table 0.2.78 → 0.2.79

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.
@@ -1,7 +1,8 @@
1
1
  import { WritableSignal } from "@angular/core";
2
+ import { TYPE_OBJECT } from "@libs-ui/interfaces-types";
2
3
  export type TYPE_TABLE_FILTER = ((items: TYPE_DATA_TABLE, filter: Record<string, unknown>) => Array<WritableSignal<Record<string, unknown>>>) | undefined;
3
4
  export type TYPE_DATA_FILTER_TABLE = {
4
- filterData: Record<any, any>;
5
+ filterData: TYPE_OBJECT;
5
6
  ignoreCallApiAuto?: boolean;
6
7
  };
7
8
  export type TYPE_NEW_DATA_TABLE = {
@@ -9,4 +10,4 @@ export type TYPE_NEW_DATA_TABLE = {
9
10
  addToLastList?: boolean;
10
11
  };
11
12
  export type TYPE_DATA_TABLE = WritableSignal<Array<TYPE_ITEM_DATA_TABLE>>;
12
- export type TYPE_ITEM_DATA_TABLE = WritableSignal<Record<any, any>>;
13
+ export type TYPE_ITEM_DATA_TABLE = WritableSignal<TYPE_OBJECT>;
@@ -4,7 +4,7 @@ import { IDropdown } from "@libs-ui/components-dropdown";
4
4
  import { IListConfigItem } from "@libs-ui/components-list";
5
5
  import { IPopover } from "@libs-ui/components-popover";
6
6
  import { ISwitchEvent } from "@libs-ui/components-switch";
7
- import { TYPE_FUNCTION } from "@libs-ui/interfaces-types";
7
+ import { TYPE_FUNCTION, TYPE_OBJECT } from "@libs-ui/interfaces-types";
8
8
  import { IHttpRequestConfig } from "@libs-ui/services-http-request";
9
9
  import { Observable } from "rxjs";
10
10
  import { LibsUiComponentsTableTemplateAbstractComponent } from "../templates/template.abstract.component";
@@ -26,16 +26,16 @@ export interface ITableFieldTemplateConfig {
26
26
  getTooltipConfig?: TYPE_FUNCTION;
27
27
  action?: (dataField: any, item: TYPE_ITEM_DATA_TABLE, itemTableSelected?: TYPE_ITEM_DATA_TABLE) => any;
28
28
  tooltip?: IPopover;
29
- ngStyle?: Record<any, any>;
29
+ ngStyle?: TYPE_OBJECT;
30
30
  getNgStyle?: TYPE_FUNCTION;
31
- ngClass?: Record<any, any>;
31
+ ngClass?: TYPE_OBJECT;
32
32
  ignoreClassMarginLeft?: boolean;
33
33
  lineClampConfig?: ILineClampConfig;
34
34
  maxWidthTooltip?: number;
35
35
  maxHeightTooltip?: number;
36
36
  getDisableValueSwitch?: TYPE_FUNCTION;
37
37
  getActiveValueSwitch?: TYPE_FUNCTION;
38
- switchAction?: (toggle: ISwitchEvent, item: TYPE_ITEM_DATA_TABLE) => void;
38
+ switchAction?: (switchData: ISwitchEvent, item: TYPE_ITEM_DATA_TABLE) => void;
39
39
  buttons?: Array<WritableSignal<IButton>>;
40
40
  buttonDropDown?: WritableSignal<IButton>;
41
41
  getButtonsByItem?: TYPE_FUNCTION<Array<WritableSignal<IButton>>>;
@@ -43,7 +43,7 @@ export interface ITableFieldTemplateConfig {
43
43
  getDisable?: TYPE_FUNCTION;
44
44
  dropdownConfig?: ITableFieldTemplateConfigDropdown;
45
45
  getAvatarConfig?: TYPE_FUNCTION<IAvatarConfig>;
46
- getImageSrc?: (value: any, item?: Record<any, any>, lang?: string, isError?: boolean) => Observable<string>;
46
+ getImageSrc?: (value: any, item?: TYPE_OBJECT, lang?: string, isError?: boolean) => Observable<string>;
47
47
  rows?: Array<ITableTemplateConfig>;
48
48
  rowsTemplateCssWrapper?: string;
49
49
  getComponentOutlet?: () => Observable<LibsUiComponentsTableTemplateAbstractComponent | any>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@libs-ui/components-table",
3
- "version": "0.2.78",
3
+ "version": "0.2.79",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^18.2.0",
6
6
  "@angular/core": "^18.2.0"
@@ -5,9 +5,9 @@ import { ICheckboxItem } from "@libs-ui/components-checkbox-group";
5
5
  import { ICheckboxEvent } from "@libs-ui/components-checkbox-single";
6
6
  import { IDropdownFunctionControlEvent, IEmitSelectKey } from '@libs-ui/components-dropdown';
7
7
  import { TYPE_POPOVER_EVENT } from "@libs-ui/components-popover";
8
- import { IHttpResponseError } from "@libs-ui/interfaces-types";
8
+ import { IHttpResponseError, TYPE_OBJECT } from "@libs-ui/interfaces-types";
9
9
  import { IHttpRequestConfig } from "@libs-ui/services-http-request";
10
- import { IButtonBarEvent, IConfigSelectMoreItem, IConfigTemplateItemCollapseExpand, IHoverButtonActionEvent, ILoadMoreEvent, ISortEvent, ITabelButtonActionEvent, ITableFooterConfig, ITableHeaderConfig, TYPE_DATA_FILTER_TABLE, TYPE_NEW_DATA_TABLE, TYPE_TABLE_FILTER } from "./interfaces";
10
+ import { IButtonBarEvent, IConfigSelectMoreItem, IConfigTemplateItemCollapseExpand, IHoverButtonActionEvent, ILoadMoreEvent, ISortEvent, ITabelButtonActionEvent, ITableFooterConfig, ITableHeaderConfig, TYPE_DATA_FILTER_TABLE, TYPE_ITEM_DATA_TABLE, TYPE_NEW_DATA_TABLE, TYPE_TABLE_FILTER } from "./interfaces";
11
11
  import { ITableFunctionControlEvent } from "./interfaces/function-control-event.interface";
12
12
  import { ITableNoDataConfig } from "./interfaces/no-data-config.interface";
13
13
  import * as i0 from "@angular/core";
@@ -16,10 +16,10 @@ export declare class LibsUiComponentsTableComponent implements OnInit, OnDestroy
16
16
  protected classHeaderContainer: import("@angular/core").Signal<string>;
17
17
  protected keysSelected: WritableSignal<any[]>;
18
18
  protected loading: WritableSignal<boolean>;
19
- protected stores: WritableSignal<WritableSignal<Record<any, any>>[]>;
20
- protected items: WritableSignal<WritableSignal<Record<any, any>>[]>;
21
- protected itemFooter: WritableSignal<Record<any, any>>;
22
- protected itemOfIndexHover?: WritableSignal<any>;
19
+ protected stores: WritableSignal<WritableSignal<TYPE_OBJECT>[]>;
20
+ protected items: WritableSignal<WritableSignal<TYPE_OBJECT>[]>;
21
+ protected itemFooter: WritableSignal<TYPE_OBJECT>;
22
+ protected itemOfIndexHover?: TYPE_ITEM_DATA_TABLE;
23
23
  protected keySearch: WritableSignal<string>;
24
24
  protected totalItemInBackend: WritableSignal<number>;
25
25
  protected hasItemHightLight: WritableSignal<boolean>;
@@ -99,7 +99,7 @@ export declare class LibsUiComponentsTableComponent implements OnInit, OnDestroy
99
99
  ngOnInit(): void;
100
100
  private getScrollContainer;
101
101
  private callApiByService;
102
- protected fakeResponseApi(): Record<any, any>;
102
+ protected fakeResponseApi(): TYPE_OBJECT;
103
103
  private callApiByServiceFooter;
104
104
  private addItems;
105
105
  private checkExistItem;
@@ -112,7 +112,7 @@ export declare class LibsUiComponentsTableComponent implements OnInit, OnDestroy
112
112
  protected handlerChangeAllChecked(): void;
113
113
  protected handlerChangeCheckedAllItems(event: ICheckboxEvent): void;
114
114
  private checkCancelConditionCheckedItem;
115
- protected handlerChangeItemChecked(event: ICheckboxItem, item: Record<any, any>): void;
115
+ protected handlerChangeItemChecked(event: ICheckboxItem, item: TYPE_OBJECT): void;
116
116
  protected handlerChangeSort(sort: ISort): void;
117
117
  private handlerSortLocal;
118
118
  protected handlerFunctionControlMoreSelectItem(functionControl: IDropdownFunctionControlEvent): void;
@@ -122,7 +122,7 @@ export declare class LibsUiComponentsTableComponent implements OnInit, OnDestroy
122
122
  protected handlerButtonClick(type: 'button' | 'button-dropdown', buttonDropdownData: any, button: IButton): void;
123
123
  protected handlerBarButtonClick(button: IButton): void;
124
124
  protected handlerButtonDropdownEvent(eventName: TYPE_POPOVER_EVENT): void;
125
- protected setIndexHover(e: Event, item: WritableSignal<Record<any, any>>): void;
125
+ protected setIndexHover(e: Event, item: WritableSignal<TYPE_OBJECT>): void;
126
126
  protected resetIndexHoverWhenMouseLeave(e?: Event): void;
127
127
  protected resetIndexHover(e?: Event): void;
128
128
  protected handlerMouseEnter(event: Event): void;