@ai-table/grid 0.4.0-1 → 0.4.0-2
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.
- package/components/cell-editors/abstract-cell-editor.component.d.ts +1 -0
- package/components/cell-editors/abstract-cell-editor.component.d.ts.map +1 -1
- package/components/cell-editors/cell-editor.scss +3 -1
- package/components/cell-editors/select/select-editor.component.d.ts.map +1 -1
- package/components/cell-editors/text/text-editor.component.d.ts +1 -0
- package/components/cell-editors/text/text-editor.component.d.ts.map +1 -1
- package/fesm2022/ai-table-grid.mjs +12 -0
- package/fesm2022/ai-table-grid.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -18,6 +18,7 @@ export declare abstract class AbstractEditCellEditor<TValue, TFieldType extends
|
|
|
18
18
|
protected render2: Renderer2;
|
|
19
19
|
protected minHeight: number;
|
|
20
20
|
ngOnInit(): void;
|
|
21
|
+
applyContainerClass(className: string): void;
|
|
21
22
|
update(): void;
|
|
22
23
|
closePopover(): void;
|
|
23
24
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"abstract-cell-editor.component.d.ts","sourceRoot":"","sources":["../../../../packages/grid/src/components/cell-editors/abstract-cell-editor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgD,UAAU,EAAwB,MAAM,EAAU,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1I,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,OAAO,EAAkB,MAAM,YAAY,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;;AAG3F,8BAKsB,sBAAsB,CAAC,MAAM,EAAE,UAAU,SAAS,YAAY,GAAG,YAAY,CAAE,YAAW,MAAM;IACvF,OAAO,EAAG,OAAO,CAAC;IAElB,OAAO,EAAG,MAAM,CAAC;IAEjB,QAAQ,EAAG,MAAM,CAAC;IAElB,UAAU,EAAG,iBAAiB,CAAC;IAE1D,YAAY,8CAAoD;IAEhE,iBAAiB,8EAA+C;IAEhE,UAAU,EAAG,MAAM,CAAC;IAEpB,KAAK,6CAEF;IAEH,MAAM,0EAEH;IAEH,UAAU,EAAE,UAAU,CAAC,WAAW,CAAC,CAAmC;IAEtE,SAAS,CAAC,aAAa,sCAA6E;IAEpG,SAAS,CAAC,OAAO,YAAqB;IAEtC,SAAS,CAAC,SAAS,SAAM;IAEzB,QAAQ,IAAI,IAAI;IAIhB,MAAM;IAYN,YAAY;IAIZ;;;;;OAKG;IACH,SAAS,CAAC,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,gBAAgB,CAAC,EAAE,MAAM,IAAI;
|
|
1
|
+
{"version":3,"file":"abstract-cell-editor.component.d.ts","sourceRoot":"","sources":["../../../../packages/grid/src/components/cell-editors/abstract-cell-editor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgD,UAAU,EAAwB,MAAM,EAAU,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1I,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,OAAO,EAAkB,MAAM,YAAY,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;;AAG3F,8BAKsB,sBAAsB,CAAC,MAAM,EAAE,UAAU,SAAS,YAAY,GAAG,YAAY,CAAE,YAAW,MAAM;IACvF,OAAO,EAAG,OAAO,CAAC;IAElB,OAAO,EAAG,MAAM,CAAC;IAEjB,QAAQ,EAAG,MAAM,CAAC;IAElB,UAAU,EAAG,iBAAiB,CAAC;IAE1D,YAAY,8CAAoD;IAEhE,iBAAiB,8EAA+C;IAEhE,UAAU,EAAG,MAAM,CAAC;IAEpB,KAAK,6CAEF;IAEH,MAAM,0EAEH;IAEH,UAAU,EAAE,UAAU,CAAC,WAAW,CAAC,CAAmC;IAEtE,SAAS,CAAC,aAAa,sCAA6E;IAEpG,SAAS,CAAC,OAAO,YAAqB;IAEtC,SAAS,CAAC,SAAS,SAAM;IAEzB,QAAQ,IAAI,IAAI;IAIhB,mBAAmB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI;IAO5C,MAAM;IAYN,YAAY;IAIZ;;;;;OAKG;IACH,SAAS,CAAC,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,gBAAgB,CAAC,EAAE,MAAM,IAAI;yCAhEjF,sBAAsB;2CAAtB,sBAAsB;CAoF3C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-editor.component.d.ts","sourceRoot":"","sources":["../../../../../packages/grid/src/components/cell-editors/select/select-editor.component.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAmE,MAAM,eAAe,CAAC;AAO/G,OAAO,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AAEpD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;;AAI3E,qBAmBa,yBAA0B,SAAQ,sBAAsB,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,kBAAkB,CAAE,YAAW,aAAa;IACjI,aAAa,kFAEV;IAEH,MAAM,6CAEH;IAEH,IAAI,UAAU,YAEb;;IAMQ,QAAQ,IAAI,IAAI;
|
|
1
|
+
{"version":3,"file":"select-editor.component.d.ts","sourceRoot":"","sources":["../../../../../packages/grid/src/components/cell-editors/select/select-editor.component.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAmE,MAAM,eAAe,CAAC;AAO/G,OAAO,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AAEpD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;;AAI3E,qBAmBa,yBAA0B,SAAQ,sBAAsB,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,kBAAkB,CAAE,YAAW,aAAa;IACjI,aAAa,kFAEV;IAEH,MAAM,6CAEH;IAEH,IAAI,UAAU,YAEb;;IAMQ,QAAQ,IAAI,IAAI;IAYzB,eAAe;IAMf,YAAY,CAAC,KAAK,EAAE,OAAO;IAM3B,aAAa,CAAC,KAAK,EAAE,GAAG;IAOxB,aAAa;IAab,WAAW;yCA7DF,yBAAyB;2CAAzB,yBAAyB;CAkErC"}
|
|
@@ -4,6 +4,7 @@ import * as i0 from "@angular/core";
|
|
|
4
4
|
export declare class TextCellEditorComponent extends AbstractEditCellEditor<string> implements AfterViewInit {
|
|
5
5
|
isSelectAll: import("@angular/core").InputSignal<boolean>;
|
|
6
6
|
constructor();
|
|
7
|
+
ngOnInit(): void;
|
|
7
8
|
ngAfterViewInit(): void;
|
|
8
9
|
updateStyle(): void;
|
|
9
10
|
handleSelectAll(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-editor.component.d.ts","sourceRoot":"","sources":["../../../../../packages/grid/src/components/cell-editors/text/text-editor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAgE,MAAM,eAAe,CAAC;AAI5G,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;;AAE3E,qBAqBa,uBAAwB,SAAQ,sBAAsB,CAAC,MAAM,CAAE,YAAW,aAAa;IAChG,WAAW,+CAAgB;;
|
|
1
|
+
{"version":3,"file":"text-editor.component.d.ts","sourceRoot":"","sources":["../../../../../packages/grid/src/components/cell-editors/text/text-editor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAgE,MAAM,eAAe,CAAC;AAI5G,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;;AAE3E,qBAqBa,uBAAwB,SAAQ,sBAAsB,CAAC,MAAM,CAAE,YAAW,aAAa;IAChG,WAAW,+CAAgB;;IAMlB,QAAQ,IAAI,IAAI;IAKzB,eAAe;IAQf,WAAW;IAIX,eAAe;IAOf,WAAW;IAIX,WAAW;yCAnCF,uBAAuB;2CAAvB,uBAAuB;CAuCnC"}
|
|
@@ -1682,6 +1682,12 @@ class AbstractEditCellEditor {
|
|
|
1682
1682
|
ngOnInit() {
|
|
1683
1683
|
this.modelValue = AITableQueries.getFieldValue(this.aiTable, [this.record()._id, this.field()._id]);
|
|
1684
1684
|
}
|
|
1685
|
+
applyContainerClass(className) {
|
|
1686
|
+
const container = this.elementRef.nativeElement.closest('.grid-cell-editor');
|
|
1687
|
+
if (container) {
|
|
1688
|
+
this.render2.addClass(container, className);
|
|
1689
|
+
}
|
|
1690
|
+
}
|
|
1685
1691
|
update() {
|
|
1686
1692
|
if (this.modelValue === AITableQueries.getFieldValue(this.aiTable, [this.record()._id, this.field()._id])) {
|
|
1687
1693
|
return;
|
|
@@ -11993,6 +11999,8 @@ class SelectCellEditorComponent extends AbstractEditCellEditor {
|
|
|
11993
11999
|
});
|
|
11994
12000
|
}
|
|
11995
12001
|
ngOnInit() {
|
|
12002
|
+
super.ngOnInit();
|
|
12003
|
+
this.applyContainerClass('has-select-cell');
|
|
11996
12004
|
this.modelValue = computed(() => {
|
|
11997
12005
|
const value = AITableQueries.getFieldValue(this.aiTable, [this.record()._id, this.field()._id]);
|
|
11998
12006
|
if (!this.isMultiple) {
|
|
@@ -12059,6 +12067,10 @@ class TextCellEditorComponent extends AbstractEditCellEditor {
|
|
|
12059
12067
|
super();
|
|
12060
12068
|
this.isSelectAll = input(false);
|
|
12061
12069
|
}
|
|
12070
|
+
ngOnInit() {
|
|
12071
|
+
super.ngOnInit();
|
|
12072
|
+
this.applyContainerClass('has-text-cell');
|
|
12073
|
+
}
|
|
12062
12074
|
ngAfterViewInit() {
|
|
12063
12075
|
// 解决闪烁线问题
|
|
12064
12076
|
queueMicrotask(() => {
|