@sapui5/sap.fe.macros 1.142.0 → 1.142.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/sap/fe/macros/.library +1 -1
- package/src/sap/fe/macros/Field.js +5 -5
- package/src/sap/fe/macros/Field.ts +5 -3
- package/src/sap/fe/macros/FooterContent.js +3 -2
- package/src/sap/fe/macros/FooterContent.tsx +2 -10
- package/src/sap/fe/macros/MessageButton.js +3 -3
- package/src/sap/fe/macros/MessageButton.tsx +3 -2
- package/src/sap/fe/macros/Page.js +8 -4
- package/src/sap/fe/macros/Page.tsx +13 -4
- package/src/sap/fe/macros/RichTextEditor.js +12 -14
- package/src/sap/fe/macros/RichTextEditor.tsx +10 -13
- package/src/sap/fe/macros/ai/EasyFillDialog.js +2 -1
- package/src/sap/fe/macros/ai/EasyFillDialog.tsx +1 -0
- package/src/sap/fe/macros/ai/SummarizationButton.js +6 -4
- package/src/sap/fe/macros/ai/SummarizationButton.tsx +5 -3
- package/src/sap/fe/macros/chart/Action.js +19 -7
- package/src/sap/fe/macros/chart/Action.ts +8 -0
- package/src/sap/fe/macros/chart/ChartDelegate.js +13 -2
- package/src/sap/fe/macros/chart/ChartDelegate.ts +20 -1
- package/src/sap/fe/macros/chart/MdcChartTemplate.js +8 -6
- package/src/sap/fe/macros/chart/MdcChartTemplate.tsx +13 -22
- package/src/sap/fe/macros/controls/FileWrapper.js +4 -3
- package/src/sap/fe/macros/controls/FileWrapper.ts +3 -2
- package/src/sap/fe/macros/controls/FilterBar.js +1 -1
- package/src/sap/fe/macros/controls/FilterBar.ts +8 -1
- package/src/sap/fe/macros/controls/Section.js +3 -2
- package/src/sap/fe/macros/controls/Section.ts +1 -1
- package/src/sap/fe/macros/controls/TextLink.js +15 -1
- package/src/sap/fe/macros/controls/TextLink.tsx +19 -0
- package/src/sap/fe/macros/coreUI/OperationParameterDialog.js +23 -18
- package/src/sap/fe/macros/coreUI/OperationParameterDialog.tsx +27 -25
- package/src/sap/fe/macros/field/FieldRuntimeHelper.js +4 -2
- package/src/sap/fe/macros/field/FieldRuntimeHelper.ts +7 -7
- package/src/sap/fe/macros/field/FieldTemplating.js +8 -3
- package/src/sap/fe/macros/field/FieldTemplating.ts +8 -3
- package/src/sap/fe/macros/filterBar/FilterBar.block.js +10 -1
- package/src/sap/fe/macros/filterBar/FilterBar.block.tsx +10 -0
- package/src/sap/fe/macros/form/FormContainer.block.js +9 -8
- package/src/sap/fe/macros/form/FormContainer.block.ts +10 -7
- package/src/sap/fe/macros/internal/field/DisplayStyle.js +3 -2
- package/src/sap/fe/macros/internal/field/DisplayStyle.tsx +1 -0
- package/src/sap/fe/macros/internal/field/EditStyle.js +11 -6
- package/src/sap/fe/macros/internal/field/EditStyle.tsx +7 -3
- package/src/sap/fe/macros/internal/valuehelp/AdditionalValueFormatter.js +36 -7
- package/src/sap/fe/macros/internal/valuehelp/AdditionalValueFormatter.ts +35 -6
- package/src/sap/fe/macros/internal/valuehelp/AdditionalValueHelper.js +54 -1
- package/src/sap/fe/macros/internal/valuehelp/AdditionalValueHelper.ts +59 -0
- package/src/sap/fe/macros/internal/valuehelp/ValueListHelper.js +23 -3
- package/src/sap/fe/macros/internal/valuehelp/ValueListHelper.ts +24 -2
- package/src/sap/fe/macros/library.js +5 -6
- package/src/sap/fe/macros/{library.ts → library.tsx} +1 -1
- package/src/sap/fe/macros/messagebundle.properties +6 -0
- package/src/sap/fe/macros/messages/MessageButton.js +21 -12
- package/src/sap/fe/macros/messages/MessageButton.ts +21 -11
- package/src/sap/fe/macros/multivaluefield/MultiValueFieldDelegate.js +8 -3
- package/src/sap/fe/macros/multivaluefield/MultiValueFieldDelegate.ts +9 -2
- package/src/sap/fe/macros/quickView/QuickView.js +5 -4
- package/src/sap/fe/macros/quickView/QuickView.tsx +10 -3
- package/src/sap/fe/macros/table/ActionsTemplating.js +6 -5
- package/src/sap/fe/macros/table/ActionsTemplating.tsx +4 -4
- package/src/sap/fe/macros/table/MdcTableTemplate.js +31 -13
- package/src/sap/fe/macros/table/MdcTableTemplate.tsx +35 -7
- package/src/sap/fe/macros/table/Table.block.js +3 -1
- package/src/sap/fe/macros/table/Table.block.tsx +7 -4
- package/src/sap/fe/macros/table/TableAPI.js +62 -28
- package/src/sap/fe/macros/table/TableAPI.ts +73 -32
- package/src/sap/fe/macros/table/TableEventHandlerProvider.js +15 -4
- package/src/sap/fe/macros/table/TableEventHandlerProvider.ts +16 -3
- package/src/sap/fe/macros/table/TableRuntime.js +6 -4
- package/src/sap/fe/macros/table/TableRuntime.ts +16 -3
- package/src/sap/fe/macros/table/delegates/TableDelegate.js +3 -3
- package/src/sap/fe/macros/table/delegates/TableDelegate.ts +3 -4
- package/src/sap/fe/macros/table/massEdit/MassEditDialog.js +41 -15
- package/src/sap/fe/macros/table/massEdit/MassEditDialog.tsx +41 -22
- package/src/sap/fe/macros/table/mixin/ContextMenuHandler.js +2 -4
- package/src/sap/fe/macros/table/mixin/ContextMenuHandler.ts +1 -2
- package/src/sap/fe/macros/table/mixin/EmptyRowsHandler.js +10 -4
- package/src/sap/fe/macros/table/mixin/EmptyRowsHandler.ts +9 -3
- package/src/sap/fe/macros/table/mixin/TableHierarchy.js +6 -6
- package/src/sap/fe/macros/table/mixin/TableHierarchy.ts +5 -5
- package/src/sap/fe/macros/valuehelp/ValueHelpDelegate.js +28 -10
- package/src/sap/fe/macros/valuehelp/ValueHelpDelegate.ts +33 -14
|
@@ -5,6 +5,7 @@ import type {
|
|
|
5
5
|
DataField,
|
|
6
6
|
DataFieldForAction,
|
|
7
7
|
DataFieldForAnnotation,
|
|
8
|
+
DataFieldTypes,
|
|
8
9
|
DataPoint,
|
|
9
10
|
FieldGroup,
|
|
10
11
|
LineItem,
|
|
@@ -90,6 +91,7 @@ import ContextMenuSetting from "sap/m/plugins/ContextMenuSetting";
|
|
|
90
91
|
import CopyProvider from "sap/m/plugins/CopyProvider";
|
|
91
92
|
import DataStateIndicator from "sap/m/plugins/DataStateIndicator";
|
|
92
93
|
import type Control from "sap/ui/core/Control";
|
|
94
|
+
import type CustomData from "sap/ui/core/CustomData";
|
|
93
95
|
import type UI5Element from "sap/ui/core/Element";
|
|
94
96
|
import Library from "sap/ui/core/Lib";
|
|
95
97
|
import type { TitleLevel } from "sap/ui/core/library";
|
|
@@ -732,7 +734,7 @@ function getCopyProvider(tableProperties: TableBlockProperties): CopyProvider {
|
|
|
732
734
|
* @param tableProperties
|
|
733
735
|
* @returns The CellSelector
|
|
734
736
|
*/
|
|
735
|
-
function getCellSelector(tableProperties: TableBlockProperties): CellSelector | undefined {
|
|
737
|
+
function getCellSelector(tableProperties: TableBlockProperties, handlerProvider: TableEventHandlerProvider): CellSelector | undefined {
|
|
736
738
|
const tableType = tableProperties.tableDefinition.control.type;
|
|
737
739
|
if (
|
|
738
740
|
!tableProperties.tableDefinition.control.disableCopyToClipboard &&
|
|
@@ -746,8 +748,9 @@ function getCellSelector(tableProperties: TableBlockProperties): CellSelector |
|
|
|
746
748
|
not(getDragAndDropEnabled(tableProperties.contextObjectPath, tableProperties.tableDefinition))
|
|
747
749
|
)}
|
|
748
750
|
rangeLimit={200}
|
|
751
|
+
selectionChange={handlerProvider.getCellsSelectionHandler()}
|
|
749
752
|
/>
|
|
750
|
-
);
|
|
753
|
+
) as CellSelector;
|
|
751
754
|
}
|
|
752
755
|
return undefined;
|
|
753
756
|
}
|
|
@@ -852,7 +855,6 @@ function getActionCommand(
|
|
|
852
855
|
onExecuteAction: parameters.handlerProvider.getDataFieldForActionButtonPressHandler(
|
|
853
856
|
dataField as DataFieldForAction,
|
|
854
857
|
action,
|
|
855
|
-
undefined,
|
|
856
858
|
forContextMenu
|
|
857
859
|
),
|
|
858
860
|
onExecuteIBN: parameters.handlerProvider.getDataFieldForIBNPressHandler(action, false),
|
|
@@ -1138,6 +1140,7 @@ function getCreationTemplate(
|
|
|
1138
1140
|
* @param tableDefinition The table definition
|
|
1139
1141
|
* @param column The column definition
|
|
1140
1142
|
* @param dataFieldContext The data field context
|
|
1143
|
+
* @param dataFieldObjectPath The data field object path
|
|
1141
1144
|
* @param collection The collection context
|
|
1142
1145
|
* @param enableAnalytics Whether analytics are enabled
|
|
1143
1146
|
* @param tableType The type of the table
|
|
@@ -1150,6 +1153,7 @@ function getCreationTemplate(
|
|
|
1150
1153
|
* @param showEmptyIndicator Whether to show the empty indicator
|
|
1151
1154
|
* @param className
|
|
1152
1155
|
* @param handlerProvider The handler provider
|
|
1156
|
+
* @param isConnectedField Indicates if the field is a connected field
|
|
1153
1157
|
* @returns The XML string representing the field.
|
|
1154
1158
|
*/
|
|
1155
1159
|
export function getMacroFieldTemplate(
|
|
@@ -1157,6 +1161,7 @@ export function getMacroFieldTemplate(
|
|
|
1157
1161
|
tableDefinition: TableVisualization,
|
|
1158
1162
|
column: AnnotationTableColumn,
|
|
1159
1163
|
dataFieldContext: Context,
|
|
1164
|
+
dataFieldObjectPath: DataModelObjectPath<DataFieldAbstractTypes>,
|
|
1160
1165
|
collection: Context,
|
|
1161
1166
|
enableAnalytics: boolean | undefined,
|
|
1162
1167
|
tableType: TableType,
|
|
@@ -1212,6 +1217,19 @@ export function getMacroFieldTemplate(
|
|
|
1212
1217
|
isAnalyticalAggregatedRow: tableDefinition.control.analyticalConfiguration?.aggregationOnLeafLevel,
|
|
1213
1218
|
reactiveAreaMode: reactiveAreaMode
|
|
1214
1219
|
};
|
|
1220
|
+
let customData: CustomData | undefined;
|
|
1221
|
+
|
|
1222
|
+
// In case we display a property with TextOnly text arragement in a non-analytical table, we still load the original property (using custom data)
|
|
1223
|
+
// to make sure intent-based navigation can use the value of the original property an not just its text representation.
|
|
1224
|
+
// For analytical tables, this is done by adding the original property as a context-defining property for the text property in the table converter (getExtensionInfoFromEntityType)
|
|
1225
|
+
if (
|
|
1226
|
+
tableDefinition.enableAnalytics !== true &&
|
|
1227
|
+
(
|
|
1228
|
+
dataFieldObjectPath.targetObject as DataFieldTypes | undefined
|
|
1229
|
+
)?.Value?.$target?.annotations?.Common?.Text?.annotations?.UI?.TextArrangement?.valueOf() === "UI.TextArrangementType/TextOnly"
|
|
1230
|
+
) {
|
|
1231
|
+
customData = createCustomData("extraProperty", `{${(dataFieldObjectPath.targetObject as DataFieldTypes).Value.path}}`);
|
|
1232
|
+
}
|
|
1215
1233
|
return (
|
|
1216
1234
|
<Field
|
|
1217
1235
|
vhIdPrefix={generate([tableId, "TableValueHelp"])}
|
|
@@ -1228,7 +1246,8 @@ export function getMacroFieldTemplate(
|
|
|
1228
1246
|
disableStrictHandling={column.disableStrictHandling}
|
|
1229
1247
|
>
|
|
1230
1248
|
{{
|
|
1231
|
-
formatOptions: <FieldFormatOptions {...formatOptions}
|
|
1249
|
+
formatOptions: <FieldFormatOptions {...formatOptions} />,
|
|
1250
|
+
customData
|
|
1232
1251
|
}}
|
|
1233
1252
|
</Field>
|
|
1234
1253
|
);
|
|
@@ -1332,7 +1351,7 @@ function getColumnContentTemplate(
|
|
|
1332
1351
|
.createBindingContext(dataFieldContext.getPath() + "/Target/$AnnotationPath/Data");
|
|
1333
1352
|
const fieldGroupCollectionLength = fieldGroup.Data.length - 1;
|
|
1334
1353
|
|
|
1335
|
-
const items = fieldGroup.Data.map((
|
|
1354
|
+
const items = fieldGroup.Data.map((_fieldGroupDataField: DataFieldAbstractTypes, fieldGroupDataFieldIdx: number) => {
|
|
1336
1355
|
const fieldGroupDataFieldContext = dataFieldCollectionContext
|
|
1337
1356
|
.getModel()
|
|
1338
1357
|
.createBindingContext(dataFieldCollectionContext.getPath() + "/" + fieldGroupDataFieldIdx);
|
|
@@ -1363,6 +1382,7 @@ function getColumnContentTemplate(
|
|
|
1363
1382
|
tableDefinition,
|
|
1364
1383
|
column,
|
|
1365
1384
|
fieldGroupDataFieldContext,
|
|
1385
|
+
fieldGroupDataFieldOP,
|
|
1366
1386
|
collection,
|
|
1367
1387
|
enableAnalytics,
|
|
1368
1388
|
tableType,
|
|
@@ -1392,6 +1412,7 @@ function getColumnContentTemplate(
|
|
|
1392
1412
|
tableDefinition,
|
|
1393
1413
|
column,
|
|
1394
1414
|
fieldGroupDataFieldContext,
|
|
1415
|
+
fieldGroupDataFieldOP,
|
|
1395
1416
|
collection,
|
|
1396
1417
|
enableAnalytics,
|
|
1397
1418
|
tableType,
|
|
@@ -1447,11 +1468,13 @@ function getColumnContentTemplate(
|
|
|
1447
1468
|
const connectedFieldsElementContext = dataFieldContext
|
|
1448
1469
|
.getModel()
|
|
1449
1470
|
.createBindingContext(`${connectedFieldsContext.getPath()}/${(connectedFieldsElement as DataField)?.Value?.path}`);
|
|
1471
|
+
const connectedFieldsElementOP = getInvolvedDataModelObjects<DataFieldAbstractTypes>(connectedFieldsElementContext);
|
|
1450
1472
|
const fieldTemplate = getMacroFieldTemplate(
|
|
1451
1473
|
tableId,
|
|
1452
1474
|
tableDefinition,
|
|
1453
1475
|
column,
|
|
1454
1476
|
connectedFieldsElementContext,
|
|
1477
|
+
connectedFieldsElementOP,
|
|
1455
1478
|
collection,
|
|
1456
1479
|
enableAnalytics,
|
|
1457
1480
|
tableType,
|
|
@@ -1548,6 +1571,7 @@ function getColumnContentTemplate(
|
|
|
1548
1571
|
tableDefinition,
|
|
1549
1572
|
column,
|
|
1550
1573
|
dataFieldContext,
|
|
1574
|
+
dataFieldOP,
|
|
1551
1575
|
collection,
|
|
1552
1576
|
enableAnalytics,
|
|
1553
1577
|
tableType,
|
|
@@ -1854,7 +1878,10 @@ export function getMDCTableTemplate(tableProperties: TableBlockProperties, param
|
|
|
1854
1878
|
{ key: "updatablePropertyPath", value: updatablePropertyPath || "" },
|
|
1855
1879
|
{ key: "exportRequestSize", value: tableProperties.tableDefinition.control.exportRequestSize }
|
|
1856
1880
|
];
|
|
1857
|
-
|
|
1881
|
+
let rowPressHandler;
|
|
1882
|
+
if (tableType === "ResponsiveTable") {
|
|
1883
|
+
rowPressHandler = parameters.handlerProvider.rowPress ? parameters.handlerProvider.noop : undefined;
|
|
1884
|
+
}
|
|
1858
1885
|
return (
|
|
1859
1886
|
<MDCTable
|
|
1860
1887
|
core:require={getCoreRequire(tableProperties.tableDefinition)}
|
|
@@ -1867,6 +1894,7 @@ export function getMDCTableTemplate(tableProperties: TableBlockProperties, param
|
|
|
1867
1894
|
busyIndicatorDelay={0}
|
|
1868
1895
|
enableExport={tableProperties.tableDefinition.control.enableExport}
|
|
1869
1896
|
delegate={JSON.parse(delegate)}
|
|
1897
|
+
rowPress={rowPressHandler}
|
|
1870
1898
|
beforeOpenContextMenu={parameters.handlerProvider.beforeOpenContextMenu}
|
|
1871
1899
|
autoBindOnInit={tableProperties.useBasicSearch || !tableProperties.filterBar}
|
|
1872
1900
|
selectionMode={tableProperties.tableDefinition.annotation.selectionMode || "None"}
|
|
@@ -1917,7 +1945,7 @@ export function getMDCTableTemplate(tableProperties: TableBlockProperties, param
|
|
|
1917
1945
|
),
|
|
1918
1946
|
quickFilter: getQuickFilter(tableProperties),
|
|
1919
1947
|
copyProvider: getCopyProvider(tableProperties),
|
|
1920
|
-
cellSelector: getCellSelector(tableProperties)
|
|
1948
|
+
cellSelector: getCellSelector(tableProperties, parameters.handlerProvider)
|
|
1921
1949
|
}}
|
|
1922
1950
|
</MDCTable>
|
|
1923
1951
|
);
|