Skip to content

[Cases] IBM Resilient form improvements#238869

Merged
janmonschke merged 73 commits intoelastic:mainfrom
janmonschke:cases/ibm-form-improvements
Dec 3, 2025
Merged

[Cases] IBM Resilient form improvements#238869
janmonschke merged 73 commits intoelastic:mainfrom
janmonschke:cases/ibm-form-improvements

Conversation

@janmonschke
Copy link
Contributor

@janmonschke janmonschke commented Oct 14, 2025

Summary

Fixes: #240446

This PR provides an improved experience of editing IBM resilient fields.

Instead of editing IBM resilient fields with a JSON editor, this PR adds dynamic form elements for the IBM resilient fields.

Demo

Screen.Recording.2025-11-18.at.13.36.36.mov

Other changes

  • Removed useGetIncidentTypes and useGetSeverity since they can both be obtained via useGetFields. This also removes the API calls from 3 to just a single one.
  • The connector preview is now a proper table and all connector previews have been changed.

Testing

  • Add an IBM Resilient connector (hmu in Slack for credentials)
  • Create case, add additional fields to the connector, hit save
  • Observe that the fields and their values are shown in the case page
  • Edit the additional fields to your liking (adding, removing, editing) and make sure the changes are saved when pushing to IBM Resilient
@elastic elastic deleted a comment from elasticmachine Oct 22, 2025
Copy link
Contributor

@PhilippeOberti PhilippeOberti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review only (only Cypress files modified). LGTM for the @elastic/security-threat-hunting-investigations team!

@janmonschke janmonschke added the ci:cloud-deploy Create or update a Cloud deployment label Nov 19, 2025
Copy link
Contributor

@christineweng christineweng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Desk tested and LGTM, left some nit comments.

The json editor is also used in Edit connector -> Test, I wonder if it should be replaced by the new fields as well

image
signal?: AbortSignal;
}

export async function getIncidentTypes({ http, connectorId, signal }: Props) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did a lookup on getIncidentTypes and found that under stack_connectors there is another api for this (and severity as well), do you know why there were 2?

x-pack/platform/plugins/shared/stack_connectors/public/connector_types/resilient/api.ts

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, they're separate forms in separate plugins, see: #238869

@janmonschke
Copy link
Contributor Author

The json editor is also used in Edit connector -> Test, I wonder if it should be replaced by the new fields as well

@christineweng That form is not owned by us and there's no easy way to share the form since these are different plugins. From what I understand, the Response Ops team is working on improving the connector forms as well so I did not want to interfere.

Copy link
Contributor

@banderror banderror left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving changes to x-pack/solutions/security/test/security_solution_cypress/cypress/objects/case.ts

@janmonschke janmonschke added the ci:cloud-persist-deployment Persist cloud deployment indefinitely label Nov 25, 2025
@elastic-vault-github-plugin-prod elastic-vault-github-plugin-prod bot requested a review from a team as a code owner November 25, 2025 06:54
@jbudz jbudz removed the request for review from a team November 25, 2025 20:53
@janmonschke janmonschke enabled auto-merge (squash) December 3, 2025 11:30
@elasticmachine
Copy link
Contributor

elasticmachine commented Dec 3, 2025

💛 Build succeeded, but was flaky

Failed CI Steps

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
cases 1196 1198 +2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
cases 1.4MB 1.4MB +15.4KB

Count of Enzyme imports

Enzyme is no longer supported, and we should switch to @testing-library/react instead.

id before after diff
cases 36 35 -1
Unknown metric groups

ESLint disabled line counts

id before after diff
cases 70 74 +4

References to deprecated APIs

id before after diff
cases 81 79 -2

Total ESLint disabled count

id before after diff
cases 87 91 +4

History

cc @janmonschke

@janmonschke janmonschke merged commit 9785c55 into elastic:main Dec 3, 2025
12 checks passed
JordanSh pushed a commit to JordanSh/kibana that referenced this pull request Dec 9, 2025
## Summary

Fixes:  elastic#240446

This PR provides an improved experience of editing IBM resilient fields.

Instead of editing IBM resilient fields with a JSON editor, this PR adds
dynamic form elements for the IBM resilient fields.

### Demo


https://github.com/user-attachments/assets/aedd61e4-9566-4196-b24e-52d4cd85e925

### Other changes

- Removed `useGetIncidentTypes` and `useGetSeverity` since they can both
be obtained via `useGetFields`. This also removes the API calls from 3
to just a single one.
- The connector preview is now a proper table and all connector previews
have been changed.

### Testing

- Add an IBM Resilient connector (hmu in Slack for credentials)
- Create case, add additional fields to the connector, hit save
- Observe that the fields and their values are shown in the case page
- Edit the additional fields to your liking (adding, removing, editing)
and make sure the changes are saved when pushing to IBM Resilient

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting ci:cloud-deploy Create or update a Cloud deployment ci:cloud-persist-deployment Persist cloud deployment indefinitely release_note:enhancement Team:Cases Security Solution Cases team v9.3.0

6 participants