@progress/kendo-angular-conversational-ui 23.0.0-develop.8 → 23.0.0
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/codemods/utils.js +285 -39
- package/codemods/v23/chat-FileSelectSettings.js +27 -0
- package/codemods/v23/chat-enableFileSelect.js +49 -0
- package/codemods/v23/chat-enableSpeechToText.js +49 -0
- package/codemods/v23/customMessages-send.js +49 -0
- package/fesm2022/progress-kendo-angular-conversational-ui.mjs +43 -21
- package/package-metadata.mjs +2 -2
- package/package.json +36 -14
package/codemods/utils.js
CHANGED
|
@@ -775,6 +775,83 @@ const tsPropertyTransformer = (source, root, j, packageName, componentType, prop
|
|
|
775
775
|
localVariables.add(path.node.id.name);
|
|
776
776
|
}
|
|
777
777
|
});
|
|
778
|
+
// Find array variables of type componentType[]
|
|
779
|
+
// This handles cases like: const arr: ChatComponent[] = [...]; arr[0].property = value;
|
|
780
|
+
const arrayVariables = new Set();
|
|
781
|
+
root.find(j.VariableDeclarator).forEach((path) => {
|
|
782
|
+
if (path.node.id.type === 'Identifier' &&
|
|
783
|
+
path.node.id.typeAnnotation &&
|
|
784
|
+
path.node.id.typeAnnotation.typeAnnotation?.type === 'TSArrayType' &&
|
|
785
|
+
path.node.id.typeAnnotation.typeAnnotation.elementType?.type === 'TSTypeReference' &&
|
|
786
|
+
path.node.id.typeAnnotation.typeAnnotation.elementType.typeName?.type === 'Identifier' &&
|
|
787
|
+
path.node.id.typeAnnotation.typeAnnotation.elementType.typeName.name === componentType) {
|
|
788
|
+
arrayVariables.add(path.node.id.name);
|
|
789
|
+
}
|
|
790
|
+
});
|
|
791
|
+
// Find object properties that have componentType (e.g., {chat: ChatComponent})
|
|
792
|
+
// This handles cases like: const config: {chat: ChatComponent} = {...}; config.chat.property = value;
|
|
793
|
+
const objectProperties = new Map(); // Maps variable name to property names
|
|
794
|
+
root.find(j.VariableDeclarator).forEach((path) => {
|
|
795
|
+
if (path.node.id.type === 'Identifier' &&
|
|
796
|
+
path.node.id.typeAnnotation &&
|
|
797
|
+
path.node.id.typeAnnotation.typeAnnotation?.type === 'TSTypeLiteral') {
|
|
798
|
+
const varName = path.node.id.name;
|
|
799
|
+
const members = path.node.id.typeAnnotation.typeAnnotation.members;
|
|
800
|
+
members.forEach((member) => {
|
|
801
|
+
if (member.type === 'TSPropertySignature' &&
|
|
802
|
+
member.key &&
|
|
803
|
+
member.key.type === 'Identifier' &&
|
|
804
|
+
member.typeAnnotation &&
|
|
805
|
+
member.typeAnnotation.typeAnnotation?.type === 'TSTypeReference' &&
|
|
806
|
+
member.typeAnnotation.typeAnnotation.typeName?.type === 'Identifier' &&
|
|
807
|
+
member.typeAnnotation.typeAnnotation.typeName.name === componentType) {
|
|
808
|
+
if (!objectProperties.has(varName)) {
|
|
809
|
+
objectProperties.set(varName, []);
|
|
810
|
+
}
|
|
811
|
+
objectProperties.get(varName).push(member.key.name);
|
|
812
|
+
}
|
|
813
|
+
});
|
|
814
|
+
}
|
|
815
|
+
});
|
|
816
|
+
// Helper function to check if a node is a componentType instance
|
|
817
|
+
const isComponentTypeInstance = (node) => {
|
|
818
|
+
// Direct identifier (parameter or local variable)
|
|
819
|
+
if (node.type === 'Identifier') {
|
|
820
|
+
return parameters.has(node.name) || localVariables.has(node.name);
|
|
821
|
+
}
|
|
822
|
+
// this.property where property is of componentType
|
|
823
|
+
if (node.type === 'MemberExpression' && node.property.type === 'Identifier') {
|
|
824
|
+
if (node.object.type === 'ThisExpression' && properties.has(node.property.name)) {
|
|
825
|
+
return true;
|
|
826
|
+
}
|
|
827
|
+
// Handle nested object properties: objectVar.propertyName where propertyName is of componentType
|
|
828
|
+
if (node.object.type === 'Identifier') {
|
|
829
|
+
const objName = node.object.name;
|
|
830
|
+
const propName = node.property.name;
|
|
831
|
+
if (objectProperties.has(objName)) {
|
|
832
|
+
const props = objectProperties.get(objName);
|
|
833
|
+
return props.includes(propName);
|
|
834
|
+
}
|
|
835
|
+
}
|
|
836
|
+
}
|
|
837
|
+
// Array element access: arrayVar[index]
|
|
838
|
+
if (node.type === 'MemberExpression' &&
|
|
839
|
+
node.object.type === 'Identifier' &&
|
|
840
|
+
arrayVariables.has(node.object.name)) {
|
|
841
|
+
return true;
|
|
842
|
+
}
|
|
843
|
+
// TypeScript type assertions like (this.componentProperty as ComponentType)
|
|
844
|
+
if (node.type === 'TSAsExpression') {
|
|
845
|
+
if (node.typeAnnotation &&
|
|
846
|
+
node.typeAnnotation.type === 'TSTypeReference' &&
|
|
847
|
+
node.typeAnnotation.typeName &&
|
|
848
|
+
node.typeAnnotation.typeName.type === 'Identifier' &&
|
|
849
|
+
node.typeAnnotation.typeName.name === componentType) {
|
|
850
|
+
return true;
|
|
851
|
+
}
|
|
852
|
+
}
|
|
853
|
+
return false;
|
|
854
|
+
};
|
|
778
855
|
// Find all member expressions where propertyName is accessed on any componentType instance
|
|
779
856
|
root.find(j.MemberExpression, {
|
|
780
857
|
property: {
|
|
@@ -783,31 +860,7 @@ const tsPropertyTransformer = (source, root, j, packageName, componentType, prop
|
|
|
783
860
|
},
|
|
784
861
|
})
|
|
785
862
|
.filter((path) => {
|
|
786
|
-
|
|
787
|
-
if (path.node.object.type === 'MemberExpression' && path.node.object.property.type === 'Identifier') {
|
|
788
|
-
// handle properties of this
|
|
789
|
-
if (path.node.object.object.type === 'ThisExpression' &&
|
|
790
|
-
properties.has(path.node.object.property.name)) {
|
|
791
|
-
return true;
|
|
792
|
-
}
|
|
793
|
-
}
|
|
794
|
-
// Handle function parameters and local variables
|
|
795
|
-
if (path.node.object.type === 'Identifier') {
|
|
796
|
-
return parameters.has(path.node.object.name) || localVariables.has(path.node.object.name);
|
|
797
|
-
}
|
|
798
|
-
// Handle TypeScript type assertions like (this.componentProperty as ComponentType).property
|
|
799
|
-
if (path.node.object.type === 'TSAsExpression') {
|
|
800
|
-
const typeAssertion = path.node.object;
|
|
801
|
-
// Check if the type assertion is casting to our componentType
|
|
802
|
-
if (typeAssertion.typeAnnotation &&
|
|
803
|
-
typeAssertion.typeAnnotation.type === 'TSTypeReference' &&
|
|
804
|
-
typeAssertion.typeAnnotation.typeName &&
|
|
805
|
-
typeAssertion.typeAnnotation.typeName.type === 'Identifier' &&
|
|
806
|
-
typeAssertion.typeAnnotation.typeName.name === componentType) {
|
|
807
|
-
return true;
|
|
808
|
-
}
|
|
809
|
-
}
|
|
810
|
-
return false;
|
|
863
|
+
return isComponentTypeInstance(path.node.object);
|
|
811
864
|
})
|
|
812
865
|
.forEach((path) => {
|
|
813
866
|
// Replace old property name with new property name
|
|
@@ -844,6 +897,91 @@ const tsPropertyTransformer = (source, root, j, packageName, componentType, prop
|
|
|
844
897
|
}
|
|
845
898
|
}
|
|
846
899
|
});
|
|
900
|
+
// Transform object literal properties in variable declarations and assignments
|
|
901
|
+
// This handles cases like: const obj: ComponentType = { oldProperty: 'value' }
|
|
902
|
+
root.find(j.VariableDeclarator)
|
|
903
|
+
.filter((path) => {
|
|
904
|
+
// Check if the variable has the componentType type annotation
|
|
905
|
+
return Boolean(path.node.id.type === 'Identifier' &&
|
|
906
|
+
path.node.id.typeAnnotation &&
|
|
907
|
+
path.node.id.typeAnnotation.typeAnnotation?.type === 'TSTypeReference' &&
|
|
908
|
+
path.node.id.typeAnnotation.typeAnnotation.typeName?.type === 'Identifier' &&
|
|
909
|
+
path.node.id.typeAnnotation.typeAnnotation.typeName.name === componentType);
|
|
910
|
+
})
|
|
911
|
+
.forEach((path) => {
|
|
912
|
+
// Check if the initializer is an object expression
|
|
913
|
+
if (path.node.init && path.node.init.type === 'ObjectExpression') {
|
|
914
|
+
path.node.init.properties.forEach((prop) => {
|
|
915
|
+
// Rename the property if it matches
|
|
916
|
+
if (prop.type === 'ObjectProperty' &&
|
|
917
|
+
prop.key &&
|
|
918
|
+
prop.key.type === 'Identifier' &&
|
|
919
|
+
prop.key.name === propertyName) {
|
|
920
|
+
prop.key.name = newPropertyName;
|
|
921
|
+
}
|
|
922
|
+
});
|
|
923
|
+
}
|
|
924
|
+
});
|
|
925
|
+
// Transform object literal properties in class properties
|
|
926
|
+
// This handles cases like: customMessages: ComponentType = { oldProperty: 'value' }
|
|
927
|
+
root.find(j.ClassProperty)
|
|
928
|
+
.filter((path) => {
|
|
929
|
+
// Check if the property has the componentType type annotation
|
|
930
|
+
return Boolean(path.node.typeAnnotation &&
|
|
931
|
+
path.node.typeAnnotation.typeAnnotation?.type === 'TSTypeReference' &&
|
|
932
|
+
path.node.typeAnnotation.typeAnnotation.typeName?.type === 'Identifier' &&
|
|
933
|
+
path.node.typeAnnotation.typeAnnotation.typeName.name === componentType);
|
|
934
|
+
})
|
|
935
|
+
.forEach((path) => {
|
|
936
|
+
// Check if the value is an object expression
|
|
937
|
+
if (path.node.value && path.node.value.type === 'ObjectExpression') {
|
|
938
|
+
path.node.value.properties.forEach((prop) => {
|
|
939
|
+
// Rename the property if it matches
|
|
940
|
+
if (prop.type === 'ObjectProperty' &&
|
|
941
|
+
prop.key &&
|
|
942
|
+
prop.key.type === 'Identifier' &&
|
|
943
|
+
prop.key.name === propertyName) {
|
|
944
|
+
prop.key.name = newPropertyName;
|
|
945
|
+
}
|
|
946
|
+
});
|
|
947
|
+
}
|
|
948
|
+
});
|
|
949
|
+
// Transform object literal properties in assignment expressions
|
|
950
|
+
// This handles cases like: this.obj = { oldProperty: 'value' }
|
|
951
|
+
root.find(j.AssignmentExpression)
|
|
952
|
+
.filter((path) => {
|
|
953
|
+
// Check if we're assigning an object literal
|
|
954
|
+
return path.node.right.type === 'ObjectExpression';
|
|
955
|
+
})
|
|
956
|
+
.forEach((path) => {
|
|
957
|
+
// We need to determine if the left side is of componentType
|
|
958
|
+
// This is more complex as we need to check the type of the assignment target
|
|
959
|
+
const leftSide = path.node.left;
|
|
960
|
+
let isTargetComponentType = false;
|
|
961
|
+
// Check if it's a property that we know is of componentType
|
|
962
|
+
if (leftSide.type === 'MemberExpression' && leftSide.property.type === 'Identifier') {
|
|
963
|
+
if (leftSide.object.type === 'ThisExpression' && properties.has(leftSide.property.name)) {
|
|
964
|
+
isTargetComponentType = true;
|
|
965
|
+
}
|
|
966
|
+
else if (leftSide.object.type === 'Identifier' && localVariables.has(leftSide.object.name)) {
|
|
967
|
+
isTargetComponentType = true;
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
else if (leftSide.type === 'Identifier') {
|
|
971
|
+
isTargetComponentType = localVariables.has(leftSide.name) || parameters.has(leftSide.name);
|
|
972
|
+
}
|
|
973
|
+
if (isTargetComponentType && path.node.right.type === 'ObjectExpression') {
|
|
974
|
+
path.node.right.properties.forEach((prop) => {
|
|
975
|
+
// Rename the property if it matches
|
|
976
|
+
if (prop.type === 'ObjectProperty' &&
|
|
977
|
+
prop.key &&
|
|
978
|
+
prop.key.type === 'Identifier' &&
|
|
979
|
+
prop.key.name === propertyName) {
|
|
980
|
+
prop.key.name = newPropertyName;
|
|
981
|
+
}
|
|
982
|
+
});
|
|
983
|
+
}
|
|
984
|
+
});
|
|
847
985
|
}
|
|
848
986
|
};
|
|
849
987
|
exports.tsPropertyTransformer = tsPropertyTransformer;
|
|
@@ -1022,6 +1160,103 @@ const tsInterfaceTransformer = (fileInfo, rootSource, j, packageName, interfaceN
|
|
|
1022
1160
|
path.node.callee.name = newName;
|
|
1023
1161
|
}
|
|
1024
1162
|
});
|
|
1163
|
+
// Helper function to recursively transform type references
|
|
1164
|
+
const transformTypeReference = (typeNode) => {
|
|
1165
|
+
if (!typeNode)
|
|
1166
|
+
return;
|
|
1167
|
+
// Handle TSTypeReference (e.g., FileSelectSettings)
|
|
1168
|
+
if (typeNode.type === 'TSTypeReference' &&
|
|
1169
|
+
typeNode.typeName &&
|
|
1170
|
+
typeNode.typeName.type === 'Identifier' &&
|
|
1171
|
+
typeNode.typeName.name === interfaceName) {
|
|
1172
|
+
typeNode.typeName.name = newName;
|
|
1173
|
+
}
|
|
1174
|
+
// Handle TSArrayType (e.g., FileSelectSettings[])
|
|
1175
|
+
if (typeNode.type === 'TSArrayType' && typeNode.elementType) {
|
|
1176
|
+
transformTypeReference(typeNode.elementType);
|
|
1177
|
+
}
|
|
1178
|
+
// Handle generic Array<T> (e.g., Array<FileSelectSettings>)
|
|
1179
|
+
if (typeNode.type === 'TSTypeReference' &&
|
|
1180
|
+
typeNode.typeParameters &&
|
|
1181
|
+
typeNode.typeParameters.params) {
|
|
1182
|
+
typeNode.typeParameters.params.forEach((param) => {
|
|
1183
|
+
transformTypeReference(param);
|
|
1184
|
+
});
|
|
1185
|
+
}
|
|
1186
|
+
// Handle TSTypeLiteral (e.g., { primary: FileSelectSettings })
|
|
1187
|
+
if (typeNode.type === 'TSTypeLiteral' && typeNode.members) {
|
|
1188
|
+
typeNode.members.forEach((member) => {
|
|
1189
|
+
if (member.typeAnnotation && member.typeAnnotation.typeAnnotation) {
|
|
1190
|
+
transformTypeReference(member.typeAnnotation.typeAnnotation);
|
|
1191
|
+
}
|
|
1192
|
+
});
|
|
1193
|
+
}
|
|
1194
|
+
// Handle TSFunctionType (e.g., (settings: FileSelectSettings) => void)
|
|
1195
|
+
if (typeNode.type === 'TSFunctionType') {
|
|
1196
|
+
if (typeNode.parameters) {
|
|
1197
|
+
typeNode.parameters.forEach((param) => {
|
|
1198
|
+
if (param.typeAnnotation && param.typeAnnotation.typeAnnotation) {
|
|
1199
|
+
transformTypeReference(param.typeAnnotation.typeAnnotation);
|
|
1200
|
+
}
|
|
1201
|
+
});
|
|
1202
|
+
}
|
|
1203
|
+
if (typeNode.typeAnnotation && typeNode.typeAnnotation.typeAnnotation) {
|
|
1204
|
+
transformTypeReference(typeNode.typeAnnotation.typeAnnotation);
|
|
1205
|
+
}
|
|
1206
|
+
}
|
|
1207
|
+
};
|
|
1208
|
+
// Apply recursive transformation to all type annotations
|
|
1209
|
+
rootSource.find(j.VariableDeclarator).forEach((path) => {
|
|
1210
|
+
if (path.node.id.type === 'Identifier' &&
|
|
1211
|
+
path.node.id.typeAnnotation &&
|
|
1212
|
+
path.node.id.typeAnnotation.typeAnnotation) {
|
|
1213
|
+
transformTypeReference(path.node.id.typeAnnotation.typeAnnotation);
|
|
1214
|
+
}
|
|
1215
|
+
});
|
|
1216
|
+
rootSource.find(j.ClassProperty).forEach((path) => {
|
|
1217
|
+
if (path.node.typeAnnotation && path.node.typeAnnotation.typeAnnotation) {
|
|
1218
|
+
transformTypeReference(path.node.typeAnnotation.typeAnnotation);
|
|
1219
|
+
}
|
|
1220
|
+
});
|
|
1221
|
+
rootSource.find(j.ClassMethod).forEach((path) => {
|
|
1222
|
+
if (path.node.returnType && path.node.returnType.typeAnnotation) {
|
|
1223
|
+
transformTypeReference(path.node.returnType.typeAnnotation);
|
|
1224
|
+
}
|
|
1225
|
+
// Transform parameter types recursively
|
|
1226
|
+
if (path.node.params) {
|
|
1227
|
+
path.node.params.forEach((param) => {
|
|
1228
|
+
if (param.typeAnnotation && param.typeAnnotation.typeAnnotation) {
|
|
1229
|
+
transformTypeReference(param.typeAnnotation.typeAnnotation);
|
|
1230
|
+
}
|
|
1231
|
+
});
|
|
1232
|
+
}
|
|
1233
|
+
});
|
|
1234
|
+
rootSource.find(j.FunctionDeclaration).forEach((path) => {
|
|
1235
|
+
if (path.node.returnType && path.node.returnType.typeAnnotation) {
|
|
1236
|
+
transformTypeReference(path.node.returnType.typeAnnotation);
|
|
1237
|
+
}
|
|
1238
|
+
// Transform parameter types recursively
|
|
1239
|
+
if (path.node.params) {
|
|
1240
|
+
path.node.params.forEach((param) => {
|
|
1241
|
+
if (param.typeAnnotation && param.typeAnnotation.typeAnnotation) {
|
|
1242
|
+
transformTypeReference(param.typeAnnotation.typeAnnotation);
|
|
1243
|
+
}
|
|
1244
|
+
});
|
|
1245
|
+
}
|
|
1246
|
+
});
|
|
1247
|
+
rootSource.find(j.ArrowFunctionExpression).forEach((path) => {
|
|
1248
|
+
if (path.node.returnType && path.node.returnType.typeAnnotation) {
|
|
1249
|
+
transformTypeReference(path.node.returnType.typeAnnotation);
|
|
1250
|
+
}
|
|
1251
|
+
// Transform parameter types recursively
|
|
1252
|
+
if (path.node.params) {
|
|
1253
|
+
path.node.params.forEach((param) => {
|
|
1254
|
+
if (param.typeAnnotation && param.typeAnnotation.typeAnnotation) {
|
|
1255
|
+
transformTypeReference(param.typeAnnotation.typeAnnotation);
|
|
1256
|
+
}
|
|
1257
|
+
});
|
|
1258
|
+
}
|
|
1259
|
+
});
|
|
1025
1260
|
}
|
|
1026
1261
|
};
|
|
1027
1262
|
exports.tsInterfaceTransformer = tsInterfaceTransformer;
|
|
@@ -1035,21 +1270,26 @@ function isComponentTypeMatch(root, j, node, componentType) {
|
|
|
1035
1270
|
if (node.type === 'Identifier') {
|
|
1036
1271
|
const paramName = node.name;
|
|
1037
1272
|
// Check function parameters
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1273
|
+
let isParameter = false;
|
|
1274
|
+
root.find(j.Function).forEach((path) => {
|
|
1275
|
+
if (path.node.params && path.node.params.some((param) => param.type === 'Identifier' &&
|
|
1276
|
+
param.name === paramName &&
|
|
1277
|
+
param.typeAnnotation?.typeAnnotation?.typeName?.name === componentType)) {
|
|
1278
|
+
isParameter = true;
|
|
1279
|
+
}
|
|
1043
1280
|
});
|
|
1044
1281
|
if (isParameter)
|
|
1045
1282
|
return true;
|
|
1046
1283
|
// Check local variable declarations
|
|
1047
|
-
|
|
1048
|
-
|
|
1284
|
+
let isLocalVariable = false;
|
|
1285
|
+
root.find(j.VariableDeclarator).forEach((path) => {
|
|
1286
|
+
if (path.node.id.type === 'Identifier' &&
|
|
1049
1287
|
path.node.id.name === paramName &&
|
|
1050
1288
|
path.node.id.typeAnnotation?.typeAnnotation?.type === 'TSTypeReference' &&
|
|
1051
1289
|
path.node.id.typeAnnotation.typeAnnotation.typeName?.type === 'Identifier' &&
|
|
1052
|
-
path.node.id.typeAnnotation.typeAnnotation.typeName.name === componentType)
|
|
1290
|
+
path.node.id.typeAnnotation.typeAnnotation.typeName.name === componentType) {
|
|
1291
|
+
isLocalVariable = true;
|
|
1292
|
+
}
|
|
1053
1293
|
});
|
|
1054
1294
|
return isLocalVariable;
|
|
1055
1295
|
}
|
|
@@ -1072,13 +1312,14 @@ function isComponentTypeMatch(root, j, node, componentType) {
|
|
|
1072
1312
|
const varName = node.object.name;
|
|
1073
1313
|
const propName = node.property.name;
|
|
1074
1314
|
// Check if this is an object with a property of componentType
|
|
1075
|
-
|
|
1315
|
+
let hasMatchingProperty = false;
|
|
1316
|
+
root.find(j.VariableDeclarator).forEach((path) => {
|
|
1076
1317
|
if (path.node.id.type === 'Identifier' &&
|
|
1077
1318
|
path.node.id.name === varName &&
|
|
1078
1319
|
path.node.id.typeAnnotation &&
|
|
1079
1320
|
path.node.id.typeAnnotation.typeAnnotation?.type === 'TSTypeLiteral') {
|
|
1080
1321
|
const members = path.node.id.typeAnnotation.typeAnnotation.members;
|
|
1081
|
-
|
|
1322
|
+
const found = members.some((member) => {
|
|
1082
1323
|
return (member.type === 'TSPropertySignature' &&
|
|
1083
1324
|
member.key?.type === 'Identifier' &&
|
|
1084
1325
|
member.key.name === propName &&
|
|
@@ -1086,8 +1327,10 @@ function isComponentTypeMatch(root, j, node, componentType) {
|
|
|
1086
1327
|
member.typeAnnotation.typeAnnotation.typeName?.type === 'Identifier' &&
|
|
1087
1328
|
member.typeAnnotation.typeAnnotation.typeName.name === componentType);
|
|
1088
1329
|
});
|
|
1330
|
+
if (found) {
|
|
1331
|
+
hasMatchingProperty = true;
|
|
1332
|
+
}
|
|
1089
1333
|
}
|
|
1090
|
-
return false;
|
|
1091
1334
|
});
|
|
1092
1335
|
return hasMatchingProperty;
|
|
1093
1336
|
}
|
|
@@ -1097,13 +1340,16 @@ function isComponentTypeMatch(root, j, node, componentType) {
|
|
|
1097
1340
|
if (node.type === 'MemberExpression' && node.computed === true && node.object.type === 'Identifier') {
|
|
1098
1341
|
const arrayName = node.object.name;
|
|
1099
1342
|
// Check if this array is of type ChatComponent[]
|
|
1100
|
-
|
|
1101
|
-
|
|
1343
|
+
let isComponentArray = false;
|
|
1344
|
+
root.find(j.VariableDeclarator).forEach((path) => {
|
|
1345
|
+
if (path.node.id.type === 'Identifier' &&
|
|
1102
1346
|
path.node.id.name === arrayName &&
|
|
1103
1347
|
path.node.id.typeAnnotation?.typeAnnotation?.type === 'TSArrayType' &&
|
|
1104
1348
|
path.node.id.typeAnnotation.typeAnnotation.elementType?.type === 'TSTypeReference' &&
|
|
1105
1349
|
path.node.id.typeAnnotation.typeAnnotation.elementType.typeName?.type === 'Identifier' &&
|
|
1106
|
-
path.node.id.typeAnnotation.typeAnnotation.elementType.typeName.name === componentType)
|
|
1350
|
+
path.node.id.typeAnnotation.typeAnnotation.elementType.typeName.name === componentType) {
|
|
1351
|
+
isComponentArray = true;
|
|
1352
|
+
}
|
|
1107
1353
|
});
|
|
1108
1354
|
return isComponentArray;
|
|
1109
1355
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
"use strict";
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.default = default_1;
|
|
8
|
+
const utils_1 = require("../utils");
|
|
9
|
+
function default_1(fileInfo, api) {
|
|
10
|
+
const j = api.jscodeshift;
|
|
11
|
+
const rootSource = j(fileInfo.source);
|
|
12
|
+
(0, utils_1.tsInterfaceTransformer)(fileInfo, rootSource, j, '@progress/kendo-angular-upload', 'FileSelectSettings', 'FileSelectButtonSettings');
|
|
13
|
+
// Update import statement from @progress/kendo-angular-upload to @progress/kendo-angular-conversational-ui
|
|
14
|
+
rootSource.find(j.ImportDeclaration, {
|
|
15
|
+
source: { value: '@progress/kendo-angular-upload' }
|
|
16
|
+
}).forEach(path => {
|
|
17
|
+
const specifiers = path.node.specifiers;
|
|
18
|
+
const hasFileSelectButtonSettings = specifiers?.some(spec => spec.type === 'ImportSpecifier' &&
|
|
19
|
+
spec.imported.type === 'Identifier' &&
|
|
20
|
+
spec.imported.name === 'FileSelectButtonSettings');
|
|
21
|
+
if (hasFileSelectButtonSettings) {
|
|
22
|
+
path.node.source.value = '@progress/kendo-angular-conversational-ui';
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
//to use single quotes in the transformed file use rootSource.toSource({ quote: 'single' });
|
|
26
|
+
return rootSource.toSource();
|
|
27
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
"use strict";
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
23
|
+
if (mod && mod.__esModule) return mod;
|
|
24
|
+
var result = {};
|
|
25
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
26
|
+
__setModuleDefault(result, mod);
|
|
27
|
+
return result;
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.default = default_1;
|
|
31
|
+
const fs = __importStar(require("fs"));
|
|
32
|
+
const utils_1 = require("../utils");
|
|
33
|
+
function default_1(fileInfo, api) {
|
|
34
|
+
const filePath = fileInfo.path;
|
|
35
|
+
// Handle HTML files and inline templates
|
|
36
|
+
const htmlResult = (0, utils_1.htmlTransformer)(fileInfo, api, (templateContent) => (0, utils_1.attributeNameUpdate)(templateContent, 'kendo-chat', 'enableFileSelect', 'fileSelectButton'));
|
|
37
|
+
if (filePath.endsWith('.html')) {
|
|
38
|
+
if (htmlResult && htmlResult !== fileInfo.source) {
|
|
39
|
+
fs.writeFileSync(filePath, htmlResult, 'utf-8');
|
|
40
|
+
return htmlResult;
|
|
41
|
+
}
|
|
42
|
+
return fileInfo.source; // Return original source if no changes
|
|
43
|
+
}
|
|
44
|
+
// Handle TypeScript property transformations
|
|
45
|
+
const j = api.jscodeshift;
|
|
46
|
+
const rootSource = j(htmlResult || fileInfo.source);
|
|
47
|
+
(0, utils_1.tsPropertyTransformer)(fileInfo.source, rootSource, j, '@progress/kendo-angular-conversational-ui', 'ChatComponent', 'enableFileSelect', 'fileSelectButton');
|
|
48
|
+
return rootSource.toSource();
|
|
49
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
"use strict";
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
23
|
+
if (mod && mod.__esModule) return mod;
|
|
24
|
+
var result = {};
|
|
25
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
26
|
+
__setModuleDefault(result, mod);
|
|
27
|
+
return result;
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.default = default_1;
|
|
31
|
+
const fs = __importStar(require("fs"));
|
|
32
|
+
const utils_1 = require("../utils");
|
|
33
|
+
function default_1(fileInfo, api) {
|
|
34
|
+
const filePath = fileInfo.path;
|
|
35
|
+
// Handle HTML files and inline templates
|
|
36
|
+
const htmlResult = (0, utils_1.htmlTransformer)(fileInfo, api, (templateContent) => (0, utils_1.attributeNameUpdate)(templateContent, 'kendo-chat', 'enableSpeechToText', 'speechToTextButton'));
|
|
37
|
+
if (filePath.endsWith('.html')) {
|
|
38
|
+
if (htmlResult && htmlResult !== fileInfo.source) {
|
|
39
|
+
fs.writeFileSync(filePath, htmlResult, 'utf-8');
|
|
40
|
+
return htmlResult;
|
|
41
|
+
}
|
|
42
|
+
return fileInfo.source; // Return original source if no changes
|
|
43
|
+
}
|
|
44
|
+
// Handle TypeScript property transformations
|
|
45
|
+
const j = api.jscodeshift;
|
|
46
|
+
const rootSource = j(htmlResult || fileInfo.source);
|
|
47
|
+
(0, utils_1.tsPropertyTransformer)(fileInfo.source, rootSource, j, '@progress/kendo-angular-conversational-ui', 'ChatComponent', 'enableSpeechToText', 'speechToTextButton');
|
|
48
|
+
return rootSource.toSource();
|
|
49
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
"use strict";
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
23
|
+
if (mod && mod.__esModule) return mod;
|
|
24
|
+
var result = {};
|
|
25
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
26
|
+
__setModuleDefault(result, mod);
|
|
27
|
+
return result;
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.default = default_1;
|
|
31
|
+
const fs = __importStar(require("fs"));
|
|
32
|
+
const utils_1 = require("../utils");
|
|
33
|
+
function default_1(fileInfo, api) {
|
|
34
|
+
const filePath = fileInfo.path;
|
|
35
|
+
// Handle HTML files and inline templates
|
|
36
|
+
const htmlResult = (0, utils_1.htmlTransformer)(fileInfo, api, (templateContent) => (0, utils_1.attributeNameUpdate)(templateContent, 'kendo-chat-messages', 'send', 'actionButtonTitle'));
|
|
37
|
+
if (filePath.endsWith('.html')) {
|
|
38
|
+
if (htmlResult && htmlResult !== fileInfo.source) {
|
|
39
|
+
fs.writeFileSync(filePath, htmlResult, 'utf-8');
|
|
40
|
+
return htmlResult;
|
|
41
|
+
}
|
|
42
|
+
return fileInfo.source; // Return original source if no changes
|
|
43
|
+
}
|
|
44
|
+
// Handle TypeScript property transformations
|
|
45
|
+
const j = api.jscodeshift;
|
|
46
|
+
const rootSource = j(htmlResult || fileInfo.source);
|
|
47
|
+
(0, utils_1.tsPropertyTransformer)(fileInfo.source, rootSource, j, '@progress/kendo-angular-conversational-ui', 'CustomMessagesComponent', 'send', 'actionButtonTitle');
|
|
48
|
+
return rootSource.toSource();
|
|
49
|
+
}
|
|
@@ -11,7 +11,7 @@ import { isPresent, normalizeKeys, Keys, focusableSelector, guid, getter, isDocu
|
|
|
11
11
|
import { DialogContainerService, DialogService, WindowService, WindowContainerService } from '@progress/kendo-angular-dialog';
|
|
12
12
|
import { NgTemplateOutlet, NgClass } from '@angular/common';
|
|
13
13
|
import { Subject, Subscription, fromEvent } from 'rxjs';
|
|
14
|
-
import { moreHorizontalIcon, commentIcon, sparklesIcon, stopSmIcon, thumbUpIcon, thumbDownOutlineIcon, thumbDownIcon, thumbUpOutlineIcon, copyIcon, arrowRotateCwIcon, chevronUpIcon, chevronDownIcon, arrowUpOutlineIcon, undoIcon, downloadIcon, chevronLeftIcon, chevronRightIcon, xIcon, moreVerticalIcon,
|
|
14
|
+
import { moreHorizontalIcon, commentIcon, sparklesIcon, stopSmIcon, thumbUpIcon, thumbDownOutlineIcon, thumbDownIcon, thumbUpOutlineIcon, copyIcon, arrowRotateCwIcon, chevronUpIcon, chevronDownIcon, arrowUpOutlineIcon, paperclipOutlineAltRightIcon, undoIcon, downloadIcon, chevronLeftIcon, chevronRightIcon, xIcon, moreVerticalIcon, arrowRotateCwOutlineIcon, warningTriangleIcon, pinOutlineIcon, arrowDownOutlineIcon, cancelOutlineIcon, menuIcon, paperPlaneIcon } from '@progress/kendo-svg-icons';
|
|
15
15
|
import * as i1 from '@progress/kendo-angular-l10n';
|
|
16
16
|
import { ComponentMessages, LocalizationService, L10N_PREFIX } from '@progress/kendo-angular-l10n';
|
|
17
17
|
import { validatePackage } from '@progress/kendo-licensing';
|
|
@@ -216,7 +216,7 @@ const packageMetadata = {
|
|
|
216
216
|
productCode: 'KENDOUIANGULAR',
|
|
217
217
|
productCodes: ['KENDOUIANGULAR'],
|
|
218
218
|
publishDate: 0,
|
|
219
|
-
version: '23.0.0
|
|
219
|
+
version: '23.0.0',
|
|
220
220
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
|
|
221
221
|
};
|
|
222
222
|
|
|
@@ -2043,7 +2043,9 @@ const SEND_BTN_DEFAULT_SETTINGS = {
|
|
|
2043
2043
|
const FILESELECT_BUTTON_DEFAULT_SETTINGS$1 = {
|
|
2044
2044
|
multiple: true,
|
|
2045
2045
|
disabled: false,
|
|
2046
|
-
fillMode: 'clear'
|
|
2046
|
+
fillMode: 'clear',
|
|
2047
|
+
icon: 'paperclip-outline-alt-right',
|
|
2048
|
+
svgIcon: paperclipOutlineAltRightIcon,
|
|
2047
2049
|
};
|
|
2048
2050
|
/**
|
|
2049
2051
|
* @hidden
|
|
@@ -3063,6 +3065,7 @@ class ChatFileComponent extends ChatItem {
|
|
|
3063
3065
|
kendoButton
|
|
3064
3066
|
[attr.title]="textFor('removeFileTitle')"
|
|
3065
3067
|
[svgIcon]="deleteIcon"
|
|
3068
|
+
icon="x"
|
|
3066
3069
|
(click)="remove.emit(chatFile)"
|
|
3067
3070
|
fillMode="flat"
|
|
3068
3071
|
></button>
|
|
@@ -3106,6 +3109,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
3106
3109
|
kendoButton
|
|
3107
3110
|
[attr.title]="textFor('removeFileTitle')"
|
|
3108
3111
|
[svgIcon]="deleteIcon"
|
|
3112
|
+
icon="x"
|
|
3109
3113
|
(click)="remove.emit(chatFile)"
|
|
3110
3114
|
fillMode="flat"
|
|
3111
3115
|
></button>
|
|
@@ -3794,7 +3798,7 @@ class PromptBoxFileSelectButtonComponent extends PromptBoxBaseTool {
|
|
|
3794
3798
|
this.disabled = false;
|
|
3795
3799
|
this.fillMode = 'flat';
|
|
3796
3800
|
this.size = 'small';
|
|
3797
|
-
this.icon = 'paperclip';
|
|
3801
|
+
this.icon = 'paperclip-outline-alt-right';
|
|
3798
3802
|
this.svgIcon = paperclipOutlineAltRightIcon;
|
|
3799
3803
|
}
|
|
3800
3804
|
/**
|
|
@@ -3832,13 +3836,13 @@ class PromptBoxFileSelectButtonComponent extends PromptBoxBaseTool {
|
|
|
3832
3836
|
[attr.title]="title || textFor('fileSelectButtonTitle')"
|
|
3833
3837
|
[disabled]="disabled"
|
|
3834
3838
|
[fillMode]="fillMode"
|
|
3835
|
-
[icon]="icon"
|
|
3836
|
-
[iconClass]="iconClass"
|
|
3837
3839
|
[imageUrl]="imageUrl"
|
|
3838
3840
|
[rounded]="rounded"
|
|
3839
3841
|
[size]="size"
|
|
3840
|
-
[svgIcon]="svgIcon"
|
|
3841
3842
|
[themeColor]="themeColor"
|
|
3843
|
+
[icon]="iconClass ? undefined : icon"
|
|
3844
|
+
[svgIcon]="iconClass ? undefined : svgIcon"
|
|
3845
|
+
[iconClass]="iconClass"
|
|
3842
3846
|
(click)="selectFiles()"
|
|
3843
3847
|
></button>
|
|
3844
3848
|
<kendo-fileselect
|
|
@@ -3870,13 +3874,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
3870
3874
|
[attr.title]="title || textFor('fileSelectButtonTitle')"
|
|
3871
3875
|
[disabled]="disabled"
|
|
3872
3876
|
[fillMode]="fillMode"
|
|
3873
|
-
[icon]="icon"
|
|
3874
|
-
[iconClass]="iconClass"
|
|
3875
3877
|
[imageUrl]="imageUrl"
|
|
3876
3878
|
[rounded]="rounded"
|
|
3877
3879
|
[size]="size"
|
|
3878
|
-
[svgIcon]="svgIcon"
|
|
3879
3880
|
[themeColor]="themeColor"
|
|
3881
|
+
[icon]="iconClass ? undefined : icon"
|
|
3882
|
+
[svgIcon]="iconClass ? undefined : svgIcon"
|
|
3883
|
+
[iconClass]="iconClass"
|
|
3880
3884
|
(click)="selectFiles()"
|
|
3881
3885
|
></button>
|
|
3882
3886
|
<kendo-fileselect
|
|
@@ -3951,6 +3955,7 @@ class PromptBoxFileComponent {
|
|
|
3951
3955
|
kendoButton
|
|
3952
3956
|
[attr.title]="textFor('removeFileTitle')"
|
|
3953
3957
|
[svgIcon]="deleteIcon"
|
|
3958
|
+
icon="x"
|
|
3954
3959
|
[disabled]="disabled"
|
|
3955
3960
|
(click)="remove.emit(promptBoxFile)"
|
|
3956
3961
|
fillMode="flat"
|
|
@@ -3978,6 +3983,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
3978
3983
|
kendoButton
|
|
3979
3984
|
[attr.title]="textFor('removeFileTitle')"
|
|
3980
3985
|
[svgIcon]="deleteIcon"
|
|
3986
|
+
icon="x"
|
|
3981
3987
|
[disabled]="disabled"
|
|
3982
3988
|
(click)="remove.emit(promptBoxFile)"
|
|
3983
3989
|
fillMode="flat"
|
|
@@ -4534,6 +4540,7 @@ class PromptBoxComponent {
|
|
|
4534
4540
|
this.ngZone = ngZone;
|
|
4535
4541
|
this.localization = localization;
|
|
4536
4542
|
this.hostElement = hostElement;
|
|
4543
|
+
validatePackage(packageMetadata);
|
|
4537
4544
|
}
|
|
4538
4545
|
ngAfterViewInit() {
|
|
4539
4546
|
if (this.mode !== 'single' && this.textareaElement) {
|
|
@@ -5768,13 +5775,14 @@ class MessageBoxComponent {
|
|
|
5768
5775
|
kendoButton
|
|
5769
5776
|
[attr.title]="textFor('removeReplyTitle')"
|
|
5770
5777
|
[svgIcon]="deleteIcon"
|
|
5778
|
+
icon="x"
|
|
5771
5779
|
(click)="removeReply()"
|
|
5772
5780
|
fillMode="flat"
|
|
5773
5781
|
></button>
|
|
5774
5782
|
</div>
|
|
5775
5783
|
</ng-template>
|
|
5776
5784
|
}
|
|
5777
|
-
<kendo-promptbox-
|
|
5785
|
+
<kendo-promptbox-start-affix>
|
|
5778
5786
|
@if (fileSelectButton) {
|
|
5779
5787
|
<kendo-promptbox-fileselect-button
|
|
5780
5788
|
[disabled]="fileSelectButtonSettings?.disabled"
|
|
@@ -5785,9 +5793,14 @@ class MessageBoxComponent {
|
|
|
5785
5793
|
[restrictions]="fileSelectButtonSettings?.restrictions"
|
|
5786
5794
|
[multiple]="fileSelectButtonSettings?.multiple"
|
|
5787
5795
|
[accept]="fileSelectButtonSettings?.accept"
|
|
5796
|
+
[svgIcon]="fileSelectButtonSettings?.svgIcon"
|
|
5797
|
+
[icon]="fileSelectButtonSettings?.icon"
|
|
5798
|
+
[iconClass]="fileSelectButtonSettings?.iconClass"
|
|
5799
|
+
[imageUrl]="fileSelectButtonSettings?.imageUrl"
|
|
5788
5800
|
></kendo-promptbox-fileselect-button>
|
|
5789
5801
|
}
|
|
5790
|
-
|
|
5802
|
+
</kendo-promptbox-start-affix>
|
|
5803
|
+
<kendo-promptbox-end-affix>
|
|
5791
5804
|
@if (speechToTextButtonSettings) {
|
|
5792
5805
|
<kendo-promptbox-speech-to-text-button
|
|
5793
5806
|
[continuous]="speechToTextButtonSettings?.continuous"
|
|
@@ -5820,7 +5833,7 @@ class MessageBoxComponent {
|
|
|
5820
5833
|
} @if (messageBoxTemplate?.templateRef) {
|
|
5821
5834
|
<ng-template [ngTemplateOutlet]="messageBoxTemplate?.templateRef"></ng-template>
|
|
5822
5835
|
}
|
|
5823
|
-
`, isInline: true, dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[kendoButton]", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: PromptBoxComponent, selector: "kendo-promptbox", inputs: ["disabled", "focusableId", "loading", "placeholder", "readonly", "title", "mode", "rows", "maxTextAreaHeight", "value", "actionButton", "fileSelectButton", "speechToTextButton"], outputs: ["valueChange", "focus", "blur", "inputFocus", "inputBlur", "promptAction", "selectAttachments", "fileRemove", "speechToTextClick", "speechToTextStart", "speechToTextEnd", "speechToTextError", "speechToTextResult"], exportAs: ["kendoPromptBox"] }, { kind: "component", type: PromptBoxCustomMessagesComponent, selector: "kendo-promptbox-messages" }, { kind: "directive", type: PromptBoxHeaderTemplateDirective, selector: "[kendoPromptBoxHeaderTemplate]" }, { kind: "component", type: PromptBoxEndAffixComponent, selector: "kendo-promptbox-end-affix", exportAs: ["kendoPromptBoxEndAffix"] }, { kind: "component", type: PromptBoxActionButtonComponent, selector: "kendo-promptbox-action-button", inputs: ["buttonClass", "loading", "loadingIcon", "loadingSVGIcon"], outputs: ["promptAction"], exportAs: ["kendoPromptBoxActionButton"] }, { kind: "component", type: PromptBoxFileSelectButtonComponent, selector: "kendo-promptbox-fileselect-button", inputs: ["restrictions", "multiple", "accept"], outputs: ["selectAttachments"], exportAs: ["kendoPromptBoxFileSelectButton"] }, { kind: "component", type: PromptBoxSpeechToTextButtonComponent, selector: "kendo-promptbox-speech-to-text-button", inputs: ["continuous", "integrationMode", "interimResults", "lang", "maxAlternatives"], outputs: ["stbClick", "stbStart", "stbEnd", "stbError", "stbResult"], exportAs: ["kendoPromptBoxSpeechToTextButton"] }, { kind: "component", type: MessageReferenceComponent, selector: "chat-message-reference-content", inputs: ["message"] }, { kind: "component", type: SuggestedActionsComponent, selector: "kendo-chat-suggested-actions", inputs: ["actions", "suggestions", "tabbable", "type", "suggestionTemplate"], outputs: ["dispatchAction", "dispatchSuggestion"] }] });
|
|
5836
|
+
`, isInline: true, dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[kendoButton]", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: PromptBoxComponent, selector: "kendo-promptbox", inputs: ["disabled", "focusableId", "loading", "placeholder", "readonly", "title", "mode", "rows", "maxTextAreaHeight", "value", "actionButton", "fileSelectButton", "speechToTextButton"], outputs: ["valueChange", "focus", "blur", "inputFocus", "inputBlur", "promptAction", "selectAttachments", "fileRemove", "speechToTextClick", "speechToTextStart", "speechToTextEnd", "speechToTextError", "speechToTextResult"], exportAs: ["kendoPromptBox"] }, { kind: "component", type: PromptBoxCustomMessagesComponent, selector: "kendo-promptbox-messages" }, { kind: "directive", type: PromptBoxHeaderTemplateDirective, selector: "[kendoPromptBoxHeaderTemplate]" }, { kind: "component", type: PromptBoxStartAffixComponent, selector: "kendo-promptbox-start-affix", exportAs: ["kendoPromptBoxStartAffix"] }, { kind: "component", type: PromptBoxEndAffixComponent, selector: "kendo-promptbox-end-affix", exportAs: ["kendoPromptBoxEndAffix"] }, { kind: "component", type: PromptBoxActionButtonComponent, selector: "kendo-promptbox-action-button", inputs: ["buttonClass", "loading", "loadingIcon", "loadingSVGIcon"], outputs: ["promptAction"], exportAs: ["kendoPromptBoxActionButton"] }, { kind: "component", type: PromptBoxFileSelectButtonComponent, selector: "kendo-promptbox-fileselect-button", inputs: ["restrictions", "multiple", "accept"], outputs: ["selectAttachments"], exportAs: ["kendoPromptBoxFileSelectButton"] }, { kind: "component", type: PromptBoxSpeechToTextButtonComponent, selector: "kendo-promptbox-speech-to-text-button", inputs: ["continuous", "integrationMode", "interimResults", "lang", "maxAlternatives"], outputs: ["stbClick", "stbStart", "stbEnd", "stbError", "stbResult"], exportAs: ["kendoPromptBoxSpeechToTextButton"] }, { kind: "component", type: MessageReferenceComponent, selector: "chat-message-reference-content", inputs: ["message"] }, { kind: "component", type: SuggestedActionsComponent, selector: "kendo-chat-suggested-actions", inputs: ["actions", "suggestions", "tabbable", "type", "suggestionTemplate"], outputs: ["dispatchAction", "dispatchSuggestion"] }] });
|
|
5824
5837
|
}
|
|
5825
5838
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImport: i0, type: MessageBoxComponent, decorators: [{
|
|
5826
5839
|
type: Component,
|
|
@@ -5873,13 +5886,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
5873
5886
|
kendoButton
|
|
5874
5887
|
[attr.title]="textFor('removeReplyTitle')"
|
|
5875
5888
|
[svgIcon]="deleteIcon"
|
|
5889
|
+
icon="x"
|
|
5876
5890
|
(click)="removeReply()"
|
|
5877
5891
|
fillMode="flat"
|
|
5878
5892
|
></button>
|
|
5879
5893
|
</div>
|
|
5880
5894
|
</ng-template>
|
|
5881
5895
|
}
|
|
5882
|
-
<kendo-promptbox-
|
|
5896
|
+
<kendo-promptbox-start-affix>
|
|
5883
5897
|
@if (fileSelectButton) {
|
|
5884
5898
|
<kendo-promptbox-fileselect-button
|
|
5885
5899
|
[disabled]="fileSelectButtonSettings?.disabled"
|
|
@@ -5890,9 +5904,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
5890
5904
|
[restrictions]="fileSelectButtonSettings?.restrictions"
|
|
5891
5905
|
[multiple]="fileSelectButtonSettings?.multiple"
|
|
5892
5906
|
[accept]="fileSelectButtonSettings?.accept"
|
|
5907
|
+
[svgIcon]="fileSelectButtonSettings?.svgIcon"
|
|
5908
|
+
[icon]="fileSelectButtonSettings?.icon"
|
|
5909
|
+
[iconClass]="fileSelectButtonSettings?.iconClass"
|
|
5910
|
+
[imageUrl]="fileSelectButtonSettings?.imageUrl"
|
|
5893
5911
|
></kendo-promptbox-fileselect-button>
|
|
5894
5912
|
}
|
|
5895
|
-
|
|
5913
|
+
</kendo-promptbox-start-affix>
|
|
5914
|
+
<kendo-promptbox-end-affix>
|
|
5896
5915
|
@if (speechToTextButtonSettings) {
|
|
5897
5916
|
<kendo-promptbox-speech-to-text-button
|
|
5898
5917
|
[continuous]="speechToTextButtonSettings?.continuous"
|
|
@@ -5933,6 +5952,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
5933
5952
|
PromptBoxComponent,
|
|
5934
5953
|
PromptBoxCustomMessagesComponent,
|
|
5935
5954
|
PromptBoxHeaderTemplateDirective,
|
|
5955
|
+
PromptBoxStartAffixComponent,
|
|
5936
5956
|
PromptBoxEndAffixComponent,
|
|
5937
5957
|
PromptBoxActionButtonComponent,
|
|
5938
5958
|
PromptBoxFileSelectButtonComponent,
|
|
@@ -6591,7 +6611,7 @@ class MessageComponent extends ChatItem {
|
|
|
6591
6611
|
</div>
|
|
6592
6612
|
</div>
|
|
6593
6613
|
} @if (!message.typing) { @if (useCustomContentTemplate) { @if (message.failed) {
|
|
6594
|
-
<button kendoButton class="k-resend-button" size="small" fillMode="clear" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6614
|
+
<button kendoButton class="k-resend-button" size="small" fillMode="clear" icon="arrow-rotate-cw-outline" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6595
6615
|
}
|
|
6596
6616
|
<div
|
|
6597
6617
|
class="k-chat-bubble k-bubble"
|
|
@@ -6627,7 +6647,7 @@ class MessageComponent extends ChatItem {
|
|
|
6627
6647
|
}
|
|
6628
6648
|
</div>
|
|
6629
6649
|
} @if (!useCustomContentTemplate && hasMessageContent) { @if (message.failed) {
|
|
6630
|
-
<button kendoButton class="k-resend-button" size="small" fillMode="clear" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6650
|
+
<button kendoButton class="k-resend-button" size="small" fillMode="clear" icon="arrow-rotate-cw-outline" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6631
6651
|
}
|
|
6632
6652
|
<div
|
|
6633
6653
|
class="k-chat-bubble k-bubble"
|
|
@@ -6808,7 +6828,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
6808
6828
|
</div>
|
|
6809
6829
|
</div>
|
|
6810
6830
|
} @if (!message.typing) { @if (useCustomContentTemplate) { @if (message.failed) {
|
|
6811
|
-
<button kendoButton class="k-resend-button" size="small" fillMode="clear" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6831
|
+
<button kendoButton class="k-resend-button" size="small" fillMode="clear" icon="arrow-rotate-cw-outline" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6812
6832
|
}
|
|
6813
6833
|
<div
|
|
6814
6834
|
class="k-chat-bubble k-bubble"
|
|
@@ -6844,7 +6864,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
6844
6864
|
}
|
|
6845
6865
|
</div>
|
|
6846
6866
|
} @if (!useCustomContentTemplate && hasMessageContent) { @if (message.failed) {
|
|
6847
|
-
<button kendoButton class="k-resend-button" size="small" fillMode="clear" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6867
|
+
<button kendoButton class="k-resend-button" size="small" fillMode="clear" icon="arrow-rotate-cw-outline" [svgIcon]="resendIcon" (click)="onResendMessage($event)"></button>
|
|
6848
6868
|
}
|
|
6849
6869
|
<div
|
|
6850
6870
|
class="k-chat-bubble k-bubble"
|
|
@@ -9031,7 +9051,7 @@ class ChatComponent {
|
|
|
9031
9051
|
<kendo-icon-wrapper name="pin" [svgIcon]="pinIcon"> </kendo-icon-wrapper>
|
|
9032
9052
|
<chat-message-reference-content [message]="pinnedMessage"></chat-message-reference-content>
|
|
9033
9053
|
<span class="k-spacer"></span>
|
|
9034
|
-
<button kendoButton [svgIcon]="deleteIcon" [attr.title]="textFor('unpinMessageTitle')" (click)="unpin.emit(pinnedMessage)" fillMode="flat"></button>
|
|
9054
|
+
<button kendoButton icon="x" [svgIcon]="deleteIcon" [attr.title]="textFor('unpinMessageTitle')" (click)="unpin.emit(pinnedMessage)" fillMode="flat"></button>
|
|
9035
9055
|
</div>
|
|
9036
9056
|
} @if (processedMessages && processedMessages.length === 0) {
|
|
9037
9057
|
<div class="k-message-list-content k-message-list-content-empty">
|
|
@@ -9064,6 +9084,7 @@ class ChatComponent {
|
|
|
9064
9084
|
[size]="'small'"
|
|
9065
9085
|
[themeColor]="'light'"
|
|
9066
9086
|
[align]="{ horizontal: 'center' }"
|
|
9087
|
+
icon="arrow-down-outline"
|
|
9067
9088
|
[svgIcon]="scrollToBottomIcon"
|
|
9068
9089
|
(click)="anchor.scrollToBottom()"
|
|
9069
9090
|
></kendo-floatingactionbutton>
|
|
@@ -9216,7 +9237,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
9216
9237
|
<kendo-icon-wrapper name="pin" [svgIcon]="pinIcon"> </kendo-icon-wrapper>
|
|
9217
9238
|
<chat-message-reference-content [message]="pinnedMessage"></chat-message-reference-content>
|
|
9218
9239
|
<span class="k-spacer"></span>
|
|
9219
|
-
<button kendoButton [svgIcon]="deleteIcon" [attr.title]="textFor('unpinMessageTitle')" (click)="unpin.emit(pinnedMessage)" fillMode="flat"></button>
|
|
9240
|
+
<button kendoButton icon="x" [svgIcon]="deleteIcon" [attr.title]="textFor('unpinMessageTitle')" (click)="unpin.emit(pinnedMessage)" fillMode="flat"></button>
|
|
9220
9241
|
</div>
|
|
9221
9242
|
} @if (processedMessages && processedMessages.length === 0) {
|
|
9222
9243
|
<div class="k-message-list-content k-message-list-content-empty">
|
|
@@ -9249,6 +9270,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
|
|
|
9249
9270
|
[size]="'small'"
|
|
9250
9271
|
[themeColor]="'light'"
|
|
9251
9272
|
[align]="{ horizontal: 'center' }"
|
|
9273
|
+
icon="arrow-down-outline"
|
|
9252
9274
|
[svgIcon]="scrollToBottomIcon"
|
|
9253
9275
|
(click)="anchor.scrollToBottom()"
|
|
9254
9276
|
></kendo-floatingactionbutton>
|
package/package-metadata.mjs
CHANGED
|
@@ -7,7 +7,7 @@ export const packageMetadata = {
|
|
|
7
7
|
"productCodes": [
|
|
8
8
|
"KENDOUIANGULAR"
|
|
9
9
|
],
|
|
10
|
-
"publishDate":
|
|
11
|
-
"version": "23.0.0
|
|
10
|
+
"publishDate": 1770742180,
|
|
11
|
+
"version": "23.0.0",
|
|
12
12
|
"licensingDocsUrl": "https://www.telerik.com/kendo-angular-ui/my-license/"
|
|
13
13
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-angular-conversational-ui",
|
|
3
|
-
"version": "23.0.0
|
|
3
|
+
"version": "23.0.0",
|
|
4
4
|
"description": "Kendo UI for Angular Conversational UI components",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "Progress",
|
|
@@ -41,13 +41,35 @@
|
|
|
41
41
|
"file": "codemods/v21/chat-pinnedbyfield.js",
|
|
42
42
|
"prompt": "true"
|
|
43
43
|
}
|
|
44
|
+
],
|
|
45
|
+
"23": [
|
|
46
|
+
{
|
|
47
|
+
"description": "The Chat's enableSpeechToText input property is renamed to speechToTextButton.",
|
|
48
|
+
"file": "codemods/v23/chat-enableSpeechToText.js",
|
|
49
|
+
"prompt": "true"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"description": "The Chat's enableFileSelect input property is renamed to fileSelectButton.",
|
|
53
|
+
"file": "codemods/v23/chat-enableFileSelect.js",
|
|
54
|
+
"prompt": "true"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"description": "The Chat's FileSelectSettings is changed to FileSelectButtonSettings.",
|
|
58
|
+
"file": "codemods/v23/chat-FileSelectSettings.js",
|
|
59
|
+
"prompt": "true"
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"description": "The CustomMessagesComponent's send property is renamed to actionButtonTitle.",
|
|
63
|
+
"file": "codemods/v23/customMessages-send.js",
|
|
64
|
+
"prompt": "true"
|
|
65
|
+
}
|
|
44
66
|
]
|
|
45
67
|
}
|
|
46
68
|
},
|
|
47
69
|
"package": {
|
|
48
70
|
"productName": "Kendo UI for Angular",
|
|
49
71
|
"productCode": "KENDOUIANGULAR",
|
|
50
|
-
"publishDate":
|
|
72
|
+
"publishDate": 1770742180,
|
|
51
73
|
"licensingDocsUrl": "https://www.telerik.com/kendo-angular-ui/my-license/"
|
|
52
74
|
}
|
|
53
75
|
},
|
|
@@ -57,22 +79,22 @@
|
|
|
57
79
|
"@angular/core": "19 - 21",
|
|
58
80
|
"@angular/platform-browser": "19 - 21",
|
|
59
81
|
"@progress/kendo-licensing": "^1.10.0",
|
|
60
|
-
"@progress/kendo-angular-buttons": "23.0.0
|
|
61
|
-
"@progress/kendo-angular-inputs": "23.0.0
|
|
62
|
-
"@progress/kendo-angular-layout": "23.0.0
|
|
63
|
-
"@progress/kendo-angular-icons": "23.0.0
|
|
64
|
-
"@progress/kendo-angular-common": "23.0.0
|
|
65
|
-
"@progress/kendo-angular-intl": "23.0.0
|
|
66
|
-
"@progress/kendo-angular-l10n": "23.0.0
|
|
67
|
-
"@progress/kendo-angular-menu": "23.0.0
|
|
68
|
-
"@progress/kendo-angular-popup": "23.0.0
|
|
69
|
-
"@progress/kendo-angular-toolbar": "23.0.0
|
|
70
|
-
"@progress/kendo-angular-upload": "23.0.0
|
|
82
|
+
"@progress/kendo-angular-buttons": "23.0.0",
|
|
83
|
+
"@progress/kendo-angular-inputs": "23.0.0",
|
|
84
|
+
"@progress/kendo-angular-layout": "23.0.0",
|
|
85
|
+
"@progress/kendo-angular-icons": "23.0.0",
|
|
86
|
+
"@progress/kendo-angular-common": "23.0.0",
|
|
87
|
+
"@progress/kendo-angular-intl": "23.0.0",
|
|
88
|
+
"@progress/kendo-angular-l10n": "23.0.0",
|
|
89
|
+
"@progress/kendo-angular-menu": "23.0.0",
|
|
90
|
+
"@progress/kendo-angular-popup": "23.0.0",
|
|
91
|
+
"@progress/kendo-angular-toolbar": "23.0.0",
|
|
92
|
+
"@progress/kendo-angular-upload": "23.0.0",
|
|
71
93
|
"rxjs": "^6.5.3 || ^7.0.0"
|
|
72
94
|
},
|
|
73
95
|
"dependencies": {
|
|
74
96
|
"tslib": "^2.3.1",
|
|
75
|
-
"@progress/kendo-angular-schematics": "23.0.0
|
|
97
|
+
"@progress/kendo-angular-schematics": "23.0.0"
|
|
76
98
|
},
|
|
77
99
|
"schematics": "./schematics/collection.json",
|
|
78
100
|
"module": "fesm2022/progress-kendo-angular-conversational-ui.mjs",
|