Skip to content

Commit

Permalink
[UXE-4724] fix: capture groups input gaps (#2047)
Browse files Browse the repository at this point in the history
  • Loading branch information
lfsigreja authored Jan 8, 2025
1 parent 860c308 commit 2ddf869
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const adapt = (payload) => {
cross_site_scripting: payload.crossSiteScripting,
directory_traversal: payload.directoryTraversal,
remote_file_inclusion: payload.remoteFileInclusion,
sql_injection: payload.sqlInjection,
sql_injection: payload.sqlInjection
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ const parseHttpResponse = (httpResponse) => {
default:
throw new Error(extractApiError(httpResponse)).message
}
}
}
1 change: 1 addition & 0 deletions src/templates/form-fields-inputs/fieldText.vue
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@

<template>
<LabelBlock
v-if="props.label"
:for="props.name"
:data-testid="customTestId.label"
:label="props.label"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ describe('WafRulesServices', () => {
cross_site_scripting: fixtures.wafRulesMock.crossSiteScripting,
directory_traversal: fixtures.wafRulesMock.directoryTraversal,
remote_file_inclusion: fixtures.wafRulesMock.remoteFileInclusion,
sql_injection: fixtures.wafRulesMock.sqlInjection,
sql_injection: fixtures.wafRulesMock.sqlInjection
},
id: fixtures.wafRulesMock.id,
name: fixtures.wafRulesMock.name,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -878,26 +878,23 @@
</FieldDropdown>
</template>
<template v-else-if="behaviorItem.value.name === 'capture_match_groups'">
<div class="flex flex-col w-full">
<div class="flex gap-3 flex-col w-full">
<FieldText
class="w-full mb-3"
:name="`behaviors[${behaviorIndex}].captured_array`"
:key="behaviorItem.key"
placeholder="captured array name"
placeholder="Captured array name"
:value="behaviors[behaviorIndex].value.captured_array"
:data-testid="`edge-application-rule-form__behaviors-item-capture-match-groups-captured-array[${behaviorIndex}]`"
/>
<FieldText
placeholder="Subject"
class="w-full mb-3"
:name="`behaviors[${behaviorIndex}].subject`"
:key="behaviorItem.key"
:value="behaviors[behaviorIndex].value.subject"
:data-testid="`edge-application-rule-form__behaviors-item-capture-match-groups-subject[${behaviorIndex}]`"
/>
<FieldText
placeholder="Regex"
class="w-full"
:name="`behaviors[${behaviorIndex}].regex`"
:key="behaviorItem.key"
:value="behaviors[behaviorIndex].value.regex"
Expand Down

0 comments on commit 2ddf869

Please sign in to comment.