@ai-table/grid 0.2.1 → 0.2.3
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/constants/text.d.ts +1 -0
- package/constants/text.d.ts.map +1 -1
- package/core/context.d.ts +2 -0
- package/core/context.d.ts.map +1 -1
- package/core/types/ai-table.d.ts +4 -2
- package/core/types/ai-table.d.ts.map +1 -1
- package/core/utils/common.d.ts.map +1 -1
- package/core/utils/field.d.ts +0 -4
- package/core/utils/field.d.ts.map +1 -1
- package/core/utils/queries.d.ts +1 -1
- package/core/utils/queries.d.ts.map +1 -1
- package/fesm2022/ai-table-grid.mjs +104 -56
- package/fesm2022/ai-table-grid.mjs.map +1 -1
- package/grid-base.component.d.ts +2 -1
- package/grid-base.component.d.ts.map +1 -1
- package/grid.component.d.ts +5 -1
- package/grid.component.d.ts.map +1 -1
- package/package.json +1 -1
- package/renderer/components/field-stat/stat.component.d.ts +3 -0
- package/renderer/components/field-stat/stat.component.d.ts.map +1 -1
- package/renderer/components/group/frozen-groups.component.d.ts +3 -0
- package/renderer/components/group/frozen-groups.component.d.ts.map +1 -1
- package/renderer/drawers/group-layout.d.ts.map +1 -1
- package/renderer/renderer.component.d.ts.map +1 -1
- package/types/cell.d.ts +1 -0
- package/types/cell.d.ts.map +1 -1
- package/types/component-config.d.ts.map +1 -1
- package/types/grid.d.ts +2 -1
- package/types/grid.d.ts.map +1 -1
- package/utils/build.d.ts +1 -0
- package/utils/build.d.ts.map +1 -1
- package/utils/clear-cells.d.ts.map +1 -1
- package/utils/group.d.ts +1 -0
- package/utils/group.d.ts.map +1 -1
- package/utils/i18n.d.ts +2 -0
- package/utils/i18n.d.ts.map +1 -1
@@ -535,6 +535,7 @@ var AITableGridI18nKey;
|
|
535
535
|
AITableGridI18nKey["fieldGroupBase"] = "fieldGroupBase";
|
536
536
|
AITableGridI18nKey["fieldGroupAdvanced"] = "fieldGroupAdvanced";
|
537
537
|
AITableGridI18nKey["rowAddFilterTooltip"] = "rowAddFilterTooltip";
|
538
|
+
AITableGridI18nKey["rowWillMoveTooltip"] = "rowWillMoveTooltip";
|
538
539
|
AITableGridI18nKey["earliestTime"] = "earliestTime";
|
539
540
|
AITableGridI18nKey["earliestTimeResult"] = "earliestTimeResult";
|
540
541
|
AITableGridI18nKey["latestTime"] = "latestTime";
|
@@ -589,6 +590,7 @@ const AITableGridI18nText = {
|
|
589
590
|
[AITableGridI18nKey.fieldGroupBase]: '基础',
|
590
591
|
[AITableGridI18nKey.fieldGroupAdvanced]: '高级',
|
591
592
|
[AITableGridI18nKey.rowAddFilterTooltip]: '本记录已被筛选过滤,点击该记录以外位置将被隐藏',
|
593
|
+
[AITableGridI18nKey.rowWillMoveTooltip]: '本记录不属于当前位置,点击该记录以外位置将被移动',
|
592
594
|
[AITableGridI18nKey.earliestTime]: '最早时间',
|
593
595
|
[AITableGridI18nKey.earliestTimeResult]: '最早时间 {{statValue}}',
|
594
596
|
[AITableGridI18nKey.latestTime]: '最晚时间',
|
@@ -994,6 +996,7 @@ const AngleRightPath = `M4.72665,3.40415 L5.55765,2.57315 L11.22965,8.24615 L5.5
|
|
994
996
|
const IconPathMap = {};
|
995
997
|
|
996
998
|
const DEFAULT_FONT_SIZE = 14;
|
999
|
+
const GROUP_STAT_DEFAULT_FONT_SIZE = 12;
|
997
1000
|
const DEFAULT_FONT_FAMILY = '-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,PingFang SC,Helvetica Neue,Noto Sans,Noto Sans CJK SC,Microsoft Yahei,Arial,Hiragino Sans GB,sans-serif';
|
998
1001
|
const DEFAULT_FONT_STYLE = 'normal';
|
999
1002
|
const DEFAULT_TEXT_LINE_HEIGHT = 24;
|
@@ -1452,6 +1455,7 @@ function createAITable(records, fields, gridData) {
|
|
1452
1455
|
editingCell: signal({ path: null }),
|
1453
1456
|
keywordsMatchedCells: signal(new Set()),
|
1454
1457
|
keywordsMatchedCellIndex: signal(0),
|
1458
|
+
keywords: signal(''),
|
1455
1459
|
recordsMap: computed(() => {
|
1456
1460
|
return records().reduce((object, item) => {
|
1457
1461
|
object[item._id] = item;
|
@@ -1465,7 +1469,7 @@ function createAITable(records, fields, gridData) {
|
|
1465
1469
|
}, {});
|
1466
1470
|
}),
|
1467
1471
|
recordsWillHidden: signal([]),
|
1468
|
-
recordsWillMove: signal(
|
1472
|
+
recordsWillMove: signal(new Map()),
|
1469
1473
|
dragState: signal({
|
1470
1474
|
type: DragType.none,
|
1471
1475
|
sourceIds: new Set()
|
@@ -1486,34 +1490,9 @@ function generateNewName(existNames, count, name) {
|
|
1486
1490
|
return newName;
|
1487
1491
|
}
|
1488
1492
|
|
1489
|
-
const isArrayField = (field) => {
|
1490
|
-
return [
|
1491
|
-
AITableFieldType.member,
|
1492
|
-
AITableFieldType.createdBy,
|
1493
|
-
AITableFieldType.updatedBy,
|
1494
|
-
AITableFieldType.select,
|
1495
|
-
AITableFieldType.attachment,
|
1496
|
-
AITableFieldType.richText
|
1497
|
-
].includes(field.type);
|
1498
|
-
};
|
1499
1493
|
const isSystemField = (field) => {
|
1500
1494
|
return [AITableFieldType.createdAt, AITableFieldType.createdBy, AITableFieldType.updatedAt, AITableFieldType.updatedBy].includes(field.type);
|
1501
1495
|
};
|
1502
|
-
const isNumberFiled = (field) => {
|
1503
|
-
return [AITableFieldType.number, AITableFieldType.progress, AITableFieldType.rate].includes(field.type);
|
1504
|
-
};
|
1505
|
-
const isDateFiled = (field) => {
|
1506
|
-
return [AITableFieldType.date, AITableFieldType.createdAt, AITableFieldType.updatedAt].includes(field.type);
|
1507
|
-
};
|
1508
|
-
function getDefaultFieldValue(field) {
|
1509
|
-
if (isArrayField(field)) {
|
1510
|
-
return [];
|
1511
|
-
}
|
1512
|
-
if (isNumberFiled(field) || isDateFiled(field) || field.type === AITableFieldType.link || field.type === AITableFieldType.checkbox) {
|
1513
|
-
return null;
|
1514
|
-
}
|
1515
|
-
return '';
|
1516
|
-
}
|
1517
1496
|
function createDefaultFieldName(aiTable, field) {
|
1518
1497
|
const fieldOption = getFieldOptionByField(aiTable, field);
|
1519
1498
|
if (fieldOption) {
|
@@ -1577,7 +1556,7 @@ const AITableQueries = {
|
|
1577
1556
|
}
|
1578
1557
|
throw new Error(`can not find the field path: ${JSON.stringify({ ...(field || {}) })}`);
|
1579
1558
|
},
|
1580
|
-
getFieldValue(aiTable, path) {
|
1559
|
+
getFieldValue(aiTable, path, record) {
|
1581
1560
|
if (!aiTable) {
|
1582
1561
|
throw new Error(`aiTable does not exist`);
|
1583
1562
|
}
|
@@ -1590,7 +1569,7 @@ const AITableQueries = {
|
|
1590
1569
|
if (!path) {
|
1591
1570
|
throw new Error(`path does not exist as path [${path}]`);
|
1592
1571
|
}
|
1593
|
-
|
1572
|
+
record = record || aiTable.recordsMap()[path[0]];
|
1594
1573
|
if (!record) {
|
1595
1574
|
throw new Error(`can not find record at path [${path}]`);
|
1596
1575
|
}
|
@@ -1625,7 +1604,7 @@ const AITableQueries = {
|
|
1625
1604
|
|
1626
1605
|
class RendererContext {
|
1627
1606
|
constructor(options) {
|
1628
|
-
const { containerRect, rowHeadWidth, linearRows, pointPosition, scrollState, visibleColumnsIndexMap, visibleRowsIndexMap, frozenColumnCount, references, aiFieldConfig, scrollAction, maxFields, maxRecords, maxSelectOptions, fieldOptions, fieldOptionMap, readonly } = options;
|
1607
|
+
const { containerRect, rowHeadWidth, linearRows, pointPosition, scrollState, visibleColumnsIndexMap, visibleRowsIndexMap, groupStatContainerWidthMap, frozenColumnCount, references, aiFieldConfig, scrollAction, maxFields, maxRecords, maxSelectOptions, fieldOptions, fieldOptionMap, groupCollapseDisabled, readonly } = options;
|
1629
1608
|
this.containerRect = containerRect;
|
1630
1609
|
this.rowHeadWidth = rowHeadWidth;
|
1631
1610
|
this.linearRows = linearRows;
|
@@ -1642,7 +1621,9 @@ class RendererContext {
|
|
1642
1621
|
this.maxSelectOptions = maxSelectOptions;
|
1643
1622
|
this.fieldOptions = fieldOptions;
|
1644
1623
|
this.fieldOptionMap = fieldOptionMap;
|
1624
|
+
this.groupCollapseDisabled = groupCollapseDisabled;
|
1645
1625
|
this.readonly = readonly;
|
1626
|
+
this.groupStatContainerWidthMap = groupStatContainerWidthMap;
|
1646
1627
|
}
|
1647
1628
|
setPointPosition(position) {
|
1648
1629
|
const oldPosition = this.pointPosition();
|
@@ -1959,13 +1940,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
|
|
1959
1940
|
}] } });
|
1960
1941
|
|
1961
1942
|
const buildGridLinearRows = (visibleRecords, isAddingVisible = true, aiTable, aiBuildGroupLinearRowsFn) => {
|
1962
|
-
let linearRows = [];
|
1963
1943
|
if (aiBuildGroupLinearRowsFn) {
|
1964
1944
|
const groupLinearRows = aiBuildGroupLinearRowsFn(aiTable);
|
1965
1945
|
if (groupLinearRows) {
|
1966
1946
|
return groupLinearRows;
|
1967
1947
|
}
|
1968
1948
|
}
|
1949
|
+
return buildNormalLinearRows(visibleRecords, isAddingVisible);
|
1950
|
+
};
|
1951
|
+
const buildNormalLinearRows = (visibleRecords, isAddingVisible = true) => {
|
1952
|
+
let linearRows = [];
|
1969
1953
|
let displayRowIndex = 0;
|
1970
1954
|
[...visibleRecords, { _id: '' }].forEach((row) => {
|
1971
1955
|
if (row._id) {
|
@@ -3343,9 +3327,14 @@ function copyOption(originOption, targetFieldOptions, targetOptionStyle) {
|
|
3343
3327
|
return newOption;
|
3344
3328
|
}
|
3345
3329
|
function getValidCellValue(cellValue, options) {
|
3346
|
-
|
3347
|
-
|
3348
|
-
|
3330
|
+
if (Array.isArray(cellValue)) {
|
3331
|
+
const optionsMap = helpers.keyBy(options, '_id');
|
3332
|
+
const validCellValue = cellValue.filter((optionId) => !!optionsMap[optionId]);
|
3333
|
+
return validCellValue;
|
3334
|
+
}
|
3335
|
+
else {
|
3336
|
+
return [];
|
3337
|
+
}
|
3349
3338
|
}
|
3350
3339
|
|
3351
3340
|
class TextField extends TextFieldBase {
|
@@ -3562,6 +3551,9 @@ function getGroupLastRecordIndex(aiTable, startRowIndex) {
|
|
3562
3551
|
}
|
3563
3552
|
return linearRows.length - 1;
|
3564
3553
|
}
|
3554
|
+
function setCollapseDisabled(aiTable, groupCollapseDisabled) {
|
3555
|
+
aiTable.context.groupCollapseDisabled.set(groupCollapseDisabled);
|
3556
|
+
}
|
3565
3557
|
|
3566
3558
|
const aiTableAttributePattern = new RegExp(`${aiTableFragmentAttribute}="(.+?)"`, 'm');
|
3567
3559
|
const decodeClipboardJsonData = (encoded) => {
|
@@ -7023,10 +7015,12 @@ class GroupLayout extends Layout {
|
|
7023
7015
|
const iconContainerWidth = AI_TABLE_ICON_COMMON_SIZE + AI_TABLE_FIELD_HEAD_ICON_GAP_SIZE;
|
7024
7016
|
if (!isEmpty(groupValue) || [AITableFieldType.checkbox, AITableFieldType.progress].includes(field.type)) {
|
7025
7017
|
cellDrawer.initStyle(field, style);
|
7018
|
+
const statContainerWidth = aiTable.context?.groupStatContainerWidthMap()?.get(`${config.row.groupId}:${fieldId}`);
|
7019
|
+
const widthOffset = statContainerWidth ? statContainerWidth - AI_TABLE_CELL_PADDING : 0;
|
7026
7020
|
cellDrawer.renderCell({
|
7027
7021
|
...render,
|
7028
7022
|
x: render.x + iconContainerWidth,
|
7029
|
-
columnWidth: render.columnWidth - iconContainerWidth,
|
7023
|
+
columnWidth: render.columnWidth - iconContainerWidth - widthOffset,
|
7030
7024
|
isGroupFirstRender: true
|
7031
7025
|
}, this.ctx);
|
7032
7026
|
}
|
@@ -9155,8 +9149,12 @@ class AITableFieldStat {
|
|
9155
9149
|
this.isGroupStat = computed(() => {
|
9156
9150
|
return this.config().isGroupStat;
|
9157
9151
|
});
|
9152
|
+
this.groupStatContainerWidthMap = computed(() => {
|
9153
|
+
const { aiTable } = this.config();
|
9154
|
+
return aiTable.context?.groupStatContainerWidthMap();
|
9155
|
+
});
|
9158
9156
|
this.bgConfig = computed(() => {
|
9159
|
-
const { field, width, height, coordinate, readonly, aiTable, isGroupStat, columnIndex } = this.config();
|
9157
|
+
const { field, width, height, coordinate, readonly, aiTable, isGroupStat, columnIndex, groupRow } = this.config();
|
9160
9158
|
const rowHeadWidth = aiTable.context.rowHeadWidth();
|
9161
9159
|
const config = {
|
9162
9160
|
coordinate,
|
@@ -9175,7 +9173,7 @@ class AITableFieldStat {
|
|
9175
9173
|
listening: !readonly
|
9176
9174
|
};
|
9177
9175
|
if (isGroupStat) {
|
9178
|
-
if (
|
9176
|
+
if (this.isFirstColumn()) {
|
9179
9177
|
const textsConfig = this.textsConfig();
|
9180
9178
|
if (textsConfig) {
|
9181
9179
|
config.x = textsConfig[0].x - AI_TABLE_CELL_PADDING;
|
@@ -9212,6 +9210,15 @@ class AITableFieldStat {
|
|
9212
9210
|
config.strokeWidth = AI_TABLE_CELL_LINE_BORDER;
|
9213
9211
|
}
|
9214
9212
|
}
|
9213
|
+
if (isGroupStat && this.isFirstColumn()) {
|
9214
|
+
const groupStatContainerWidthMap = this.groupStatContainerWidthMap();
|
9215
|
+
const groupStatCellKey = `${groupRow.groupId}:${field._id}`;
|
9216
|
+
const originGroupStatContainerWidth = groupStatContainerWidthMap.get(groupStatCellKey);
|
9217
|
+
const width = this.renderTexts() ? config.width : 0;
|
9218
|
+
if (!originGroupStatContainerWidth || originGroupStatContainerWidth !== width) {
|
9219
|
+
groupStatContainerWidthMap.set(groupStatCellKey, width);
|
9220
|
+
}
|
9221
|
+
}
|
9215
9222
|
return config;
|
9216
9223
|
});
|
9217
9224
|
this.field = computed(() => {
|
@@ -9276,7 +9283,7 @@ class AITableFieldStat {
|
|
9276
9283
|
const noneStatString = getI18nTextByKey(this.aiTable(), AITableGridI18nKey.stat);
|
9277
9284
|
const { text, textWidth } = drawer.textEllipsis({
|
9278
9285
|
text: noneStatString,
|
9279
|
-
fontSize:
|
9286
|
+
fontSize: this.fontSize(),
|
9280
9287
|
fontWeight: DEFAULT_FONT_WEIGHT
|
9281
9288
|
});
|
9282
9289
|
return textWidth + AI_TABLE_ACTION_COMMON_SIZE + AI_TABLE_OFFSET;
|
@@ -9322,7 +9329,7 @@ class AITableFieldStat {
|
|
9322
9329
|
const { text, textWidth } = drawer.textEllipsis({
|
9323
9330
|
text: resultString,
|
9324
9331
|
maxWidth: width - AI_TABLE_ACTION_COMMON_SIZE - AI_TABLE_CELL_PADDING,
|
9325
|
-
fontSize:
|
9332
|
+
fontSize: this.fontSize(),
|
9326
9333
|
fontWeight: DEFAULT_FONT_WEIGHT
|
9327
9334
|
});
|
9328
9335
|
return {
|
@@ -9331,12 +9338,16 @@ class AITableFieldStat {
|
|
9331
9338
|
statValue: statValue || ''
|
9332
9339
|
};
|
9333
9340
|
});
|
9341
|
+
this.fontSize = computed(() => {
|
9342
|
+
return this.isGroupStat() ? GROUP_STAT_DEFAULT_FONT_SIZE : DEFAULT_FONT_SIZE;
|
9343
|
+
});
|
9334
9344
|
this.textsConfig = computed(() => {
|
9335
9345
|
const height = this.containerBoxHeight();
|
9336
9346
|
const width = this.containerBoxWidth();
|
9337
9347
|
const renderTexts = this.renderTexts();
|
9338
9348
|
const result = [];
|
9339
9349
|
let previousColor = Colors.gray700;
|
9350
|
+
const fontSize = this.fontSize();
|
9340
9351
|
if (renderTexts) {
|
9341
9352
|
const { texts, totalWidth, statValue } = renderTexts;
|
9342
9353
|
let remainingWidth = width - AI_TABLE_ACTION_COMMON_SIZE;
|
@@ -9350,7 +9361,7 @@ class AITableFieldStat {
|
|
9350
9361
|
const { text: renderText, textWidth } = drawer.textEllipsis({
|
9351
9362
|
text: isLast ? text : `${text} `,
|
9352
9363
|
maxWidth: remainingWidth,
|
9353
|
-
fontSize
|
9364
|
+
fontSize,
|
9354
9365
|
fontWeight: DEFAULT_FONT_WEIGHT
|
9355
9366
|
});
|
9356
9367
|
remainingWidth -= textWidth;
|
@@ -9370,6 +9381,7 @@ class AITableFieldStat {
|
|
9370
9381
|
width: textWidth,
|
9371
9382
|
height: height,
|
9372
9383
|
fill,
|
9384
|
+
fontSize,
|
9373
9385
|
text: renderText,
|
9374
9386
|
lineHeight: AI_TABLE_TEXT_LINE_HEIGHT,
|
9375
9387
|
listening: false
|
@@ -9443,6 +9455,8 @@ class AITableFieldStat {
|
|
9443
9455
|
this.hover.emit(this.isActive() || isHover);
|
9444
9456
|
}
|
9445
9457
|
clickStat(e) {
|
9458
|
+
if (e.event.evt.button !== AITableMouseDownType.Left)
|
9459
|
+
return;
|
9446
9460
|
e.event.evt.stopPropagation();
|
9447
9461
|
this.isActive.set(true);
|
9448
9462
|
const { aiTable, coordinate, field, actions } = this.config();
|
@@ -9615,6 +9629,10 @@ class AITableFrozenGroups {
|
|
9615
9629
|
columnStopIndex: this.columnStopIndex()
|
9616
9630
|
});
|
9617
9631
|
});
|
9632
|
+
this.groupCollapseDisabled = computed(() => {
|
9633
|
+
const { aiTable } = this.config();
|
9634
|
+
return aiTable.context.groupCollapseDisabled();
|
9635
|
+
});
|
9618
9636
|
this.groupCells = computed(() => {
|
9619
9637
|
const groups = this.groups();
|
9620
9638
|
const groupCells = [];
|
@@ -9626,7 +9644,7 @@ class AITableFrozenGroups {
|
|
9626
9644
|
targetName: AI_TABLE_ROW_GROUP_COLLAPSE_BUTTON,
|
9627
9645
|
fieldId: fieldId,
|
9628
9646
|
source: groupId,
|
9629
|
-
mouseStyle: readonly ? 'default' : 'pointer'
|
9647
|
+
mouseStyle: readonly ? 'default' : this.groupCollapseDisabled() ? 'not-allowed' : 'pointer'
|
9630
9648
|
}),
|
9631
9649
|
x,
|
9632
9650
|
y: y + (height - AI_TABLE_ICON_COMMON_SIZE) / 2,
|
@@ -9655,11 +9673,16 @@ class AITableFrozenGroups {
|
|
9655
9673
|
return groupCells;
|
9656
9674
|
});
|
9657
9675
|
}
|
9676
|
+
collapseClick(e) {
|
9677
|
+
if (this.groupCollapseDisabled()) {
|
9678
|
+
e.event.cancelBubble = true;
|
9679
|
+
}
|
9680
|
+
}
|
9658
9681
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableFrozenGroups, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
9659
9682
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableFrozenGroups, isStandalone: true, selector: "ai-table-frozen-groups", inputs: { config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: `
|
9660
9683
|
@for (groupCell of groupCells(); track $index) {
|
9661
9684
|
@if (groupCell.collapsedIcon) {
|
9662
|
-
<ai-table-icon [config]="groupCell.collapsedIcon"></ai-table-icon>
|
9685
|
+
<ai-table-icon [config]="groupCell.collapsedIcon" (koClick)="collapseClick($event)"></ai-table-icon>
|
9663
9686
|
}
|
9664
9687
|
<ai-table-field-stat [config]="groupCell.groupStat!"></ai-table-field-stat>
|
9665
9688
|
}
|
@@ -9672,7 +9695,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImpo
|
|
9672
9695
|
template: `
|
9673
9696
|
@for (groupCell of groupCells(); track $index) {
|
9674
9697
|
@if (groupCell.collapsedIcon) {
|
9675
|
-
<ai-table-icon [config]="groupCell.collapsedIcon"></ai-table-icon>
|
9698
|
+
<ai-table-icon [config]="groupCell.collapsedIcon" (koClick)="collapseClick($event)"></ai-table-icon>
|
9676
9699
|
}
|
9677
9700
|
<ai-table-field-stat [config]="groupCell.groupStat!"></ai-table-field-stat>
|
9678
9701
|
}
|
@@ -9990,6 +10013,7 @@ class AITableRenderer {
|
|
9990
10013
|
return {
|
9991
10014
|
clipX: 0,
|
9992
10015
|
clipY: AI_TABLE_FIELD_HEAD_HEIGHT,
|
10016
|
+
clipWidth: this.containerWidth(),
|
9993
10017
|
clipHeight: this.gridContainerHeight()
|
9994
10018
|
};
|
9995
10019
|
});
|
@@ -10147,6 +10171,7 @@ class AITableRenderer {
|
|
10147
10171
|
});
|
10148
10172
|
this.cellsConfig = computed(() => {
|
10149
10173
|
const { aiTable, readonly, coordinate, references, actions, maxRecords } = this.config();
|
10174
|
+
const keywordsMatchedCells = aiTable.keywordsMatchedCells();
|
10150
10175
|
const { rowStartIndex, rowStopIndex, columnStartIndex, columnStopIndex } = this.visibleRangeInfo();
|
10151
10176
|
return {
|
10152
10177
|
aiTable,
|
@@ -10158,7 +10183,8 @@ class AITableRenderer {
|
|
10158
10183
|
columnStartIndex,
|
10159
10184
|
columnStopIndex,
|
10160
10185
|
actions,
|
10161
|
-
maxRecords
|
10186
|
+
maxRecords,
|
10187
|
+
keywordsMatchedCells
|
10162
10188
|
};
|
10163
10189
|
});
|
10164
10190
|
this.fillHandleConfig = computed(() => {
|
@@ -11007,10 +11033,11 @@ function clearCells(aiTable, actions) {
|
|
11007
11033
|
if (!field || isSystemField(field)) {
|
11008
11034
|
continue;
|
11009
11035
|
}
|
11036
|
+
const defaultValue = FieldModelMap[field.type].getDefaultValue();
|
11010
11037
|
actions.updateFieldValues([
|
11011
11038
|
{
|
11012
11039
|
path: [recordId, fieldId],
|
11013
|
-
value:
|
11040
|
+
value: defaultValue
|
11014
11041
|
}
|
11015
11042
|
]);
|
11016
11043
|
}
|
@@ -12177,6 +12204,7 @@ class AITableGridBase {
|
|
12177
12204
|
this.aiReferences = input.required();
|
12178
12205
|
this.aiBuildRenderDataFn = input();
|
12179
12206
|
this.aiBuildGroupLinearRowsFn = input();
|
12207
|
+
this.aiSortKeysMap = input();
|
12180
12208
|
this.aiGetI18nTextByKey = input();
|
12181
12209
|
this.aiKeywords = input();
|
12182
12210
|
this.aiFrozenColumnCountFn = input();
|
@@ -12230,6 +12258,9 @@ class AITableGridBase {
|
|
12230
12258
|
if (this.aiGetI18nTextByKey()) {
|
12231
12259
|
this.aiTable.getI18nTextByKey = this.aiGetI18nTextByKey();
|
12232
12260
|
}
|
12261
|
+
if (this.aiSortKeysMap()) {
|
12262
|
+
this.aiTable.sortKeysMap = this.aiSortKeysMap();
|
12263
|
+
}
|
12233
12264
|
this.aiPlugins()?.forEach((plugin) => {
|
12234
12265
|
this.aiTable = plugin(this.aiTable);
|
12235
12266
|
});
|
@@ -12293,7 +12324,7 @@ class AITableGridBase {
|
|
12293
12324
|
}
|
12294
12325
|
}
|
12295
12326
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableGridBase, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
12296
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.10", type: AITableGridBase, isStandalone: true, selector: "ai-table-grid-base", inputs: { aiRecords: { classPropertyName: "aiRecords", publicName: "aiRecords", isSignal: true, isRequired: true, transformFunction: null }, aiFields: { classPropertyName: "aiFields", publicName: "aiFields", isSignal: true, isRequired: true, transformFunction: null }, aiFieldsSizeMap: { classPropertyName: "aiFieldsSizeMap", publicName: "aiFieldsSizeMap", isSignal: true, isRequired: true, transformFunction: null }, aiContextMenuItems: { classPropertyName: "aiContextMenuItems", publicName: "aiContextMenuItems", isSignal: true, isRequired: false, transformFunction: null }, aiFieldConfig: { classPropertyName: "aiFieldConfig", publicName: "aiFieldConfig", isSignal: true, isRequired: false, transformFunction: null }, aiReadonly: { classPropertyName: "aiReadonly", publicName: "aiReadonly", isSignal: true, isRequired: false, transformFunction: null }, aiPlugins: { classPropertyName: "aiPlugins", publicName: "aiPlugins", isSignal: true, isRequired: false, transformFunction: null }, aiMaxFields: { classPropertyName: "aiMaxFields", publicName: "aiMaxFields", isSignal: true, isRequired: false, transformFunction: null }, aiMaxRecords: { classPropertyName: "aiMaxRecords", publicName: "aiMaxRecords", isSignal: true, isRequired: false, transformFunction: null }, aiMaxSelectOptions: { classPropertyName: "aiMaxSelectOptions", publicName: "aiMaxSelectOptions", isSignal: true, isRequired: false, transformFunction: null }, aiReferences: { classPropertyName: "aiReferences", publicName: "aiReferences", isSignal: true, isRequired: true, transformFunction: null }, aiBuildRenderDataFn: { classPropertyName: "aiBuildRenderDataFn", publicName: "aiBuildRenderDataFn", isSignal: true, isRequired: false, transformFunction: null }, aiBuildGroupLinearRowsFn: { classPropertyName: "aiBuildGroupLinearRowsFn", publicName: "aiBuildGroupLinearRowsFn", isSignal: true, isRequired: false, transformFunction: null }, aiGetI18nTextByKey: { classPropertyName: "aiGetI18nTextByKey", publicName: "aiGetI18nTextByKey", isSignal: true, isRequired: false, transformFunction: null }, aiKeywords: { classPropertyName: "aiKeywords", publicName: "aiKeywords", isSignal: true, isRequired: false, transformFunction: null }, aiFrozenColumnCountFn: { classPropertyName: "aiFrozenColumnCountFn", publicName: "aiFrozenColumnCountFn", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { aiRecords: "aiRecordsChange", aiFields: "aiFieldsChange", aiFieldsSizeMap: "aiFieldsSizeMapChange", aiTableInitialized: "aiTableInitialized", aiAddRecord: "aiAddRecord", aiAddField: "aiAddField", aiMoveField: "aiMoveField", aiUpdateFieldValues: "aiUpdateFieldValues", aiSetField: "aiSetField", aiSetFieldWidth: "aiSetFieldWidth", aiSetFieldStatType: "aiSetFieldStatType", aiMoveRecords: "aiMoveRecords", aiClick: "aiClick", aiDbClick: "aiDbClick", aiRowGroupCollapseClick: "aiRowGroupCollapseClick" }, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
12327
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.10", type: AITableGridBase, isStandalone: true, selector: "ai-table-grid-base", inputs: { aiRecords: { classPropertyName: "aiRecords", publicName: "aiRecords", isSignal: true, isRequired: true, transformFunction: null }, aiFields: { classPropertyName: "aiFields", publicName: "aiFields", isSignal: true, isRequired: true, transformFunction: null }, aiFieldsSizeMap: { classPropertyName: "aiFieldsSizeMap", publicName: "aiFieldsSizeMap", isSignal: true, isRequired: true, transformFunction: null }, aiContextMenuItems: { classPropertyName: "aiContextMenuItems", publicName: "aiContextMenuItems", isSignal: true, isRequired: false, transformFunction: null }, aiFieldConfig: { classPropertyName: "aiFieldConfig", publicName: "aiFieldConfig", isSignal: true, isRequired: false, transformFunction: null }, aiReadonly: { classPropertyName: "aiReadonly", publicName: "aiReadonly", isSignal: true, isRequired: false, transformFunction: null }, aiPlugins: { classPropertyName: "aiPlugins", publicName: "aiPlugins", isSignal: true, isRequired: false, transformFunction: null }, aiMaxFields: { classPropertyName: "aiMaxFields", publicName: "aiMaxFields", isSignal: true, isRequired: false, transformFunction: null }, aiMaxRecords: { classPropertyName: "aiMaxRecords", publicName: "aiMaxRecords", isSignal: true, isRequired: false, transformFunction: null }, aiMaxSelectOptions: { classPropertyName: "aiMaxSelectOptions", publicName: "aiMaxSelectOptions", isSignal: true, isRequired: false, transformFunction: null }, aiReferences: { classPropertyName: "aiReferences", publicName: "aiReferences", isSignal: true, isRequired: true, transformFunction: null }, aiBuildRenderDataFn: { classPropertyName: "aiBuildRenderDataFn", publicName: "aiBuildRenderDataFn", isSignal: true, isRequired: false, transformFunction: null }, aiBuildGroupLinearRowsFn: { classPropertyName: "aiBuildGroupLinearRowsFn", publicName: "aiBuildGroupLinearRowsFn", isSignal: true, isRequired: false, transformFunction: null }, aiSortKeysMap: { classPropertyName: "aiSortKeysMap", publicName: "aiSortKeysMap", isSignal: true, isRequired: false, transformFunction: null }, aiGetI18nTextByKey: { classPropertyName: "aiGetI18nTextByKey", publicName: "aiGetI18nTextByKey", isSignal: true, isRequired: false, transformFunction: null }, aiKeywords: { classPropertyName: "aiKeywords", publicName: "aiKeywords", isSignal: true, isRequired: false, transformFunction: null }, aiFrozenColumnCountFn: { classPropertyName: "aiFrozenColumnCountFn", publicName: "aiFrozenColumnCountFn", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { aiRecords: "aiRecordsChange", aiFields: "aiFieldsChange", aiFieldsSizeMap: "aiFieldsSizeMapChange", aiTableInitialized: "aiTableInitialized", aiAddRecord: "aiAddRecord", aiAddField: "aiAddField", aiMoveField: "aiMoveField", aiUpdateFieldValues: "aiUpdateFieldValues", aiSetField: "aiSetField", aiSetFieldWidth: "aiSetFieldWidth", aiSetFieldStatType: "aiSetFieldStatType", aiMoveRecords: "aiMoveRecords", aiClick: "aiClick", aiDbClick: "aiDbClick", aiRowGroupCollapseClick: "aiRowGroupCollapseClick" }, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
12297
12328
|
}
|
12298
12329
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableGridBase, decorators: [{
|
12299
12330
|
type: Component,
|
@@ -13038,18 +13069,29 @@ class AITableGrid extends AITableGridBase {
|
|
13038
13069
|
this.domToolTips = computed(() => {
|
13039
13070
|
const scrollTop = this.aiTable.context.scrollState().scrollTop;
|
13040
13071
|
const rowIndices = this.toolTipRowIndices();
|
13041
|
-
return rowIndices.map((rowIndex) => {
|
13072
|
+
return rowIndices.map(({ rowIndex, tooltip }) => {
|
13042
13073
|
const offset = this.coordinate().getRowOffset(rowIndex);
|
13043
13074
|
return {
|
13044
13075
|
top: offset - scrollTop - AI_TABLE_FIELD_HEAD_HEIGHT,
|
13045
|
-
left: 0
|
13076
|
+
left: 0,
|
13077
|
+
tooltip
|
13046
13078
|
};
|
13047
13079
|
});
|
13048
13080
|
});
|
13049
13081
|
this.toolTipRowIndices = computed(() => {
|
13050
13082
|
const hiddenRows = this.aiTable.recordsWillHidden() || [];
|
13083
|
+
const moveRows = this.aiTable.recordsWillMove() || [];
|
13051
13084
|
const toolTipRowIndices = hiddenRows.map((rowId) => {
|
13052
|
-
return
|
13085
|
+
return {
|
13086
|
+
tooltip: getI18nTextByKey(this.aiTable, AITableGridI18nKey.rowAddFilterTooltip),
|
13087
|
+
rowIndex: this.aiTable.context?.visibleRowsIndexMap().get(rowId) || 0
|
13088
|
+
};
|
13089
|
+
});
|
13090
|
+
moveRows.forEach((record) => {
|
13091
|
+
toolTipRowIndices.push({
|
13092
|
+
tooltip: getI18nTextByKey(this.aiTable, AITableGridI18nKey.rowWillMoveTooltip),
|
13093
|
+
rowIndex: this.aiTable.context?.visibleRowsIndexMap().get(record._id) || 0
|
13094
|
+
});
|
13053
13095
|
});
|
13054
13096
|
return toolTipRowIndices;
|
13055
13097
|
});
|
@@ -13216,10 +13258,13 @@ class AITableGrid extends AITableGridBase {
|
|
13216
13258
|
// 当新增行选中的cell,编辑后,activeCell 不在新增的行中时,根据筛选 过滤行数据,触发重新渲染
|
13217
13259
|
const activeCellPath = this.aiTable.selection().activeCell;
|
13218
13260
|
untracked(() => {
|
13219
|
-
if (!activeCellPath || !this.aiTable.recordsWillHidden().includes(activeCellPath[0]))
|
13220
|
-
|
13221
|
-
|
13222
|
-
|
13261
|
+
if ((!activeCellPath || !this.aiTable.recordsWillHidden().includes(activeCellPath[0])) &&
|
13262
|
+
this.aiTable.recordsWillHidden().length > 0) {
|
13263
|
+
this.aiTable.recordsWillHidden.set([]);
|
13264
|
+
}
|
13265
|
+
if ((!activeCellPath || !this.aiTable.recordsWillMove().has(activeCellPath[0])) &&
|
13266
|
+
this.aiTable.recordsWillMove().size > 0) {
|
13267
|
+
this.aiTable.recordsWillMove.set(new Map());
|
13223
13268
|
}
|
13224
13269
|
});
|
13225
13270
|
});
|
@@ -13263,6 +13308,7 @@ class AITableGrid extends AITableGridBase {
|
|
13263
13308
|
linearRows: this.linearRows,
|
13264
13309
|
visibleColumnsIndexMap: this.visibleColumnsIndexMap,
|
13265
13310
|
visibleRowsIndexMap: this.visibleRowsIndexMap,
|
13311
|
+
groupStatContainerWidthMap: signal(new Map()),
|
13266
13312
|
pointPosition: signal(DEFAULT_POINT_POSITION),
|
13267
13313
|
scrollState: signal(DEFAULT_SCROLL_STATE),
|
13268
13314
|
frozenColumnCount: this.frozenColumnCount,
|
@@ -13274,6 +13320,7 @@ class AITableGrid extends AITableGridBase {
|
|
13274
13320
|
maxSelectOptions: this.aiMaxSelectOptions,
|
13275
13321
|
fieldOptions: this.fieldOptions,
|
13276
13322
|
fieldOptionMap: this.fieldOptionMap,
|
13323
|
+
groupCollapseDisabled: signal(false),
|
13277
13324
|
readonly: this.aiReadonly
|
13278
13325
|
});
|
13279
13326
|
}
|
@@ -13294,8 +13341,9 @@ class AITableGrid extends AITableGridBase {
|
|
13294
13341
|
}
|
13295
13342
|
}
|
13296
13343
|
setKeywordsMatchedCells() {
|
13297
|
-
const keywords = this.aiKeywords();
|
13344
|
+
const keywords = this.aiKeywords() || '';
|
13298
13345
|
let matchedCells = new Set();
|
13346
|
+
this.aiTable.keywords.set(keywords);
|
13299
13347
|
if (keywords) {
|
13300
13348
|
const references = this.aiReferences();
|
13301
13349
|
this.aiTable.gridData().records.forEach((record) => {
|
@@ -14036,18 +14084,18 @@ class AITableGrid extends AITableGridBase {
|
|
14036
14084
|
});
|
14037
14085
|
}
|
14038
14086
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableGrid, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
14039
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableGrid, isStandalone: true, selector: "ai-table-grid", host: { classAttribute: "ai-table-grid" }, providers: [AITableGridEventService, AITableGridFieldService, AITableScrollControllerService], viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, isSignal: true }, { propertyName: "verticalBarRef", first: true, predicate: ["verticalBar"], descendants: true, isSignal: true }, { propertyName: "horizontalBarRef", first: true, predicate: ["horizontalBar"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div #container class=\"ai-table-grid-view\">\n @if (hasContainerRect()) {\n <ai-table-renderer\n [config]=\"rendererConfig()\"\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 (koWheel)=\"stageWheel($event)\"\n >\n @if (domToolTips().length > 0) {\n <div\n class=\"ai-table-left-background-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n @for (domToolTip of domToolTips(); track trackBy(idx, domToolTip); let idx = $index) {\n <div
|
14087
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: AITableGrid, isStandalone: true, selector: "ai-table-grid", host: { classAttribute: "ai-table-grid" }, providers: [AITableGridEventService, AITableGridFieldService, AITableScrollControllerService], viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, isSignal: true }, { propertyName: "verticalBarRef", first: true, predicate: ["verticalBar"], descendants: true, isSignal: true }, { propertyName: "horizontalBarRef", first: true, predicate: ["horizontalBar"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div #container class=\"ai-table-grid-view\">\n @if (hasContainerRect()) {\n <ai-table-renderer\n [config]=\"rendererConfig()\"\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 (koWheel)=\"stageWheel($event)\"\n >\n @if (domToolTips().length > 0) {\n <div\n class=\"ai-table-left-background-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n @for (domToolTip of domToolTips(); track trackBy(idx, domToolTip); let idx = $index) {\n <div class=\"ai-table-left-background\" [thyTooltip]=\"domToolTip.tooltip\" [style.--scroll-top.px]=\"domToolTip.top\">\n <thy-icon class=\"text-white\" thyIconName=\"filter-line\"></thy-icon>\n </div>\n }\n </div>\n }\n <div #horizontalBar class=\"ai-table-horizontal-scroll-bar-wrapper\" [style.width.px]=\"containerRect().width\">\n <div class=\"ai-table-scroll-bar-inner\" [style.width.px]=\"scrollbarWidth()\"></div>\n </div>\n <div\n #verticalBar\n class=\"ai-table-vertical-scroll-bar-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n <div class=\"ai-table-scroll-bar-inner\" [style.height.px]=\"scrollTotalHeight()\"></div>\n </div>\n </ai-table-renderer>\n }\n <ai-table-drag [horizontalBar]=\"horizontalBarRef()\" [verticalBar]=\"verticalBarRef()\" (dragEnd)=\"dragEnd($event)\"></ai-table-drag>\n</div>\n", dependencies: [{ kind: "component", type: AITableRenderer, selector: "ai-table-renderer", inputs: ["config"], outputs: ["koMousemove", "koMousedown", "koMouseup", "koContextmenu", "koWheel", "koClick", "koDblclick", "koMouseleave", "onScrollPosition"] }, { kind: "component", type: AITableDragComponent, selector: "ai-table-drag", inputs: ["horizontalBar", "verticalBar"], outputs: ["dragEnd"] }, { kind: "directive", type: ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { kind: "component", type: ThyIcon, selector: "thy-icon, [thy-icon]", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
14040
14088
|
}
|
14041
14089
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: AITableGrid, decorators: [{
|
14042
14090
|
type: Component,
|
14043
14091
|
args: [{ selector: 'ai-table-grid', changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
14044
14092
|
class: 'ai-table-grid'
|
14045
|
-
}, imports: [AITableRenderer, AITableDragComponent, ThyTooltipDirective, ThyIcon], providers: [AITableGridEventService, AITableGridFieldService, AITableScrollControllerService], template: "<div #container class=\"ai-table-grid-view\">\n @if (hasContainerRect()) {\n <ai-table-renderer\n [config]=\"rendererConfig()\"\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 (koWheel)=\"stageWheel($event)\"\n >\n @if (domToolTips().length > 0) {\n <div\n class=\"ai-table-left-background-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n @for (domToolTip of domToolTips(); track trackBy(idx, domToolTip); let idx = $index) {\n <div
|
14093
|
+
}, imports: [AITableRenderer, AITableDragComponent, ThyTooltipDirective, ThyIcon], providers: [AITableGridEventService, AITableGridFieldService, AITableScrollControllerService], template: "<div #container class=\"ai-table-grid-view\">\n @if (hasContainerRect()) {\n <ai-table-renderer\n [config]=\"rendererConfig()\"\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 (koWheel)=\"stageWheel($event)\"\n >\n @if (domToolTips().length > 0) {\n <div\n class=\"ai-table-left-background-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n @for (domToolTip of domToolTips(); track trackBy(idx, domToolTip); let idx = $index) {\n <div class=\"ai-table-left-background\" [thyTooltip]=\"domToolTip.tooltip\" [style.--scroll-top.px]=\"domToolTip.top\">\n <thy-icon class=\"text-white\" thyIconName=\"filter-line\"></thy-icon>\n </div>\n }\n </div>\n }\n <div #horizontalBar class=\"ai-table-horizontal-scroll-bar-wrapper\" [style.width.px]=\"containerRect().width\">\n <div class=\"ai-table-scroll-bar-inner\" [style.width.px]=\"scrollbarWidth()\"></div>\n </div>\n <div\n #verticalBar\n class=\"ai-table-vertical-scroll-bar-wrapper\"\n [style.height.px]=\"containerRect().height - fieldHeadHeight\"\n [style.top.px]=\"fieldHeadHeight\"\n >\n <div class=\"ai-table-scroll-bar-inner\" [style.height.px]=\"scrollTotalHeight()\"></div>\n </div>\n </ai-table-renderer>\n }\n <ai-table-drag [horizontalBar]=\"horizontalBarRef()\" [verticalBar]=\"verticalBarRef()\" (dragEnd)=\"dragEnd($event)\"></ai-table-drag>\n</div>\n" }]
|
14046
14094
|
}], ctorParameters: () => [] });
|
14047
14095
|
|
14048
14096
|
/**
|
14049
14097
|
* Generated bundle index. Do not edit.
|
14050
14098
|
*/
|
14051
14099
|
|
14052
|
-
export { AITable, AITableActionIcon, AITableAddField, AITableAreaType, AITableAvatarSize, AITableAvatarType, AITableBackground, AITableCellAttachment, AITableCellCheckbox, AITableCellLink, AITableCellProgress, AITableCellRate, AITableCellRichText, AITableCellText, AITableCells, AITableCheckType, AITableColumnHeads, AITableContextMenu, AITableDomGrid, AITableFieldHead, AITableFieldIcon, AITableFieldIsSameOptionPipe, AITableFieldSetting, AITableFrozenCells, AITableFrozenColumnHeads, AITableFrozenGroups, AITableFrozenPlaceholderCells, AITableGrid, AITableGridEventService, AITableGridFieldService, AITableGridI18nKey, AITableGridI18nText, AITableGroups, AITableHoverRowHeads, AITableIcon, AITableMemberType, AITableMouseDownType, AITableOtherRows, AITablePlaceholderCells, AITableQueries, AITableRenderer, AITableRowType, AITableScrollableGroup, AITableSelectAllState, AITableShadow, 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_LINE_BORDER, 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_BG, AI_TABLE_FIELD_STAT_CONTAINER_HEIGHT, AI_TABLE_FIELD_STAT_INNER_HEIGHT, AI_TABLE_FILE_ICON_ITEM_HEIGHT, AI_TABLE_FILE_ICON_SIZE, AI_TABLE_FILL_HANDLE, AI_TABLE_GRID_FIELD_SERVICE_MAP, AI_TABLE_GROUP_MAX_LEVEL, 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_OPTION_MULTI_ITEM_FONT_SIZE, 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_GROUP_COLLAPSE_BUTTON, AI_TABLE_ROW_GROUP_OFFSET, 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_SHADOW_DEFAULT_WIDTH, AI_TABLE_TAG_FONT_SIZE, AI_TABLE_TAG_PADDING, AI_TABLE_TEXT_GAP, AI_TABLE_TEXT_LINE_HEIGHT, AbstractEditCellEditor, AddOutlinedPath, AngleDownPath, AngleRightPath, AttachmentField, AttachmentPath, CellDrawer, Check, CheckboxMenuSort, Colors, ColumnCalendarFilledPath, ColumnCheckboxFilledPath, ColumnLinkOutlinedPath, ColumnMemberFilledPath, ColumnMultipleFillPath, ColumnNumberFilledPath, ColumnProgressFilledPath, ColumnRatingFilledPath, ColumnRichTextFilledPath, ColumnSelectFilledPath, ColumnTextFilledPath, Coordinate, CoverCellBase, 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, 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, clearCoverCell, clearSelectedCells, clearSelection, clearSelectionFields, clearSelectionRecords, closeEditingCell, closeExpendCell, compareNumber, compareOption, compareString, createAITable, createActiveCellBorder, createCells, createDefaultField, createDefaultFieldName, createListener, dragFillHighlightArea, drawer, expandCell, extractLinkUrl, extractText, generateNewName, generateTargetName, getAvatarBgColor, getAvatarShortName, getCellEditorBorderSpace, getCellHorizontalPosition, getColumnIndicesSizeMap, getCoverCell, getDateFieldValues, getDefaultFieldOptions,
|
14100
|
+
export { AITable, AITableActionIcon, AITableAddField, AITableAreaType, AITableAvatarSize, AITableAvatarType, AITableBackground, AITableCellAttachment, AITableCellCheckbox, AITableCellLink, AITableCellProgress, AITableCellRate, AITableCellRichText, AITableCellText, AITableCells, AITableCheckType, AITableColumnHeads, AITableContextMenu, AITableDomGrid, AITableFieldHead, AITableFieldIcon, AITableFieldIsSameOptionPipe, AITableFieldSetting, AITableFrozenCells, AITableFrozenColumnHeads, AITableFrozenGroups, AITableFrozenPlaceholderCells, AITableGrid, AITableGridEventService, AITableGridFieldService, AITableGridI18nKey, AITableGridI18nText, AITableGroups, AITableHoverRowHeads, AITableIcon, AITableMemberType, AITableMouseDownType, AITableOtherRows, AITablePlaceholderCells, AITableQueries, AITableRenderer, AITableRowType, AITableScrollableGroup, AITableSelectAllState, AITableShadow, 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_LINE_BORDER, 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_BG, AI_TABLE_FIELD_STAT_CONTAINER_HEIGHT, AI_TABLE_FIELD_STAT_INNER_HEIGHT, AI_TABLE_FILE_ICON_ITEM_HEIGHT, AI_TABLE_FILE_ICON_SIZE, AI_TABLE_FILL_HANDLE, AI_TABLE_GRID_FIELD_SERVICE_MAP, AI_TABLE_GROUP_MAX_LEVEL, 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_OPTION_MULTI_ITEM_FONT_SIZE, 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_GROUP_COLLAPSE_BUTTON, AI_TABLE_ROW_GROUP_OFFSET, 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_SHADOW_DEFAULT_WIDTH, AI_TABLE_TAG_FONT_SIZE, AI_TABLE_TAG_PADDING, AI_TABLE_TEXT_GAP, AI_TABLE_TEXT_LINE_HEIGHT, AbstractEditCellEditor, AddOutlinedPath, AngleDownPath, AngleRightPath, AttachmentField, AttachmentPath, CellDrawer, Check, CheckboxMenuSort, Colors, ColumnCalendarFilledPath, ColumnCheckboxFilledPath, ColumnLinkOutlinedPath, ColumnMemberFilledPath, ColumnMultipleFillPath, ColumnNumberFilledPath, ColumnProgressFilledPath, ColumnRatingFilledPath, ColumnRichTextFilledPath, ColumnSelectFilledPath, ColumnTextFilledPath, Coordinate, CoverCellBase, 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, GROUP_STAT_DEFAULT_FONT_SIZE, 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, buildNormalLinearRows, castToString, cellDrawer, clearCells, clearCoverCell, clearSelectedCells, clearSelection, clearSelectionFields, clearSelectionRecords, closeEditingCell, closeExpendCell, compareNumber, compareOption, compareString, createAITable, createActiveCellBorder, createCells, createDefaultField, createDefaultFieldName, createListener, dragFillHighlightArea, drawer, expandCell, extractLinkUrl, extractText, generateNewName, generateTargetName, getAvatarBgColor, getAvatarShortName, getCellEditorBorderSpace, getCellHorizontalPosition, getColumnIndicesSizeMap, getCoverCell, getDateFieldValues, getDefaultFieldOptions, getDefaultI18nTextByKey, getDetailByTargetName, getEditorBoxOffset, getEditorSpace, getFieldOptionByField, getFieldOptionMap, getFieldOptions, getFieldValue, getFileThumbnailSvgString, getFillDirection, getGroupLastRecordIndex, getHoverEditorBoxOffset, getHoverEditorSpace, getI18nTextByKey, getMousePosition, getName, getOptionsByFieldAndRecords, getPlaceHolderCellsConfigs, getStartAndEndCell, getSystemFieldValue, getTargetName, getTextWidth, getVisibleRangeInfo, graphemeSplitter, handleMouseStyle, hasIntersect, idCreator, idsCreator, imageCache, isActiveCell, isCellMatchKeywords, isClipboardReadSupported, isClipboardReadTextSupported, isClipboardWriteSupported, isClipboardWriteTextSupported, isEmptyOrNot, isMac, isMeetFilter, isSameFieldOption, isSelectedField, isSystemField, isVirtualKey, isWindows, isWindowsOS, isWithinFrozenColumnBoundary, performFill, processPastedValueForSelect, readFromClipboard, scrollMax, scrollToMatchedCell, selectCells, selectField, setActiveCell, setCollapseDisabled, setEditingCell, setExpandCellInfo, setMouseStyle, setSelection, shortIdCreator, shortIdsCreator, statDateRangeOfDays, statDateRangeOfMonths, statEarliestTime, statLatestTime, stringInclude, textDataCache, toAttachmentFieldValue, toDateFieldValue, toLinkFieldValue, toMemberFieldValue, toNumberFieldValue, toProgressFieldValue, toRateFieldValue, toRichTextFieldValue, toSelectFieldValue, toTextFieldValue, toggleSelectAllRecords, toggleSelectRecord, transformToCellText, updatePicture, writeToAITable, writeToClipboard, zhIntlCollator };
|
14053
14101
|
//# sourceMappingURL=ai-table-grid.mjs.map
|