@libs-ui/components-list 0.2.357-15 → 0.2.357-16

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,13 +1,23 @@
1
1
  import { AfterViewInit } from '@angular/core';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class LibsUiComponentsListHighlightKeySearchDirective implements AfterViewInit {
4
+ private observer?;
5
+ private isApplying;
4
6
  readonly isHighlight: import("@angular/core").InputSignal<boolean | undefined>;
5
7
  readonly keySearch: import("@angular/core").InputSignal<string | undefined>;
6
8
  readonly classHighlight: import("@angular/core").InputSignal<string>;
7
9
  private readonly elementRef;
10
+ private readonly destroyRef;
11
+ constructor();
8
12
  ngAfterViewInit(): void;
9
13
  protected handlerHighlight(element: Node): void;
10
14
  protected checkAndReplace(node: Node): void;
15
+ /** Xoá highlight cũ rồi tô lại — gọi được nhiều lần, không nhân bản span. */
16
+ private applyHighlight;
17
+ /** Gỡ span highlight đã chèn, gộp lại text node ban đầu. */
18
+ private clearHighlight;
19
+ /** Chỉ theo dõi DOM khi thực sự bật highlight để không tốn tài nguyên cho list thường. */
20
+ private syncObserver;
11
21
  static ɵfac: i0.ɵɵFactoryDeclaration<LibsUiComponentsListHighlightKeySearchDirective, never>;
12
22
  static ɵdir: i0.ɵɵDirectiveDeclaration<LibsUiComponentsListHighlightKeySearchDirective, "[LibsUiComponentsListHighlightKeySearchDirective]", never, { "isHighlight": { "alias": "isHighlight"; "required": false; "isSignal": true; }; "keySearch": { "alias": "keySearch"; "required": false; "isSignal": true; }; "classHighlight": { "alias": "classHighlight"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
13
23
  }
@@ -6,7 +6,7 @@ import { ISort } from '@libs-ui/components-buttons-sort';
6
6
  import { ICheckboxItem } from '@libs-ui/components-checkbox-group';
7
7
  import { LibsUiComponentsComponentOutletComponent } from '@libs-ui/components-component-outlet';
8
8
  import { ILabel } from '@libs-ui/components-label';
9
- import { IPopover, IPopoverOverlay, TYPE_POPOVER_EVENT } from '@libs-ui/components-popover';
9
+ import { IPopover, IPopoverOverlay, TYPE_POPOVER_EVENT, TYPE_POPOVER_TYPE } from '@libs-ui/components-popover';
10
10
  import { TYPE_FUNCTION, TYPE_OBJECT } from '@libs-ui/interfaces-types';
11
11
  import { IHttpRequestConfig } from '@libs-ui/services-http-request';
12
12
  import { Observable } from 'rxjs';
@@ -138,6 +138,8 @@ export interface IListConfigItemCheckbox {
138
138
  }
139
139
  export interface IListConfigItemTextRow {
140
140
  classRow?: string;
141
+ classLabelRow?: string;
142
+ typePopoverLabel?: TYPE_POPOVER_TYPE;
141
143
  classItemSelected?: string;
142
144
  getValue?: (item: any, itemViewInList?: TYPE_LIST_ITEM) => Observable<string>;
143
145
  classGetValue?: string;
package/package.json CHANGED
@@ -1,37 +1,37 @@
1
1
  {
2
2
  "name": "@libs-ui/components-list",
3
- "version": "0.2.357-15",
3
+ "version": "0.2.357-16",
4
4
  "peerDependencies": {
5
5
  "@angular/common": ">=18.0.0",
6
6
  "@angular/core": ">=18.0.0",
7
- "@libs-ui/utils": "0.2.357-15",
8
- "@libs-ui/components-avatar": "0.2.357-15",
9
- "@libs-ui/components-badge": "0.2.357-15",
10
- "@libs-ui/components-buttons-button": "0.2.357-15",
11
- "@libs-ui/components-buttons-sort": "0.2.357-15",
12
- "@libs-ui/components-checkbox-group": "0.2.357-15",
13
- "@libs-ui/components-label": "0.2.357-15",
14
- "@libs-ui/components-popover": "0.2.357-15",
15
- "@libs-ui/services-http-request": "0.2.357-15",
7
+ "@libs-ui/utils": "0.2.357-16",
8
+ "@libs-ui/components-avatar": "0.2.357-16",
9
+ "@libs-ui/components-badge": "0.2.357-16",
10
+ "@libs-ui/components-buttons-button": "0.2.357-16",
11
+ "@libs-ui/components-buttons-sort": "0.2.357-16",
12
+ "@libs-ui/components-checkbox-group": "0.2.357-16",
13
+ "@libs-ui/components-label": "0.2.357-16",
14
+ "@libs-ui/components-popover": "0.2.357-16",
15
+ "@libs-ui/services-http-request": "0.2.357-16",
16
16
  "rxjs": "~7.8.0",
17
- "@libs-ui/interfaces-types": "0.2.357-15",
18
- "@libs-ui/components-inputs-input": "0.2.357-15",
19
- "@libs-ui/components-inputs-search": "0.2.357-15",
20
- "@libs-ui/components-inputs-valid": "0.2.357-15",
21
- "@libs-ui/services-dynamic-component": "0.2.357-15",
17
+ "@libs-ui/interfaces-types": "0.2.357-16",
18
+ "@libs-ui/components-inputs-input": "0.2.357-16",
19
+ "@libs-ui/components-inputs-search": "0.2.357-16",
20
+ "@libs-ui/components-inputs-valid": "0.2.357-16",
21
+ "@libs-ui/services-dynamic-component": "0.2.357-16",
22
22
  "@ngx-translate/core": "^15.0.0",
23
23
  "@iharbeck/ngx-virtual-scroller": "15.2.0",
24
- "@libs-ui/components-checkbox-single": "0.2.357-15",
25
- "@libs-ui/components-scroll-overlay": "0.2.357-15",
26
- "@libs-ui/components-spinner": "0.2.357-15",
27
- "@libs-ui/icons": "0.2.357-15",
28
- "@libs-ui/pipes-call-function-in-template": "0.2.357-15",
29
- "@libs-ui/pipes-convert-object-to-signal": "0.2.357-15",
30
- "@libs-ui/components-radio-single": "0.2.357-15",
31
- "@libs-ui/components-switch": "0.2.357-15",
32
- "@libs-ui/components-component-outlet": "0.2.357-15",
33
- "@libs-ui/pipes-convert-signal-to-object": "0.2.357-15",
34
- "@libs-ui/pipes-get-value-of-object": "0.2.357-15"
24
+ "@libs-ui/components-checkbox-single": "0.2.357-16",
25
+ "@libs-ui/components-scroll-overlay": "0.2.357-16",
26
+ "@libs-ui/components-spinner": "0.2.357-16",
27
+ "@libs-ui/icons": "0.2.357-16",
28
+ "@libs-ui/pipes-call-function-in-template": "0.2.357-16",
29
+ "@libs-ui/pipes-convert-object-to-signal": "0.2.357-16",
30
+ "@libs-ui/components-radio-single": "0.2.357-16",
31
+ "@libs-ui/components-switch": "0.2.357-16",
32
+ "@libs-ui/components-component-outlet": "0.2.357-16",
33
+ "@libs-ui/pipes-convert-signal-to-object": "0.2.357-16",
34
+ "@libs-ui/pipes-get-value-of-object": "0.2.357-16"
35
35
  },
36
36
  "sideEffects": false,
37
37
  "module": "fesm2022/libs-ui-components-list.mjs",
@@ -85,6 +85,13 @@ export declare abstract class LibsUiComponentsListTemplatesComponentAbstract imp
85
85
  protected fakeResponseApi(): Record<string, any>;
86
86
  protected buildValueByConfig(item: WritableSignal<any>, configTemplate?: IListConfigItemText | IListConfigItemRadio | IListConfigItemCheckbox): string;
87
87
  protected handlerChangStageFlagMouse(flag: IFlagMouse): void;
88
+ /**
89
+ * Điều kiện dùng chung cho text/checkbox/radio khi build lại danh sách trong processData:
90
+ * item được nhận khi (đang search online qua service HOẶC text khớp từ khóa) VÀ chưa trùng
91
+ * trong list hiện tại (bỏ qua nếu replace) VÀ chưa trùng trong tập kết quả đang gom.
92
+ * @param text Chuỗi hiển thị của item đã lowercase (caller tự build vì phụ thuộc configTemplate riêng).
93
+ */
94
+ protected isItemAcceptedBySearch(dataStore: WritableSignal<any>, itemByKeySearch: Array<WritableSignal<any>>, text: string, replace?: boolean): boolean;
88
95
  protected abstract processData(isReplace?: boolean): any;
89
96
  protected abstract processSearch(): any;
90
97
  protected abstract getLengthItem(): number;