@ai-table/grid 0.1.21 → 0.1.23

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 (35) hide show
  1. package/components/stat-type-menu/stat-type-menu.scss +12 -0
  2. package/components/stat-type-menu/stat-type-menucomponent.d.ts +17 -0
  3. package/components/stat-type-menu/stat-type-menucomponent.d.ts.map +1 -0
  4. package/constants/icon.d.ts +1 -0
  5. package/constants/icon.d.ts.map +1 -1
  6. package/constants/table.d.ts +2 -0
  7. package/constants/table.d.ts.map +1 -1
  8. package/fesm2022/ai-table-grid.mjs +513 -28
  9. package/fesm2022/ai-table-grid.mjs.map +1 -1
  10. package/grid.component.d.ts +5 -3
  11. package/grid.component.d.ts.map +1 -1
  12. package/package.json +1 -1
  13. package/renderer/components/field-stat/stat.component.d.ts +73 -0
  14. package/renderer/components/field-stat/stat.component.d.ts.map +1 -0
  15. package/renderer/components/field-stat/stats.component.d.ts +9 -0
  16. package/renderer/components/field-stat/stats.component.d.ts.map +1 -0
  17. package/renderer/components/fill-handle.component.d.ts +21 -0
  18. package/renderer/components/fill-handle.component.d.ts.map +1 -0
  19. package/renderer/creations/create-stats.d.ts +3 -0
  20. package/renderer/creations/create-stats.d.ts.map +1 -0
  21. package/renderer/renderer.component.d.ts +4 -1
  22. package/renderer/renderer.component.d.ts.map +1 -1
  23. package/services/selection.service.d.ts +1 -1
  24. package/services/selection.service.d.ts.map +1 -1
  25. package/types/component-config.d.ts +24 -0
  26. package/types/component-config.d.ts.map +1 -1
  27. package/types/grid.d.ts +3 -6
  28. package/types/grid.d.ts.map +1 -1
  29. package/utils/drag-fill/drag-fill.d.ts +18 -0
  30. package/utils/drag-fill/drag-fill.d.ts.map +1 -0
  31. package/utils/drag-fill/index.d.ts +2 -0
  32. package/utils/drag-fill/index.d.ts.map +1 -0
  33. package/utils/index.d.ts +1 -0
  34. package/utils/index.d.ts.map +1 -1
  35. package/utils/style.d.ts.map +1 -1
@@ -53,7 +53,7 @@ import { ThySelect, ThySelectModule } from 'ngx-tethys/select';
53
53
  import { ThyDot } from 'ngx-tethys/dot';
54
54
  import { ThyIcon } from 'ngx-tethys/icon';
55
55
  import { ThyTag } from 'ngx-tethys/tag';
56
- import { ThyDropdownMenuComponent, ThyDropdownMenuGroup, ThyDropdownDirective, ThyDropdownMenuItemDirective, ThyDropdownMenuItemIconDirective, ThyDropdownMenuItemNameDirective, ThyDropdownMenuItemExtendIconDirective, ThyDropdownAbstractMenu, ThyDropdownMenuItemMetaDirective } from 'ngx-tethys/dropdown';
56
+ import { ThyDropdownAbstractMenu, ThyDropdownMenuItemDirective, ThyDropdownMenuComponent, ThyDropdownMenuGroup, ThyDropdownDirective, ThyDropdownMenuItemIconDirective, ThyDropdownMenuItemNameDirective, ThyDropdownMenuItemExtendIconDirective, ThyDropdownMenuItemMetaDirective } from 'ngx-tethys/dropdown';
57
57
  import { ThySwitch } from 'ngx-tethys/switch';
58
58
  import { of, Subject, fromEvent, debounceTime, mergeWith, animationFrames, filter } from 'rxjs';
59
59
  import { isKeyHotkey } from 'is-hotkey';
@@ -1746,8 +1746,8 @@ class SelectCellEditorComponent extends AbstractEditCellEditor {
1746
1746
  }
