= ({
}
};
+ // show this when wildcard filename with matches operator
+ const getWildcardWarning = (precedingWarning: string): React.ReactNode => {
+ return (
+
+ {precedingWarning}{' '}
+
+ }
+ size="m"
+ />
+
+ );
+ };
+
const getFieldValueComboBox = (type: OperatorTypeEnum, isFirst: boolean): JSX.Element => {
switch (type) {
case OperatorTypeEnum.MATCH:
@@ -319,6 +343,9 @@ export const BuilderEntryItem: React.FC = ({
[os] = osTypes as OperatingSystem[];
}
const warning = validateFilePathInput({ os, value: wildcardValue });
+ const actualWarning =
+ warning === FILENAME_WILDCARD_WARNING ? getWildcardWarning(warning) : warning;
+
return (
= ({
onError={handleError}
onChange={handleFieldWildcardValueChange}
onWarning={handleWarning}
- warning={warning}
+ warning={actualWarning}
placeholder={i18n.EXCEPTION_FIELD_VALUE_PLACEHOLDER}
rowLabel={isFirst ? i18n.VALUE : undefined}
selectedField={entry.correspondingKeywordField ?? entry.field}