1747
1747
  updateValueFn() {
1748
1748
  const value = (this.isMultiple ? this.modelValue : (this.modelValue && [this.modelValue]) || []);
1749
- const originValue = AITableQueries.getFieldValue(this.aiTable, [this.record()._id, this.field()._id]);
1750
- if (!value.every((v, i) => v === originValue[i]) || value.length !== originValue.length) {
1749
+ const originValue = AITableQueries.getFieldValue(this.aiTable, [this.record()._id, this.field()._id]) || [];
1750
+ if (value.length !== originValue.length || !value.every((v, i) => v === originValue[i])) {
1751
1751
  this.updateFieldValues.emit([
1752
1752
  {
1753
1753
  value: value,
@@ -2106,6 +2106,7 @@ const AI_TABLE_FIELD_HEAD_ICON_GAP_SIZE = 8; // 字段表列头图标的间距
2106
2106
  const AI_TABLE_FIELD_HEAD_MORE = 'AI_TABLE_FIELD_HEAD_MORE'; // 更多图标名称
2107
2107
  const AI_TABLE_FIELD_HEAD_OPACITY_LINE = 'AI_TABLE_FIELD_HEAD_OPACITY_LINE'; // 字段列头透明线
2108
2108
  const AI_TABLE_ROW_DRAG = 'AI_TABLE_ROW_DRAG'; // 行拖拽
2109
+ const AI_TABLE_FILL_HANDLE = 'AI_TABLE_FILL_HANDLE'; // 填充手柄
2109
2110
  const AI_TABLE_PREVENT_CLEAR_SELECTION_CLASS = '.ai-table-prevent-clear-selection';
2110
2111
  const AI_TABLE_ICON_COMMON_SIZE = 16; // 表格图标的通用尺寸
2111
2112
  const AI_TABLE_CELL = 'AI_TABLE_CELL'; // 单元格标识
@@ -2158,6 +2159,7 @@ const AI_TABLE_AUTO_SCROLL_LEFT_THRESHOLD = 40;
2158
2159
  const AI_TABLE_AUTO_SCROLL_RIGHT_THRESHOLD = 40;
2159
2160
  const AI_TABLE_AUTO_SCROLL_TOP_THRESHOLD = AI_TABLE_FIELD_HEAD_HEIGHT / 2;
2160
2161
  const AI_TABLE_AUTO_SCROLL_BOTTOM_THRESHOLD = AI_TABLE_FIELD_HEAD_HEIGHT / 2;
2162
+ const AI_TABLE_FIELD_STAT_HEIGHT = 48; // 字段统计高度
2161
2163
 
2162
2164
  const MIN_COLUMN_WIDTH = 80;
2163
2165
  const DBL_CLICK_EDIT_TYPE = [
@@ -2220,6 +2222,7 @@ const DepartmentOutlinedPath = `M3 5.5C3 3.567 4.567 2 6.5 2C8.433 2 10 3.567 10
2220
2222
  const AttachmentPath = `M9.1773124,11.8057395 C7.96668709,13.0163648 6.00387566,13.0163648 4.79325035,11.8057395 C3.58262505,10.5951142 3.58262505,8.63230278 4.78926443,7.4257012 L8.27628904,3.87217601 C8.50840068,3.63567937 8.88828274,3.63209333 9.12479868,3.86418566 C9.36131462,4.096278 9.36490066,4.47616006 9.13280833,4.712676 L5.64177849,8.27020561 C4.89978234,9.01220177 4.89978234,10.2152152 5.64177849,10.9572114 C6.38377464,11.6992075 7.5867881,11.6992075 8.32878426,10.9572114 L12.2321177,7.05387799 C13.3493901,5.93660552 13.2780395,4.02707269 12.0410949,2.79012806 C10.8041502,1.55318343 8.8946174,1.4818328 7.77734493,2.59910526 L3.72686067,6.64958953 C2.02034367,8.35610653 2.02835883,11.1329242 3.74721224,12.8517776 C5.46606565,14.570631 8.24288334,14.5786462 9.94940034,12.8721292 L13.5980637,9.22346588 C13.8323782,8.98915131 14.2122772,8.98915131 14.4465918,9.22346588 C14.6809064,9.45778046 14.6809064,9.83767945 14.4465918,10.071994 L10.7979285,13.7206573 C8.62168228,15.8969035 5.08507361,15.8866953 2.8986841,13.7003058 C0.712294592,11.5139163 0.702086332,7.97730759 2.87833253,5.8010614 L6.9288168,1.75057713 C8.52947856,0.149915361 11.1976354,0.249612361 12.889623,1.94159992 C14.5816106,3.63358749 14.6813076,6.30174436 13.0806458,7.90240612 L9.1773124,11.8057395 Z`;
2221
2223
  const EditPath = `M2,8.33918294 L10.7095952,0 L15,4.17020474 L6.53816398,13 L2,13 L2,8.33918294 Z M3.2,8.85157902 L3.2,11.8 L6.02608482,11.8 L13.3091776,4.20020516 L10.7033283,1.66736141 L3.2,8.85157902 Z M0,16 L0,14.8 L16,14.8 L16,16 L0,16 Z`;
2222
2224
  const RowDragPath = `M6,3 C6.55228475,3 7,2.55228475 7,2 C7,1.44771525 6.55228475,1 6,1 C5.44771525,1 5,1.44771525 5,2 C5,2.55228475 5.44771525,3 6,3 Z M10,3 C10.5522847,3 11,2.55228475 11,2 C11,1.44771525 10.5522847,1 10,1 C9.44771525,1 9,1.44771525 9,2 C9,2.55228475 9.44771525,3 10,3 Z M6,7 C6.55228475,7 7,6.55228475 7,6 C7,5.44771525 6.55228475,5 6,5 C5.44771525,5 5,5.44771525 5,6 C5,6.55228475 5.44771525,7 6,7 Z M10,7 C10.5522847,7 11,6.55228475 11,6 C11,5.44771525 10.5522847,5 10,5 C9.44771525,5 9,5.44771525 9,6 C9,6.55228475 9.44771525,7 10,7 Z M6,11 C6.55228475,11 7,10.5522847 7,10 C7,9.44771525 6.55228475,9 6,9 C5.44771525,9 5,9.44771525 5,10 C5,10.5522847 5.44771525,11 6,11 Z M10,11 C10.5522847,11 11,10.5522847 11,10 C11,9.44771525 10.5522847,9 10,9 C9.44771525,9 9,9.44771525 9,10 C9,10.5522847 9.44771525,11 10,11 Z M6,15 C6.55228475,15 7,14.5522847 7,14 C7,13.4477153 6.55228475,13 6,13 C5.44771525,13 5,13.4477153 5,14 C5,14.5522847 5.44771525,15 6,15 Z M10,15 C10.5522847,15 11,14.5522847 11,14 C11,13.4477153 10.5522847,13 10,13 C9.44771525,13 9,13.4477153 9,14 C9,14.5522847 9.44771525,15 10,15 Z`;
2225
+ const AngleDownPath = `M7.97815,11.99732 L7.9728,12.00267 L2.2998,6.33067 L3.1298,5.49967 L7.97807731,10.3479473 L12.8255,5.49967 L13.6565,6.33067 L7.9835,12.00267 L7.97815,11.99732 Z`;
2223
2226
  const IconPathMap = {};
2224
2227
 
2225
2228
  const DEFAULT_FONT_SIZE = 14;
@@ -3813,6 +3816,9 @@ const handleMouseStyle = (realTargetName, areaType = AITableAreaType.grid, conta
3813
3816
  case AI_TABLE_ROW_DRAG: {
3814
3817
  return setMouseStyle('pointer', container);
3815
3818
  }
3819
+ case AI_TABLE_FILL_HANDLE: {
3820
+ return setMouseStyle('crosshair', container);
3821
+ }
3816
3822
  default:
3817
3823
  return setMouseStyle('default', container);
3818
3824
  }
@@ -8038,6 +8044,64 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
8038
8044
  }]
8039
8045
  }] });
8040
8046
 
8047
+ class AITableFillHandle {
8048
+ constructor() {
8049
+ this.config = input.required();
8050
+ this.hasSelectedCells = computed(() => {
8051
+ return this.config().aiTable.selection().selectedCells.size > 0;
8052
+ });
8053
+ this.readonly = computed(() => {
8054
+ return this.config().readonly;
8055
+ });
8056
+ this.handleConfig = computed(() => {
8057
+ const { aiTable, coordinate } = this.config();
8058
+ const selectedCells = Array.from(aiTable.selection().selectedCells);
8059
+ const lastCell = selectedCells[selectedCells.length - 1];
8060
+ const [recordId, fieldId] = lastCell.split(':');
8061
+ const columnIndex = aiTable.context.visibleColumnsIndexMap().get(fieldId);
8062
+ const columnOffset = coordinate.getColumnOffset(columnIndex);
8063
+ const columnWidth = coordinate.getColumnWidth(columnIndex);
8064
+ const rowIndex = aiTable.context.visibleRowsIndexMap().get(recordId);
8065
+ const rowOffset = coordinate.getRowOffset(rowIndex);
8066
+ const width = 6;
8067
+ const height = 6;
8068
+ return {
8069
+ x: columnOffset + columnWidth - width / 2 + AI_TABLE_OFFSET,
8070
+ y: rowOffset + AI_TABLE_ROW_HEIGHT - height + AI_TABLE_CELL_BORDER + AI_TABLE_OFFSET,
8071
+ width,
8072
+ height,
8073
+ fill: Colors.primary,
8074
+ stroke: Colors.white,
8075
+ strokeWidth: 2,
8076
+ zIndex: 20,
8077
+ name: generateTargetName({
8078
+ targetName: AI_TABLE_FILL_HANDLE,
8079
+ fieldId,
8080
+ recordId
8081
+ })
8082
+ };
8083
+ });
8084
+ }
8085
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFillHandle, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
8086
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableFillHandle, isStandalone: true, selector: "ai-table-fill-handle", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: `
8087
+ @if (hasSelectedCells() && !readonly()) {
8088
+ <ko-rect [config]="handleConfig()"></ko-rect>
8089
+ }
8090
+ `, isInline: true, dependencies: [{ kind: "component", type: KoShape, selector: "ko-shape, ko-circle, ko-label, ko-rect, ko-ellipse, ko-wedge, ko-line, ko-sprite, ko-image, ko-text, ko-text-path, ko-star, ko-ring, ko-arc, ko-tag, ko-path, ko-regular-polygon, ko-arrow, ko-transformer", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }] }); }
8091
+ }
8092
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFillHandle, decorators: [{
8093
+ type: Component,
8094
+ args: [{
8095
+ selector: 'ai-table-fill-handle',
8096
+ template: `
8097
+ @if (hasSelectedCells() && !readonly()) {
8098
+ <ko-rect [config]="handleConfig()"></ko-rect>
8099
+ }
8100
+ `,
8101
+ imports: [KoShape]
8102
+ }]
8103
+ }] });
8104
+
8041
8105
  class AITableCoverCells {
8042
8106
  constructor() {
8043
8107
  this.config = input.required();
@@ -8145,6 +8209,256 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
8145
8209
  }]
8146
8210
  }] });
8147
8211
 
8212
+ const createFieldStats = (config) => {
8213
+ const { coordinate, columnStartIndex, columnStopIndex, aiTable, actions } = config;
8214
+ const colors = Colors;
8215
+ const { columnCount, rowInitSize: fieldHeadHeight } = coordinate;
8216
+ const fields = aiTable.gridData().fields;
8217
+ const fieldStats = [];
8218
+ for (let columnIndex = columnStartIndex; columnIndex <= columnStopIndex; columnIndex++) {
8219
+ if (columnIndex > columnCount - 1)
8220
+ break;
8221
+ if (columnIndex < 0)
8222
+ continue;
8223
+ const field = fields[columnIndex];
8224
+ if (field == null)
8225
+ continue;
8226
+ const x = coordinate.getColumnOffset(columnIndex);
8227
+ const columnWidth = coordinate.getColumnWidth(columnIndex);
8228
+ const fieldStat = {
8229
+ aiTable,
8230
+ coordinate,
8231
+ actions,
8232
+ x,
8233
+ y: coordinate.containerHeight - AI_TABLE_FIELD_STAT_HEIGHT,
8234
+ width: columnWidth,
8235
+ height: fieldHeadHeight,
8236
+ field,
8237
+ stroke: columnIndex === 0 ? colors.transparent : undefined
8238
+ };
8239
+ fieldStats.push(fieldStat);
8240
+ }
8241
+ return fieldStats;
8242
+ };
8243
+
8244
+ class AITableStatTypeMenu extends ThyDropdownAbstractMenu {
8245
+ constructor() {
8246
+ super(...arguments);
8247
+ this.field = input.required();
8248
+ this.aiTable = input.required();
8249
+ this.statMenus = input.required();
8250
+ this.menuClick = output();
8251
+ }
8252
+ execute(menu) {
8253
+ this.menuClick.emit({
8254
+ menu,
8255
+ field: this.field()
8256
+ });
8257
+ }
8258
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableStatTypeMenu, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
8259
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableStatTypeMenu, isStandalone: true, selector: "ai-table-stat-type-menu", inputs: { field: { classPropertyName: "field", publicName: "field", isSignal: true, isRequired: true, transformFunction: null }, aiTable: { classPropertyName: "aiTable", publicName: "aiTable", isSignal: true, isRequired: true, transformFunction: null }, statMenus: { classPropertyName: "statMenus", publicName: "statMenus", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { menuClick: "menuClick" }, host: { classAttribute: "stat-type-menu" }, usesInheritance: true, ngImport: i0, template: "@if (field()) {\n @for (menu of statMenus(); track index; let index = $index) {\n <a thyDropdownMenuItem href=\"javascript:;\" (click)=\"execute(menu)\">\n <span>{{ menu.name }}</span>\n </a>\n }\n}\n", dependencies: [{ kind: "directive", type: ThyDropdownMenuItemDirective, selector: "[thyDropdownMenuItem]", inputs: ["thyType", "thyDisabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
8260
+ }
8261
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableStatTypeMenu, decorators: [{
8262
+ type: Component,
8263
+ args: [{ selector: 'ai-table-stat-type-menu', changeDetection: ChangeDetectionStrategy.OnPush, host: {
8264
+ class: 'stat-type-menu'
8265
+ }, imports: [ThyDropdownMenuItemDirective], template: "@if (field()) {\n @for (menu of statMenus(); track index; let index = $index) {\n <a thyDropdownMenuItem href=\"javascript:;\" (click)=\"execute(menu)\">\n <span>{{ menu.name }}</span>\n </a>\n }\n}\n" }]
8266
+ }] });
8267
+
8268
+ class AITableFieldStat {
8269
+ constructor() {
8270
+ this.thyPopover = inject(ThyPopover);
8271
+ this.config = input.required();
8272
+ this.textOffset = AI_TABLE_CELL_PADDING + AI_TABLE_ICON_COMMON_SIZE + AI_TABLE_FIELD_HEAD_ICON_GAP_SIZE;
8273
+ this.textMeasure = TextMeasure();
8274
+ this.availableTextWidth = computed(() => {
8275
+ const { width } = this.config();
8276
+ return width - AI_TABLE_ICON_COMMON_SIZE;
8277
+ });
8278
+ this.textData = computed(() => {
8279
+ const fieldName = this.config().field.name.replace(/\r|\n/g, ' ');
8280
+ this.textMeasure.setFont({ fontSize: DEFAULT_FONT_SIZE });
8281
+ const { width, height, isOverflow } = this.textMeasure.measureText(fieldName, this.availableTextWidth(), 1);
8282
+ return {
8283
+ width: Math.min(width, this.availableTextWidth()),
8284
+ height,
8285
+ isOverflow
8286
+ };
8287
+ });
8288
+ this.groupConfig = computed(() => {
8289
+ return {
8290
+ x: this.config().x,
8291
+ y: this.config().y
8292
+ };
8293
+ });
8294
+ this.bgConfig = computed(() => {
8295
+ const { field, width, height } = this.config();
8296
+ return {
8297
+ x: AI_TABLE_OFFSET,
8298
+ y: AI_TABLE_OFFSET,
8299
+ name: generateTargetName({
8300
+ targetName: 'sss',
8301
+ fieldId: field._id,
8302
+ mouseStyle: 'pointer'
8303
+ }),
8304
+ width: width,
8305
+ height: height,
8306
+ fill: Colors.white,
8307
+ stroke: Colors.gray200,
8308
+ strokeWidth: 1,
8309
+ opacity: 1
8310
+ };
8311
+ });
8312
+ this.field = computed(() => {
8313
+ const { field } = this.config();
8314
+ return field;
8315
+ });
8316
+ this.records = computed(() => {
8317
+ const { aiTable } = this.config();
8318
+ return aiTable.records;
8319
+ });
8320
+ this.statValue = computed(() => {
8321
+ const field = this.field();
8322
+ const records = this.records();
8323
+ const fieldModel = FieldModelMap[field.type];
8324
+ const result = fieldModel.getStatFormatValue(field, records());
8325
+ return result;
8326
+ });
8327
+ this.textConfig = computed(() => {
8328
+ const { field, height, aiTable } = this.config();
8329
+ const text = this.statValue();
8330
+ if (text) {
8331
+ return {
8332
+ x: this.textOffset,
8333
+ y: 0,
8334
+ width: Math.max(this.textData().width, AI_TABLE_FIELD_HEAD_TEXT_MIN_WIDTH),
8335
+ height: height + 2,
8336
+ text: this.statValue(),
8337
+ lineHeight: 1.84
8338
+ };
8339
+ }
8340
+ return null;
8341
+ });
8342
+ this.iconConfig = computed(() => {
8343
+ const { field, width, height } = this.config();
8344
+ const commonIconOffsetY = (height - AI_TABLE_ACTION_COMMON_SIZE) / 2;
8345
+ return {
8346
+ x: width - AI_TABLE_ACTION_COMMON_SIZE,
8347
+ y: commonIconOffsetY,
8348
+ data: AngleDownPath,
8349
+ fill: Colors.gray600,
8350
+ background: Colors.transparent,
8351
+ backgroundWidth: AI_TABLE_ACTION_COMMON_SIZE,
8352
+ backgroundHeight: AI_TABLE_ACTION_COMMON_SIZE,
8353
+ cornerRadius: 4,
8354
+ listening: false
8355
+ };
8356
+ });
8357
+ }
8358
+ clickStat(e) {
8359
+ e.event.evt.stopPropagation();
8360
+ const { aiTable, coordinate, field, actions } = this.config();
8361
+ const statRect = e.event.target.getClientRect();
8362
+ const fieldGroupRect = e.event.target.getParent()?.getParent()?.getClientRect();
8363
+ const containerRect = coordinate.container.getBoundingClientRect();
8364
+ const position = {
8365
+ x: containerRect.x + statRect.x,
8366
+ y: containerRect.y + statRect.y + statRect.height - 50
8367
+ };
8368
+ const editFieldPosition = {
8369
+ x: containerRect.x + fieldGroupRect.x - AI_TABLE_CELL_PADDING,
8370
+ y: containerRect.y + fieldGroupRect.y + fieldGroupRect.height
8371
+ };
8372
+ const editOrigin = coordinate.container.querySelector('.konvajs-content');
8373
+ const fieldModel = FieldModelMap[field.type];
8374
+ const ref = this.thyPopover.open(AITableStatTypeMenu, {
8375
+ origin: coordinate.container,
8376
+ originPosition: position,
8377
+ placement: 'topLeft',
8378
+ originActiveClass: undefined,
8379
+ insideClosable: true,
8380
+ initialState: {
8381
+ origin: editOrigin,
8382
+ position: editFieldPosition,
8383
+ aiTable,
8384
+ field,
8385
+ statMenus: fieldModel.statTypes
8386
+ // fieldMenus:
8387
+ }
8388
+ });
8389
+ ref.componentInstance.menuClick.subscribe((event) => {
8390
+ actions.setField({
8391
+ ...event.field,
8392
+ stat_type: event.menu.type
8393
+ });
8394
+ });
8395
+ }
8396
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFieldStat, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
8397
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableFieldStat, isStandalone: true, selector: "ai-table-field-stat", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: `
8398
+ <ko-group [config]="groupConfig()">
8399
+ <ko-rect [config]="bgConfig()" (koClick)="clickStat($event)"></ko-rect>
8400
+ @if (textConfig()) {
8401
+ <ko-group>
8402
+ <ai-table-text [config]="textConfig()!"></ai-table-text>
8403
+ <ai-table-icon [config]="iconConfig()"></ai-table-icon>
8404
+ </ko-group>
8405
+ }
8406
+ </ko-group>
8407
+ `, isInline: true, dependencies: [{ kind: "component", type: KoContainer, selector: "ko-layer, ko-fastlayer, ko-group" }, { kind: "component", type: KoShape, selector: "ko-shape, ko-circle, ko-label, ko-rect, ko-ellipse, ko-wedge, ko-line, ko-sprite, ko-image, ko-text, ko-text-path, ko-star, ko-ring, ko-arc, ko-tag, ko-path, ko-regular-polygon, ko-arrow, ko-transformer", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }, { kind: "component", type: AITableTextComponent, selector: "ai-table-text", inputs: ["config"], outputs: ["koClick", "koMouseMove"] }, { kind: "component", type: AITableIcon, selector: "ai-table-icon", inputs: ["config"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
8408
+ }
8409
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFieldStat, decorators: [{
8410
+ type: Component,
8411
+ args: [{
8412
+ selector: 'ai-table-field-stat',
8413
+ template: `
8414
+ <ko-group [config]="groupConfig()">
8415
+ <ko-rect [config]="bgConfig()" (koClick)="clickStat($event)"></ko-rect>
8416
+ @if (textConfig()) {
8417
+ <ko-group>
8418
+ <ai-table-text [config]="textConfig()!"></ai-table-text>
8419
+ <ai-table-icon [config]="iconConfig()"></ai-table-icon>
8420
+ </ko-group>
8421
+ }
8422
+ </ko-group>
8423
+ `,
8424
+ imports: [KoContainer, KoShape, AITableTextComponent, AITableIcon],
8425
+ changeDetection: ChangeDetectionStrategy.OnPush
8426
+ }]
8427
+ }] });
8428
+
8429
+ class AITableFieldStats {
8430
+ constructor() {
8431
+ this.config = input.required();
8432
+ this.statConfigs = computed(() => {
8433
+ const { coordinate, columnStartIndex } = this.config();
8434
+ const { frozenColumnCount } = coordinate;
8435
+ return createFieldStats({
8436
+ ...this.config(),
8437
+ columnStartIndex: Math.max(columnStartIndex, frozenColumnCount)
8438
+ });
8439
+ });
8440
+ }
8441
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFieldStats, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
8442
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableFieldStats, isStandalone: true, selector: "ai-table-column-stats", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: `
8443
+ @for (config of statConfigs(); track $index) {
8444
+ <ai-table-field-stat [config]="config"></ai-table-field-stat>
8445
+ }
8446
+ `, isInline: true, dependencies: [{ kind: "component", type: AITableFieldStat, selector: "ai-table-field-stat", inputs: ["config"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
8447
+ }
8448
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFieldStats, decorators: [{
8449
+ type: Component,
8450
+ args: [{
8451
+ selector: 'ai-table-column-stats',
8452
+ template: `
8453
+ @for (config of statConfigs(); track $index) {
8454
+ <ai-table-field-stat [config]="config"></ai-table-field-stat>
8455
+ }
8456
+ `,
8457
+ imports: [AITableFieldStat],
8458
+ changeDetection: ChangeDetectionStrategy.OnPush
8459
+ }]
8460
+ }] });
8461
+
8148
8462
  Konva.pixelRatio = 2;
8149
8463
  class AITableRenderer {
8150
8464
  constructor() {
@@ -8229,7 +8543,7 @@ class AITableRenderer {
8229
8543
  return {
8230
8544
  clipX: 0,
8231
8545
  clipY: this.coordinate().rowInitSize - 1,
8232
- clipWidth: this.frozenAreaWidth(),
8546
+ clipWidth: this.frozenAreaWidth() + 10,
8233
8547
  clipHeight: this.containerHeight() - this.coordinate().rowInitSize
8234
8548
  };
8235
8549
  });
@@ -8262,11 +8576,12 @@ class AITableRenderer {
8262
8576
  });
8263
8577
  this.columnHeadOrAddFieldConfig = computed(() => {
8264
8578
  const { columnStartIndex, columnStopIndex } = this.visibleRangeInfo();
8265
- const { aiTable, coordinate, readonly, maxFields } = this.config();
8579
+ const { aiTable, coordinate, readonly, maxFields, actions } = this.config();
8266
8580
  const { pointPosition } = aiTable.context;
8267
8581
  const fields = this.fields();
8268
8582
  return {
8269
8583
  aiTable,
8584
+ actions,
8270
8585
  coordinate,
8271
8586
  fields,
8272
8587
  columnStartIndex,
@@ -8292,6 +8607,23 @@ class AITableRenderer {
8292
8607
  maxRecords
8293
8608
  };
8294
8609
  });
8610
+ this.fillHandleConfig = computed(() => {
8611
+ return {
8612
+ aiTable: this.config().aiTable,
8613
+ coordinate: this.coordinate(),
8614
+ readonly: this.readonly()
8615
+ };
8616
+ });
8617
+ this.isLastSelectedCellInFrozenColumn = computed(() => {
8618
+ const { aiTable } = this.config();
8619
+ const selectedCells = Array.from(aiTable.selection().selectedCells);
8620
+ if (selectedCells.length === 0)
8621
+ return false;
8622
+ const lastCell = selectedCells[selectedCells.length - 1];
8623
+ const [, fieldId] = lastCell.split(':');
8624
+ const columnIndex = aiTable.context.visibleColumnsIndexMap().get(fieldId);
8625
+ return AITable.isFrozenColumn(aiTable, columnIndex);
8626
+ });
8295
8627
  this.activeCellBorderConfig = computed(() => {
8296
8628
  return createActiveCellBorder(this.cellsConfig());
8297
8629
  });
@@ -8338,7 +8670,7 @@ class AITableRenderer {
8338
8670
  this.koMouseleave.emit(e);
8339
8671
  }
8340
8672
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableRenderer, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
8341
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableRenderer, isStandalone: true, selector: "ai-table-renderer", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { koMousemove: "koMousemove", koMousedown: "koMousedown", koMouseup: "koMouseup", koContextmenu: "koContextmenu", koWheel: "koWheel", koClick: "koClick", koDblclick: "koDblclick", koMouseleave: "koMouseleave" }, ngImport: i0, template: "<ko-stage\n [config]=\"stageConfig()\"\n (koMousemove)=\"stageMousemove($event)\"\n (koMousedown)=\"stageMousedown($event)\"\n (koMouseup)=\"stageMouseup($event)\"\n (koContextmenu)=\"stageContextmenu($event)\"\n (koClick)=\"stageClick($event)\"\n (koDblclick)=\"stageDblclick($event)\"\n (koMouseleave)=\"stageMouseleave($event)\"\n>\n <ko-layer>\n <ko-group [config]=\"gridGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-frozen-cells [config]=\"cellsConfig()\"></ai-table-frozen-cells>\n <ai-table-other-rows [config]=\"cellsConfig()\"></ai-table-other-rows>\n @if (!hiddenIndexColumn()) {\n <ai-table-hover-row-heads [config]=\"cellsConfig()\"></ai-table-hover-row-heads>\n }\n <ai-table-frozen-placeholder-cells [config]=\"cellsConfig()\"></ai-table-frozen-placeholder-cells>\n </ko-group>\n\n <ko-group>\n <ai-table-frozen-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-frozen-column-heads>\n </ko-group>\n\n <ko-group [config]=\"commonGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n <ai-table-cells [config]=\"cellsConfig()\"></ai-table-cells>\n <ai-table-placeholder-cells [config]=\"cellsConfig()\"></ai-table-placeholder-cells>\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n\n <ko-group [config]=\"offsetXConfig()\">\n <ai-table-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-heads>\n <ai-table-add-field [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-add-field>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"attachGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n @if (activeCellBorderConfig().activeCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().activeCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().expandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenCoverAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n @if (activeCellBorderConfig().frozenActiveCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().frozenActiveCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().frozenExpandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n </ko-group>\n </ko-group>\n </ko-group>\n </ko-layer>\n</ko-stage>\n\n<ng-content></ng-content>\n", dependencies: [{ kind: "component", type: KoContainer, selector: "ko-layer, ko-fastlayer, ko-group" }, { kind: "component", type: KoStage, selector: "ko-stage", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }, { kind: "component", type: KoShape, selector: "ko-shape, ko-circle, ko-label, ko-rect, ko-ellipse, ko-wedge, ko-line, ko-sprite, ko-image, ko-text, ko-text-path, ko-star, ko-ring, ko-arc, ko-tag, ko-path, ko-regular-polygon, ko-arrow, ko-transformer", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }, { kind: "component", type: AITableColumnHeads, selector: "ai-table-column-heads", inputs: ["config"] }, { kind: "component", type: AITableFrozenColumnHeads, selector: "ai-table-frozen-column-heads", inputs: ["config"] }, { kind: "component", type: AITableCells, selector: "ai-table-cells", inputs: ["config"] }, { kind: "component", type: AITableFrozenCells, selector: "ai-table-frozen-cells", inputs: ["config"] }, { kind: "component", type: AITableFrozenPlaceholderCells, selector: "ai-table-frozen-placeholder-cells", inputs: ["config"] }, { kind: "component", type: AITableCoverCells, selector: "ai-table-cover-cell", inputs: ["config", "onlyDisplayBorder"] }, { kind: "component", type: AITablePlaceholderCells, selector: "ai-table-placeholder-cells", inputs: ["config"] }, { kind: "component", type: AITableAddField, selector: "ai-table-add-field", inputs: ["config"] }, { kind: "component", type: AITableHoverRowHeads, selector: "ai-table-hover-row-heads", inputs: ["config"] }, { kind: "component", type: AITableOtherRows, selector: "ai-table-other-rows", inputs: ["config"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
8673
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableRenderer, isStandalone: true, selector: "ai-table-renderer", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { koMousemove: "koMousemove", koMousedown: "koMousedown", koMouseup: "koMouseup", koContextmenu: "koContextmenu", koWheel: "koWheel", koClick: "koClick", koDblclick: "koDblclick", koMouseleave: "koMouseleave" }, ngImport: i0, template: "<ko-stage\n [config]=\"stageConfig()\"\n (koMousemove)=\"stageMousemove($event)\"\n (koMousedown)=\"stageMousedown($event)\"\n (koMouseup)=\"stageMouseup($event)\"\n (koContextmenu)=\"stageContextmenu($event)\"\n (koClick)=\"stageClick($event)\"\n (koDblclick)=\"stageDblclick($event)\"\n (koMouseleave)=\"stageMouseleave($event)\"\n>\n <ko-layer>\n <ko-group [config]=\"gridGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-frozen-cells [config]=\"cellsConfig()\"></ai-table-frozen-cells>\n <ai-table-other-rows [config]=\"cellsConfig()\"></ai-table-other-rows>\n @if (!hiddenIndexColumn()) {\n <ai-table-hover-row-heads [config]=\"cellsConfig()\"></ai-table-hover-row-heads>\n }\n <ai-table-frozen-placeholder-cells [config]=\"cellsConfig()\"></ai-table-frozen-placeholder-cells>\n </ko-group>\n\n <ko-group>\n <ai-table-frozen-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-frozen-column-heads>\n </ko-group>\n\n <ko-group [config]=\"commonGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n <ai-table-cells [config]=\"cellsConfig()\"></ai-table-cells>\n <ai-table-placeholder-cells [config]=\"cellsConfig()\"></ai-table-placeholder-cells>\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n\n <ko-group [config]=\"offsetXConfig()\">\n <ai-table-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-heads>\n <ai-table-add-field [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-add-field>\n <ai-table-column-stats [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-stats>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"attachGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n @if (activeCellBorderConfig().activeCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().activeCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().expandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n @if (!isLastSelectedCellInFrozenColumn()) {\n <ai-table-fill-handle [config]=\"fillHandleConfig()\"></ai-table-fill-handle>\n }\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenCoverAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n @if (activeCellBorderConfig().frozenActiveCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().frozenActiveCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().frozenExpandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n @if (isLastSelectedCellInFrozenColumn()) {\n <ai-table-fill-handle [config]=\"fillHandleConfig()\"></ai-table-fill-handle>\n }\n </ko-group>\n </ko-group>\n </ko-group>\n </ko-layer>\n</ko-stage>\n\n<ng-content></ng-content>\n", dependencies: [{ kind: "component", type: KoContainer, selector: "ko-layer, ko-fastlayer, ko-group" }, { kind: "component", type: KoStage, selector: "ko-stage", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }, { kind: "component", type: KoShape, selector: "ko-shape, ko-circle, ko-label, ko-rect, ko-ellipse, ko-wedge, ko-line, ko-sprite, ko-image, ko-text, ko-text-path, ko-star, ko-ring, ko-arc, ko-tag, ko-path, ko-regular-polygon, ko-arrow, ko-transformer", inputs: ["config"], outputs: ["koMouseover", "koMousemove", "koMouseout", "koMouseenter", "koMouseleave", "koMousedown", "koMouseup", "koWheel", "koContextmenu", "koClick", "koDblclick", "koTouchstart", "koTouchmove", "koTouchend", "koTap", "koDbltap", "koDragstart", "koDragmove", "koDragend"] }, { kind: "component", type: AITableColumnHeads, selector: "ai-table-column-heads", inputs: ["config"] }, { kind: "component", type: AITableFrozenColumnHeads, selector: "ai-table-frozen-column-heads", inputs: ["config"] }, { kind: "component", type: AITableCells, selector: "ai-table-cells", inputs: ["config"] }, { kind: "component", type: AITableFrozenCells, selector: "ai-table-frozen-cells", inputs: ["config"] }, { kind: "component", type: AITableFrozenPlaceholderCells, selector: "ai-table-frozen-placeholder-cells", inputs: ["config"] }, { kind: "component", type: AITableCoverCells, selector: "ai-table-cover-cell", inputs: ["config", "onlyDisplayBorder"] }, { kind: "component", type: AITablePlaceholderCells, selector: "ai-table-placeholder-cells", inputs: ["config"] }, { kind: "component", type: AITableAddField, selector: "ai-table-add-field", inputs: ["config"] }, { kind: "component", type: AITableHoverRowHeads, selector: "ai-table-hover-row-heads", inputs: ["config"] }, { kind: "component", type: AITableOtherRows, selector: "ai-table-other-rows", inputs: ["config"] }, { kind: "component", type: AITableFillHandle, selector: "ai-table-fill-handle", inputs: ["config"] }, { kind: "component", type: AITableFieldStats, selector: "ai-table-column-stats", inputs: ["config"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
8342
8674
  }
8343
8675
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableRenderer, decorators: [{
8344
8676
  type: Component,
@@ -8355,8 +8687,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
8355
8687
  AITablePlaceholderCells,
8356
8688
  AITableAddField,
8357
8689
  AITableHoverRowHeads,
8358
- AITableOtherRows
8359
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<ko-stage\n [config]=\"stageConfig()\"\n (koMousemove)=\"stageMousemove($event)\"\n (koMousedown)=\"stageMousedown($event)\"\n (koMouseup)=\"stageMouseup($event)\"\n (koContextmenu)=\"stageContextmenu($event)\"\n (koClick)=\"stageClick($event)\"\n (koDblclick)=\"stageDblclick($event)\"\n (koMouseleave)=\"stageMouseleave($event)\"\n>\n <ko-layer>\n <ko-group [config]=\"gridGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-frozen-cells [config]=\"cellsConfig()\"></ai-table-frozen-cells>\n <ai-table-other-rows [config]=\"cellsConfig()\"></ai-table-other-rows>\n @if (!hiddenIndexColumn()) {\n <ai-table-hover-row-heads [config]=\"cellsConfig()\"></ai-table-hover-row-heads>\n }\n <ai-table-frozen-placeholder-cells [config]=\"cellsConfig()\"></ai-table-frozen-placeholder-cells>\n </ko-group>\n\n <ko-group>\n <ai-table-frozen-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-frozen-column-heads>\n </ko-group>\n\n <ko-group [config]=\"commonGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n <ai-table-cells [config]=\"cellsConfig()\"></ai-table-cells>\n <ai-table-placeholder-cells [config]=\"cellsConfig()\"></ai-table-placeholder-cells>\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n\n <ko-group [config]=\"offsetXConfig()\">\n <ai-table-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-heads>\n <ai-table-add-field [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-add-field>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"attachGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n @if (activeCellBorderConfig().activeCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().activeCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().expandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenCoverAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n @if (activeCellBorderConfig().frozenActiveCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().frozenActiveCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().frozenExpandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n </ko-group>\n </ko-group>\n </ko-group>\n </ko-layer>\n</ko-stage>\n\n<ng-content></ng-content>\n" }]
8690
+ AITableOtherRows,
8691
+ AITableFillHandle,
8692
+ AITableFieldStats
8693
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<ko-stage\n [config]=\"stageConfig()\"\n (koMousemove)=\"stageMousemove($event)\"\n (koMousedown)=\"stageMousedown($event)\"\n (koMouseup)=\"stageMouseup($event)\"\n (koContextmenu)=\"stageContextmenu($event)\"\n (koClick)=\"stageClick($event)\"\n (koDblclick)=\"stageDblclick($event)\"\n (koMouseleave)=\"stageMouseleave($event)\"\n>\n <ko-layer>\n <ko-group [config]=\"gridGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-frozen-cells [config]=\"cellsConfig()\"></ai-table-frozen-cells>\n <ai-table-other-rows [config]=\"cellsConfig()\"></ai-table-other-rows>\n @if (!hiddenIndexColumn()) {\n <ai-table-hover-row-heads [config]=\"cellsConfig()\"></ai-table-hover-row-heads>\n }\n <ai-table-frozen-placeholder-cells [config]=\"cellsConfig()\"></ai-table-frozen-placeholder-cells>\n </ko-group>\n\n <ko-group>\n <ai-table-frozen-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-frozen-column-heads>\n </ko-group>\n\n <ko-group [config]=\"commonGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n <ai-table-cells [config]=\"cellsConfig()\"></ai-table-cells>\n <ai-table-placeholder-cells [config]=\"cellsConfig()\"></ai-table-placeholder-cells>\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n\n <ko-group [config]=\"offsetXConfig()\">\n <ai-table-column-heads [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-heads>\n <ai-table-add-field [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-add-field>\n <ai-table-column-stats [config]=\"columnHeadOrAddFieldConfig()\"></ai-table-column-stats>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"attachGroupConfig()\">\n <ko-group [config]=\"offsetConfig()\">\n @if (activeCellBorderConfig().activeCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().activeCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().expandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n @if (!isLastSelectedCellInFrozenColumn()) {\n <ai-table-fill-handle [config]=\"fillHandleConfig()\"></ai-table-fill-handle>\n }\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenCoverAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n <ai-table-cover-cell [config]=\"cellsConfig()\"></ai-table-cover-cell>\n </ko-group>\n </ko-group>\n\n <ko-group [config]=\"frozenAttachGroupConfig()\">\n <ko-group [config]=\"offsetYConfig()\">\n @if (activeCellBorderConfig().frozenActiveCellBorder) {\n <ko-rect [config]=\"activeCellBorderConfig().frozenActiveCellBorder!\"></ko-rect>\n }\n @if (showExpandCellBorder().frozenExpandCellBorder) {\n <ai-table-cover-cell [config]=\"cellsConfig()\" [onlyDisplayBorder]=\"true\"></ai-table-cover-cell>\n }\n @if (isLastSelectedCellInFrozenColumn()) {\n <ai-table-fill-handle [config]=\"fillHandleConfig()\"></ai-table-fill-handle>\n }\n </ko-group>\n </ko-group>\n </ko-group>\n </ko-layer>\n</ko-stage>\n\n<ng-content></ng-content>\n" }]
8360
8694
  }] });
8361
8695
 
8362
8696
  class AITableCellRate extends CoverCellComponent {
@@ -8889,6 +9223,106 @@ function aiTableRectConfigToKonvaConfig(rectConfig, options) {
8889
9223
  return result;
8890
9224
  }
8891
9225
 
9226
+ function getFillDirection(aiTable, sourceCells, mouseUpRecordId) {
9227
+ const { startCell: sourceStartCell, endCell: sourceEndCell } = getStartAndEndCell(sourceCells);
9228
+ const currentRowIndex = aiTable.context.visibleRowsIndexMap().get(mouseUpRecordId);
9229
+ const sourceStartRowIndex = aiTable.context.visibleRowsIndexMap().get(sourceStartCell[0]);
9230
+ const sourceEndRowIndex = aiTable.context.visibleRowsIndexMap().get(sourceEndCell[0]);
9231
+ if (currentRowIndex < sourceStartRowIndex) {
9232
+ return 'upward';
9233
+ }
9234
+ else if (currentRowIndex > sourceEndRowIndex) {
9235
+ return 'downward';
9236
+ }
9237
+ else {
9238
+ return undefined;
9239
+ }
9240
+ }
9241
+ function dragFillHighlightArea(aiTable, sourceCells, currentRecordId) {
9242
+ const { startCell: sourceStartCell, endCell: sourceEndCell } = getStartAndEndCell(sourceCells);
9243
+ const direction = getFillDirection(aiTable, sourceCells, currentRecordId);
9244
+ const sourceStartCellFieldId = sourceStartCell[1];
9245
+ const sourceEndCellFieldId = sourceEndCell[1];
9246
+ let highlightStartCell;
9247
+ let highlightEndCell;
9248
+ if (direction === 'downward') {
9249
+ highlightStartCell = sourceStartCell;
9250
+ highlightEndCell = [currentRecordId, sourceEndCellFieldId];
9251
+ }
9252
+ else if (direction === 'upward') {
9253
+ highlightStartCell = [currentRecordId, sourceStartCellFieldId];
9254
+ highlightEndCell = sourceEndCell;
9255
+ }
9256
+ else {
9257
+ highlightStartCell = sourceStartCell;
9258
+ highlightEndCell = sourceEndCell;
9259
+ }
9260
+ return { highlightStartCell, highlightEndCell };
9261
+ }
9262
+ function performFill(aiTable, sourceCells, mouseUpRecordId, actions) {
9263
+ const selectedCells = Array.from(aiTable.selection().selectedCells);
9264
+ if (sourceCells.size === 0 || selectedCells.length === 0) {
9265
+ return;
9266
+ }
9267
+ const { startCell: sourceStartCell, endCell: sourceEndCell } = getStartAndEndCell(sourceCells);
9268
+ const visibleRowsIndexMap = aiTable.context.visibleRowsIndexMap();
9269
+ const sourceStartRowIndex = visibleRowsIndexMap.get(sourceStartCell[0]);
9270
+ const sourceEndRowIndex = visibleRowsIndexMap.get(sourceEndCell[0]);
9271
+ const selectedEndCell = selectedCells[selectedCells.length - 1].split(':');
9272
+ const selectedEndRowIndex = visibleRowsIndexMap.get(selectedEndCell[0]);
9273
+ let targetStartRowIndex;
9274
+ let targetEndRowIndex;
9275
+ const direction = getFillDirection(aiTable, sourceCells, mouseUpRecordId);
9276
+ if (direction === 'downward') {
9277
+ targetStartRowIndex = sourceEndRowIndex + 1;
9278
+ targetEndRowIndex = selectedEndRowIndex;
9279
+ }
9280
+ else {
9281
+ const selectedFirstCell = selectedCells[0].split(':');
9282
+ const selectedFirstRowIndex = visibleRowsIndexMap.get(selectedFirstCell[0]);
9283
+ targetStartRowIndex = selectedFirstRowIndex;
9284
+ targetEndRowIndex = sourceStartRowIndex - 1;
9285
+ }
9286
+ const sourceRowCount = sourceEndRowIndex - sourceStartRowIndex + 1;
9287
+ const sourceRows = [];
9288
+ const linearRows = aiTable.context.linearRows();
9289
+ for (let i = sourceStartRowIndex; i <= sourceEndRowIndex; i++) {
9290
+ sourceRows.push(linearRows[i]._id);
9291
+ }
9292
+ const updateData = [];
9293
+ const fields = AITable.getVisibleFields(aiTable);
9294
+ const visibleColumnsIndexMap = aiTable.context.visibleColumnsIndexMap();
9295
+ const recordsMap = aiTable.recordsMap();
9296
+ const startFieldIndex = visibleColumnsIndexMap.get(sourceStartCell[1]);
9297
+ const endFieldIndex = visibleColumnsIndexMap.get(sourceEndCell[1]);
9298
+ for (let index = startFieldIndex; index <= endFieldIndex; index++) {
9299
+ const fieldId = fields[index]._id;
9300
+ for (let rowIndex = targetStartRowIndex; rowIndex <= targetEndRowIndex; rowIndex++) {
9301
+ const targetRecordId = linearRows[rowIndex]._id;
9302
+ const relativeRowIndex = direction === 'downward' ? rowIndex - targetStartRowIndex : targetEndRowIndex - rowIndex;
9303
+ const mod = relativeRowIndex % sourceRowCount;
9304
+ const sourceRowIndex = direction === 'downward' ? mod : sourceRowCount - 1 - mod;
9305
+ const sourceRecordId = sourceRows[sourceRowIndex];
9306
+ const sourceValue = recordsMap[sourceRecordId]?.values[fieldId];
9307
+ updateData.push({
9308
+ path: [targetRecordId, fieldId],
9309
+ value: sourceValue
9310
+ });
9311
+ }
9312
+ }
9313
+ if (updateData.length > 0) {
9314
+ actions.updateFieldValues(updateData);
9315
+ }
9316
+ }
9317
+ function getStartAndEndCell(selectedCells) {
9318
+ const selectedCellsArray = Array.from(selectedCells);
9319
+ const firstCell = selectedCellsArray[0].split(':');
9320
+ const lastCell = selectedCellsArray[selectedCellsArray.length - 1].split(':');
9321
+ const startCell = [firstCell[0], firstCell[1]];
9322
+ const endCell = [lastCell[0], lastCell[1]];
9323
+ return { startCell, endCell };
9324
+ }
9325
+
8892
9326
  class AITableFieldSetting {
8893
9327
  constructor() {
8894
9328
  this.aiEditField = model.required();
@@ -9138,7 +9572,7 @@ class AITableGridSelectionService {
9138
9572
  this.clearSelection();
9139
9573
  }
9140
9574
  }
9141
- selectCells(startCell, endCell) {
9575
+ selectCells(startCell, endCell, activeCell) {
9142
9576
  const [startRecordId, startFieldId] = startCell;
9143
9577
  const records = this.aiTable.context.linearRows();
9144
9578
  const fields = AITable.getVisibleFields(this.aiTable);
@@ -9163,7 +9597,7 @@ class AITableGridSelectionService {
9163
9597
  }
9164
9598
  }
9165
9599
  this.clearSelection();
9166
- this.setActiveCell(startCell);
9600
+ this.setActiveCell(activeCell || startCell);
9167
9601
  this.aiTable.selection().selectedCells = selectedCells;
9168
9602
  }
9169
9603
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableGridSelectionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
@@ -10333,9 +10767,15 @@ class AITableGrid extends AITableGridBase {
10333
10767
  constructor() {
10334
10768
  super();
10335
10769
  this.viewContainerRef = inject(ViewContainerRef);
10336
- this.isDragSelecting = false;
10337
10770
  this.isDragSelectionAutoScrolling = false;
10338
- this.dragSelectionStart = null;
10771
+ this.dragSelectState = {
10772
+ isDragging: false,
10773
+ startCell: null
10774
+ };
10775
+ this.dragFillState = {
10776
+ isDragging: false,
10777
+ sourceCells: new Set()
10778
+ };
10339
10779
  this.notifyService = inject(ThyNotifyService);
10340
10780
  this.scrollControllerService = inject(AITableScrollControllerService);
10341
10781
  this.isPopoverOpen = false;
@@ -10623,13 +11063,25 @@ class AITableGrid extends AITableGridBase {
10623
11063
  this.setDefaultPointPosition();
10624
11064
  }
10625
11065
  this.timer = null;
10626
- if (this.isDragSelecting) {
11066
+ if (this.dragSelectState.isDragging || this.dragFillState.isDragging) {
10627
11067
  const { fieldId, recordId } = getDetailByTargetName(curMousePosition.realTargetName);
10628
11068
  if (fieldId && recordId) {
10629
- const startCell = this.dragSelectionStart;
10630
- const endCell = [recordId, fieldId];
11069
+ let startCell;
11070
+ let endCell;
11071
+ let activeCell = null;
11072
+ if (this.dragFillState.isDragging) {
11073
+ setMouseStyle('crosshair', this.containerElement());
11074
+ const { highlightStartCell, highlightEndCell } = dragFillHighlightArea(this.aiTable, this.dragFillState.sourceCells, recordId);
11075
+ activeCell = this.aiTable.selection().activeCell;
11076
+ startCell = highlightStartCell;
11077
+ endCell = highlightEndCell;
11078
+ }
11079
+ else {
11080
+ startCell = this.dragSelectState.startCell;
11081
+ endCell = [recordId, fieldId];
11082
+ }
10631
11083
  if (startCell && !!startCell.length) {
10632
- this.aiTableGridSelectionService.selectCells(startCell, endCell);
11084
+ this.aiTableGridSelectionService.selectCells(startCell, endCell, activeCell);
10633
11085
  this.scrollViewToCell(pos, startCell, endCell, this.coordinate(), this.horizontalBarRef(), this.verticalBarRef());
10634
11086
  }
10635
11087
  }
@@ -10663,13 +11115,21 @@ class AITableGrid extends AITableGridBase {
10663
11115
  case AI_TABLE_CELL:
10664
11116
  if (!recordId || !fieldId)
10665
11117
  return;
10666
- const dragSelectionStart = [recordId, fieldId];
10667
- this.updateDragSelectionState(true, dragSelectionStart);
11118
+ const startCell = [recordId, fieldId];
11119
+ this.updateDragSelectState(true, startCell);
10668
11120
  const [expandRecordId, expandFieldId] = this.aiTable.selection().expandCell || [null, null];
10669
11121
  if (expandRecordId !== recordId || expandFieldId !== fieldId) {
10670
- this.aiTableGridSelectionService.selectCells(dragSelectionStart);
11122
+ this.aiTableGridSelectionService.selectCells(startCell);
10671
11123
  }
10672
11124
  return;
11125
+ case AI_TABLE_FILL_HANDLE:
11126
+ if (!recordId || !fieldId)
11127
+ return;
11128
+ this.updateDragFillState({
11129
+ isDragging: true,
11130
+ sourceCells: this.aiTable.selection().selectedCells
11131
+ });
11132
+ return;
10673
11133
  case AI_TABLE_ROW_DRAG:
10674
11134
  if (!recordId)
10675
11135
  return;
@@ -10696,11 +11156,31 @@ class AITableGrid extends AITableGridBase {
10696
11156
  }
10697
11157
  }
10698
11158
  stageMouseup(e) {
10699
- this.updateDragSelectionState(false, null);
11159
+ this.updateDragSelectState(false, null);
11160
+ if (this.dragFillState.isDragging) {
11161
+ this.performFill(e);
11162
+ }
11163
+ }
11164
+ performFill(e) {
11165
+ const targetName = e.event.target.name();
11166
+ const gridStage = e.event.currentTarget.getStage();
11167
+ const pos = gridStage?.getPointerPosition();
11168
+ if (pos == null) {
11169
+ this.updateDragFillState({ isDragging: false, sourceCells: new Set() });
11170
+ return;
11171
+ }
11172
+ const { context } = this.aiTable;
11173
+ const { x, y } = pos;
11174
+ const curMousePosition = getMousePosition(this.aiTable, x, y, this.coordinate(), AITable.getVisibleFields(this.aiTable), context, targetName);
11175
+ const { recordId } = getDetailByTargetName(curMousePosition.realTargetName);
11176
+ if (recordId) {
11177
+ performFill(this.aiTable, this.dragFillState.sourceCells, recordId, this.actions);
11178
+ }
11179
+ this.updateDragFillState({ isDragging: false, sourceCells: new Set() });
10700
11180
  }
10701
11181
  stageMouseleave(e) {
10702
11182
  if (!this.isDragSelectionAutoScrolling) {
10703
- this.updateDragSelectionState(false, null);
11183
+ this.updateDragSelectState(false, null);
10704
11184
  }
10705
11185
  if (this.timer) {
10706
11186
  cancelAnimationFrame(this.timer);
@@ -10882,13 +11362,18 @@ class AITableGrid extends AITableGridBase {
10882
11362
  !this.containerElement().contains(e.target) &&
10883
11363
  !e.target.closest(AI_TABLE_PREVENT_CLEAR_SELECTION_CLASS)), takeUntilDestroyed(this.destroyRef))
10884
11364
  .subscribe(() => {
10885
- this.updateDragSelectionState(false, null);
11365
+ this.updateDragSelectState(false, null);
10886
11366
  this.aiTableGridSelectionService.clearSelection();
10887
11367
  });
10888
11368
  }
10889
- updateDragSelectionState(isDragSelecting, dragSelectionStart) {
10890
- this.isDragSelecting = isDragSelecting;
10891
- this.dragSelectionStart = dragSelectionStart;
11369
+ updateDragSelectState(isDragging, startCell) {
11370
+ this.dragSelectState = {
11371
+ isDragging: isDragging,
11372
+ startCell: startCell
11373
+ };
11374
+ }
11375
+ updateDragFillState(dragFillState) {
11376
+ this.dragFillState = dragFillState;
10892
11377
  }
10893
11378
  verticalScroll(e) {
10894
11379
  const { scrollTop } = e.target;
@@ -11077,7 +11562,7 @@ class AITableGrid extends AITableGridBase {
11077
11562
  this.scrollControllerService.scroll({
11078
11563
  container: containerRect,
11079
11564
  target: position,
11080
- direction: isSelectionOnlyOnFrozenColumn ? 'vertical' : 'both',
11565
+ direction: isSelectionOnlyOnFrozenColumn || this.dragFillState.isDragging ? 'vertical' : 'both',
11081
11566
  scrollableElement: {
11082
11567
  horizontalElement: horizontalBarRef?.nativeElement,
11083
11568
  verticalElement: verticalBarRef?.nativeElement
@@ -11112,7 +11597,7 @@ class AITableGrid extends AITableGridBase {
11112
11597
  },
11113
11598
  onAutoScrollEnd: () => {
11114
11599
  this.isDragSelectionAutoScrolling = false;
11115
- this.updateDragSelectionState(false, null);
11600
+ this.updateDragSelectState(false, null);
11116
11601
  }
11117
11602
  });
11118
11603
  }
@@ -11130,5 +11615,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
11130
11615
  * Generated bundle index. Do not edit.
11131
11616
  */
11132
11617
 
11133
- export { AITable, AITableActionIcon, AITableAddField, AITableAreaType, AITableAvatarSize, AITableAvatarType, AITableCellAttachment, AITableCellLink, AITableCellProgress, AITableCellRate, AITableCellRichText, AITableCells, AITableCheckType, AITableColumnHeads, AITableContextMenu, AITableDomGrid, AITableFieldHead, AITableFieldIcon, AITableFieldIsSameOptionPipe, AITableFieldSetting, AITableFrozenCells, AITableFrozenColumnHeads, AITableFrozenPlaceholderCells, AITableGrid, AITableGridEventService, AITableGridFieldService, AITableGridI18nKey, AITableGridSelectionService, AITableHoverRowHeads, AITableIcon, AITableMemberType, AITableMouseDownType, AITableOtherRows, AITablePlaceholderCells, AITableQueries, AITableRenderer, AITableRowType, AITableSelectAllState, AITableTextComponent, AI_TABLE_ACTION_COMMON_RADIUS, AI_TABLE_ACTION_COMMON_RIGHT_PADDING, AI_TABLE_ACTION_COMMON_SIZE, AI_TABLE_AUTO_SCROLL_BOTTOM_THRESHOLD, AI_TABLE_AUTO_SCROLL_LEFT_THRESHOLD, AI_TABLE_AUTO_SCROLL_RIGHT_THRESHOLD, AI_TABLE_AUTO_SCROLL_TOP_THRESHOLD, AI_TABLE_BLANK, AI_TABLE_CELL, AI_TABLE_CELL_ACTIVE_BORDER_WIDTH, AI_TABLE_CELL_ADD_ITEM_BUTTON_SIZE, AI_TABLE_CELL_ATTACHMENT_ADD, AI_TABLE_CELL_ATTACHMENT_FILE, AI_TABLE_CELL_BORDER, AI_TABLE_CELL_DELETE_ITEM_BUTTON_SIZE, AI_TABLE_CELL_DELETE_ITEM_BUTTON_SIZE_OFFSET, AI_TABLE_CELL_EDIT, AI_TABLE_CELL_EMOJI_PADDING, AI_TABLE_CELL_EMOJI_SIZE, AI_TABLE_CELL_FIELD_ITEM_HEIGHT, AI_TABLE_CELL_MAX_ROW_COUNT, AI_TABLE_CELL_MEMBER_ITEM_HEIGHT, AI_TABLE_CELL_MEMBER_ITEM_PADDING, AI_TABLE_CELL_MEMBER_MAX_HEIGHT, AI_TABLE_CELL_MULTI_DOT_RADIUS, AI_TABLE_CELL_MULTI_ITEM_MARGIN_LEFT, AI_TABLE_CELL_MULTI_ITEM_MARGIN_TOP, AI_TABLE_CELL_MULTI_ITEM_MIN_WIDTH, AI_TABLE_CELL_MULTI_PADDING_LEFT, AI_TABLE_CELL_MULTI_PADDING_TOP, AI_TABLE_CELL_PADDING, AI_TABLE_COMMON_FONT_SIZE, AI_TABLE_DEFAULT_COLUMN_WIDTH, AI_TABLE_DOT_RADIUS, AI_TABLE_FIELD_ADD_BUTTON, AI_TABLE_FIELD_ADD_BUTTON_WIDTH, AI_TABLE_FIELD_HEAD, AI_TABLE_FIELD_HEAD_HEIGHT, AI_TABLE_FIELD_HEAD_ICON_GAP_SIZE, AI_TABLE_FIELD_HEAD_MORE, AI_TABLE_FIELD_HEAD_OPACITY_LINE, AI_TABLE_FIELD_HEAD_SELECT_CHECKBOX, AI_TABLE_FIELD_HEAD_TEXT_MIN_WIDTH, AI_TABLE_FIELD_ITEM_MARGIN_RIGHT, AI_TABLE_FIELD_MAX_WIDTH, AI_TABLE_FIELD_MIDDLE_WIDTH, AI_TABLE_FIELD_MINI_WIDTH, AI_TABLE_FIELD_MIN_WIDTH, AI_TABLE_FILE_ICON_ITEM_HEIGHT, AI_TABLE_FILE_ICON_SIZE, AI_TABLE_GRID_FIELD_SERVICE_MAP, AI_TABLE_ICON_COMMON_SIZE, AI_TABLE_INDEX_FIELD_TEXT, AI_TABLE_MEMBER_AVATAR_SIZE, AI_TABLE_MEMBER_ITEM_AVATAR_MARGIN_RIGHT, AI_TABLE_MEMBER_ITEM_PADDING_RIGHT, AI_TABLE_MIN_TEXT_WIDTH, AI_TABLE_OFFSET, AI_TABLE_OPTION_ITEM_FONT_SIZE, AI_TABLE_OPTION_ITEM_HEIGHT, AI_TABLE_OPTION_ITEM_PADDING, AI_TABLE_OPTION_ITEM_RADIUS, AI_TABLE_PIECE_RADIUS, AI_TABLE_PIECE_WIDTH, AI_TABLE_POPOVER_LEFT_OFFSET, AI_TABLE_PREVENT_CLEAR_SELECTION_CLASS, AI_TABLE_PROGRESS_BAR_HEIGHT, AI_TABLE_PROGRESS_BAR_POINTER_HEIGHT, AI_TABLE_PROGRESS_BAR_POINTER_WIDTH, AI_TABLE_PROGRESS_BAR_RADIUS, AI_TABLE_PROGRESS_TEXT_WIDTH, AI_TABLE_RATE_MAX, AI_TABLE_ROW_ADD_BUTTON, AI_TABLE_ROW_BLANK_HEIGHT, AI_TABLE_ROW_DRAG, AI_TABLE_ROW_DRAG_ICON_WIDTH, AI_TABLE_ROW_HEAD, AI_TABLE_ROW_HEAD_SIZE, AI_TABLE_ROW_HEAD_WIDTH, AI_TABLE_ROW_HEAD_WIDTH_AND_DRAG_ICON_WIDTH, AI_TABLE_ROW_HEIGHT, AI_TABLE_ROW_SELECT_CHECKBOX, AI_TABLE_SCROLL_BAR_PADDING, AI_TABLE_SCROLL_BAR_SIZE, AI_TABLE_TAG_FONT_SIZE, AI_TABLE_TAG_PADDING, AI_TABLE_TEXT_GAP, AbstractEditCellEditor, AddOutlinedPath, AttachmentField, AttachmentPath, CellDrawer, Check, Colors, ColumnCalendarFilledPath, ColumnLinkOutlinedPath, ColumnMemberFilledPath, ColumnMultipleFillPath, ColumnNumberFilledPath, ColumnProgressFilledPath, ColumnRatingFilledPath, ColumnRichTextFilledPath, ColumnSelectFilledPath, ColumnTextFilledPath, Coordinate, CoverCellComponent, DBL_CLICK_EDIT_TYPE, DEFAULT_FONT_FAMILY, DEFAULT_FONT_SIZE, DEFAULT_FONT_STYLE, DEFAULT_FONT_WEIGHT, DEFAULT_ICON_SHAPE, DEFAULT_ICON_SIZE, DEFAULT_POINT_POSITION, DEFAULT_SCROLL_STATE, DEFAULT_TEXT_ALIGN_CENTER, DEFAULT_TEXT_ALIGN_LEFT, DEFAULT_TEXT_ALIGN_RIGHT, DEFAULT_TEXT_DECORATION, DEFAULT_TEXT_ELLIPSIS, DEFAULT_TEXT_FILL, DEFAULT_TEXT_LINE_HEIGHT, DEFAULT_TEXT_LISTENING, DEFAULT_TEXT_MAX_CACHE, DEFAULT_TEXT_MAX_HEIGHT, DEFAULT_TEXT_SCALE, DEFAULT_TEXT_TRANSFORMS_ENABLED, DEFAULT_TEXT_VERTICAL_ALIGN_MIDDLE, DEFAULT_TEXT_VERTICAL_ALIGN_TOP, DEFAULT_TEXT_WRAP, DEFAULT_WRAP_TEXT_MAX_ROW, DateCellEditorComponent, DateField, DepartmentOutlinedPath, Drawer, EditPath, FONT_SIZE_SM, FieldModelMap, GRID_CELL_EDITOR_MAP, IconPathMap, IsSelectRecordPipe, KO_CONTAINER_TOKEN, KoComponent, KoContainer, KoShape, KoShapeTypes, KoStage, LinkCellEditorComponent, LinkField, MIN_COLUMN_WIDTH, MemberField, MemberSettingPipe, MoreStandOutlinedPath, NumberCellEditorComponent, NumberField, ProgressField, RateField, RendererContext, RichTextField, RowDragPath, RowHeight, SelectCellEditorComponent, SelectField, SelectOptionComponent, SelectOptionPipe, SelectOptionsPipe, SelectSettingPipe, StarFill, TextCellEditorComponent, TextField, TextMeasure, Unchecked, UserPipe, WebOutlinedPath, aiTableFragmentAttribute, aiTableImageConfigToKonvaConfig, aiTableRectConfigToKonvaConfig, aiTableTextConfigToKonvaConfig, applyNodeProps, buildClipboardData, buildGridData, buildGridLinearRows, castToString, cellDrawer, clearCells, compareNumber, compareOption, compareString, createAITable, createActiveCellBorder, createCells, createDefaultField, createDefaultFieldName, createListener, drawer, expandCell, extractLinkUrl, extractText, generateNewName, generateTargetName, getAvatarBgColor, getAvatarShortName, getCellEditorBorderSpace, getCellHorizontalPosition, getColumnIndicesSizeMap, getCoverCell, getDefaultFieldOptions, getDefaultFieldValue, getDefaultI18nTextByKey, getDetailByTargetName, getEditorBoxOffset, getEditorSpace, getFieldOptionByField, getFieldOptionMap, getFieldOptions, getFieldValue, getFileThumbnailSvgString, getHoverEditorBoxOffset, getHoverEditorSpace, getI18nTextByKey, getMousePosition, getName, getOptionsByFieldAndRecords, getPlaceHolderCellsConfigs, getSystemFieldValue, getTargetName, getTextWidth, getVisibleRangeInfo, graphemeSplitter, handleMouseStyle, hasIntersect, idCreator, idsCreator, imageCache, isActiveCell, isArrayField, isCellMatchKeywords, isClipboardReadSupported, isClipboardReadTextSupported, isClipboardWriteSupported, isClipboardWriteTextSupported, isDateFiled, isEmptyOrNot, isMac, isMeetFilter, isNumberFiled, isSameFieldOption, isSelectedField, isSystemField, isVirtualKey, isWindows, isWindowsOS, isWithinFrozenColumnBoundary, processPastedValueForSelect, readFromClipboard, scrollMax, setMouseStyle, shortIdCreator, shortIdsCreator, stringInclude, textDataCache, toAttachmentFieldValue, toDateFieldValue, toLinkFieldValue, toMemberFieldValue, toNumberFieldValue, toProgressFieldValue, toRateFieldValue, toRichTextFieldValue, toSelectFieldValue, toTextFieldValue, transformToCellText, updatePicture, writeToAITable, writeToClipboard, zhIntlCollator };
11618
+ export { AITable, AITableActionIcon, AITableAddField, AITableAreaType, AITableAvatarSize, AITableAvatarType, AITableCellAttachment, AITableCellLink, AITableCellProgress, AITableCellRate, AITableCellRichText, AITableCells, AITableCheckType, AITableColumnHeads, AITableContextMenu, AITableDomGrid, AITableFieldHead, AITableFieldIcon, AITableFieldIsSameOptionPipe, AITableFieldSetting, AITableFrozenCells, AITableFrozenColumnHeads, AITableFrozenPlaceholderCells, AITableGrid, AITableGridEventService, AITableGridFieldService, AITableGridI18nKey, AITableGridSelectionService, AITableHoverRowHeads, AITableIcon, AITableMemberType, AITableMouseDownType, AITableOtherRows, AITablePlaceholderCells, AITableQueries, AITableRenderer, AITableRowType, AITableSelectAllState, AITableTextComponent, AI_TABLE_ACTION_COMMON_RADIUS, AI_TABLE_ACTION_COMMON_RIGHT_PADDING, AI_TABLE_ACTION_COMMON_SIZE, AI_TABLE_AUTO_SCROLL_BOTTOM_THRESHOLD, AI_TABLE_AUTO_SCROLL_LEFT_THRESHOLD, AI_TABLE_AUTO_SCROLL_RIGHT_THRESHOLD, AI_TABLE_AUTO_SCROLL_TOP_THRESHOLD, AI_TABLE_BLANK, AI_TABLE_CELL, AI_TABLE_CELL_ACTIVE_BORDER_WIDTH, AI_TABLE_CELL_ADD_ITEM_BUTTON_SIZE, AI_TABLE_CELL_ATTACHMENT_ADD, AI_TABLE_CELL_ATTACHMENT_FILE, AI_TABLE_CELL_BORDER, AI_TABLE_CELL_DELETE_ITEM_BUTTON_SIZE, AI_TABLE_CELL_DELETE_ITEM_BUTTON_SIZE_OFFSET, AI_TABLE_CELL_EDIT, AI_TABLE_CELL_EMOJI_PADDING, AI_TABLE_CELL_EMOJI_SIZE, AI_TABLE_CELL_FIELD_ITEM_HEIGHT, AI_TABLE_CELL_MAX_ROW_COUNT, AI_TABLE_CELL_MEMBER_ITEM_HEIGHT, AI_TABLE_CELL_MEMBER_ITEM_PADDING, AI_TABLE_CELL_MEMBER_MAX_HEIGHT, AI_TABLE_CELL_MULTI_DOT_RADIUS, AI_TABLE_CELL_MULTI_ITEM_MARGIN_LEFT, AI_TABLE_CELL_MULTI_ITEM_MARGIN_TOP, AI_TABLE_CELL_MULTI_ITEM_MIN_WIDTH, AI_TABLE_CELL_MULTI_PADDING_LEFT, AI_TABLE_CELL_MULTI_PADDING_TOP, AI_TABLE_CELL_PADDING, AI_TABLE_COMMON_FONT_SIZE, AI_TABLE_DEFAULT_COLUMN_WIDTH, AI_TABLE_DOT_RADIUS, AI_TABLE_FIELD_ADD_BUTTON, AI_TABLE_FIELD_ADD_BUTTON_WIDTH, AI_TABLE_FIELD_HEAD, AI_TABLE_FIELD_HEAD_HEIGHT, AI_TABLE_FIELD_HEAD_ICON_GAP_SIZE, AI_TABLE_FIELD_HEAD_MORE, AI_TABLE_FIELD_HEAD_OPACITY_LINE, AI_TABLE_FIELD_HEAD_SELECT_CHECKBOX, AI_TABLE_FIELD_HEAD_TEXT_MIN_WIDTH, AI_TABLE_FIELD_ITEM_MARGIN_RIGHT, AI_TABLE_FIELD_MAX_WIDTH, AI_TABLE_FIELD_MIDDLE_WIDTH, AI_TABLE_FIELD_MINI_WIDTH, AI_TABLE_FIELD_MIN_WIDTH, AI_TABLE_FIELD_STAT_HEIGHT, AI_TABLE_FILE_ICON_ITEM_HEIGHT, AI_TABLE_FILE_ICON_SIZE, AI_TABLE_FILL_HANDLE, AI_TABLE_GRID_FIELD_SERVICE_MAP, AI_TABLE_ICON_COMMON_SIZE, AI_TABLE_INDEX_FIELD_TEXT, AI_TABLE_MEMBER_AVATAR_SIZE, AI_TABLE_MEMBER_ITEM_AVATAR_MARGIN_RIGHT, AI_TABLE_MEMBER_ITEM_PADDING_RIGHT, AI_TABLE_MIN_TEXT_WIDTH, AI_TABLE_OFFSET, AI_TABLE_OPTION_ITEM_FONT_SIZE, AI_TABLE_OPTION_ITEM_HEIGHT, AI_TABLE_OPTION_ITEM_PADDING, AI_TABLE_OPTION_ITEM_RADIUS, AI_TABLE_PIECE_RADIUS, AI_TABLE_PIECE_WIDTH, AI_TABLE_POPOVER_LEFT_OFFSET, AI_TABLE_PREVENT_CLEAR_SELECTION_CLASS, AI_TABLE_PROGRESS_BAR_HEIGHT, AI_TABLE_PROGRESS_BAR_POINTER_HEIGHT, AI_TABLE_PROGRESS_BAR_POINTER_WIDTH, AI_TABLE_PROGRESS_BAR_RADIUS, AI_TABLE_PROGRESS_TEXT_WIDTH, AI_TABLE_RATE_MAX, AI_TABLE_ROW_ADD_BUTTON, AI_TABLE_ROW_BLANK_HEIGHT, AI_TABLE_ROW_DRAG, AI_TABLE_ROW_DRAG_ICON_WIDTH, AI_TABLE_ROW_HEAD, AI_TABLE_ROW_HEAD_SIZE, AI_TABLE_ROW_HEAD_WIDTH, AI_TABLE_ROW_HEAD_WIDTH_AND_DRAG_ICON_WIDTH, AI_TABLE_ROW_HEIGHT, AI_TABLE_ROW_SELECT_CHECKBOX, AI_TABLE_SCROLL_BAR_PADDING, AI_TABLE_SCROLL_BAR_SIZE, AI_TABLE_TAG_FONT_SIZE, AI_TABLE_TAG_PADDING, AI_TABLE_TEXT_GAP, AbstractEditCellEditor, AddOutlinedPath, AngleDownPath, AttachmentField, AttachmentPath, CellDrawer, Check, Colors, ColumnCalendarFilledPath, ColumnLinkOutlinedPath, ColumnMemberFilledPath, ColumnMultipleFillPath, ColumnNumberFilledPath, ColumnProgressFilledPath, ColumnRatingFilledPath, ColumnRichTextFilledPath, ColumnSelectFilledPath, ColumnTextFilledPath, Coordinate, CoverCellComponent, DBL_CLICK_EDIT_TYPE, DEFAULT_FONT_FAMILY, DEFAULT_FONT_SIZE, DEFAULT_FONT_STYLE, DEFAULT_FONT_WEIGHT, DEFAULT_ICON_SHAPE, DEFAULT_ICON_SIZE, DEFAULT_POINT_POSITION, DEFAULT_SCROLL_STATE, DEFAULT_TEXT_ALIGN_CENTER, DEFAULT_TEXT_ALIGN_LEFT, DEFAULT_TEXT_ALIGN_RIGHT, DEFAULT_TEXT_DECORATION, DEFAULT_TEXT_ELLIPSIS, DEFAULT_TEXT_FILL, DEFAULT_TEXT_LINE_HEIGHT, DEFAULT_TEXT_LISTENING, DEFAULT_TEXT_MAX_CACHE, DEFAULT_TEXT_MAX_HEIGHT, DEFAULT_TEXT_SCALE, DEFAULT_TEXT_TRANSFORMS_ENABLED, DEFAULT_TEXT_VERTICAL_ALIGN_MIDDLE, DEFAULT_TEXT_VERTICAL_ALIGN_TOP, DEFAULT_TEXT_WRAP, DEFAULT_WRAP_TEXT_MAX_ROW, DateCellEditorComponent, DateField, DepartmentOutlinedPath, Drawer, EditPath, FONT_SIZE_SM, FieldModelMap, GRID_CELL_EDITOR_MAP, IconPathMap, IsSelectRecordPipe, KO_CONTAINER_TOKEN, KoComponent, KoContainer, KoShape, KoShapeTypes, KoStage, LinkCellEditorComponent, LinkField, MIN_COLUMN_WIDTH, MemberField, MemberSettingPipe, MoreStandOutlinedPath, NumberCellEditorComponent, NumberField, ProgressField, RateField, RendererContext, RichTextField, RowDragPath, RowHeight, SelectCellEditorComponent, SelectField, SelectOptionComponent, SelectOptionPipe, SelectOptionsPipe, SelectSettingPipe, StarFill, TextCellEditorComponent, TextField, TextMeasure, Unchecked, UserPipe, WebOutlinedPath, aiTableFragmentAttribute, aiTableImageConfigToKonvaConfig, aiTableRectConfigToKonvaConfig, aiTableTextConfigToKonvaConfig, applyNodeProps, buildClipboardData, buildGridData, buildGridLinearRows, castToString, cellDrawer, clearCells, compareNumber, compareOption, compareString, createAITable, createActiveCellBorder, createCells, createDefaultField, createDefaultFieldName, createListener, dragFillHighlightArea, drawer, expandCell, extractLinkUrl, extractText, generateNewName, generateTargetName, getAvatarBgColor, getAvatarShortName, getCellEditorBorderSpace, getCellHorizontalPosition, getColumnIndicesSizeMap, getCoverCell, getDefaultFieldOptions, getDefaultFieldValue, getDefaultI18nTextByKey, getDetailByTargetName, getEditorBoxOffset, getEditorSpace, getFieldOptionByField, getFieldOptionMap, getFieldOptions, getFieldValue, getFileThumbnailSvgString, getFillDirection, getHoverEditorBoxOffset, getHoverEditorSpace, getI18nTextByKey, getMousePosition, getName, getOptionsByFieldAndRecords, getPlaceHolderCellsConfigs, getStartAndEndCell, getSystemFieldValue, getTargetName, getTextWidth, getVisibleRangeInfo, graphemeSplitter, handleMouseStyle, hasIntersect, idCreator, idsCreator, imageCache, isActiveCell, isArrayField, isCellMatchKeywords, isClipboardReadSupported, isClipboardReadTextSupported, isClipboardWriteSupported, isClipboardWriteTextSupported, isDateFiled, isEmptyOrNot, isMac, isMeetFilter, isNumberFiled, isSameFieldOption, isSelectedField, isSystemField, isVirtualKey, isWindows, isWindowsOS, isWithinFrozenColumnBoundary, performFill, processPastedValueForSelect, readFromClipboard, scrollMax, setMouseStyle, shortIdCreator, shortIdsCreator, stringInclude, textDataCache, toAttachmentFieldValue, toDateFieldValue, toLinkFieldValue, toMemberFieldValue, toNumberFieldValue, toProgressFieldValue, toRateFieldValue, toRichTextFieldValue, toSelectFieldValue, toTextFieldValue, transformToCellText, updatePicture, writeToAITable, writeToClipboard, zhIntlCollator };
11134
11619
  //# sourceMappingURL=ai-table-grid.mjs.map