Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.x] [Security Solution] ThreeWayDiff UI: Add remaining field compon…
…ents for `FieldReadOnly` (#193261) (#193825) # Backport This will backport the following commits from `main` to `8.x`: - [[Security Solution] ThreeWayDiff UI: Add remaining field components for `FieldReadOnly` (#193261)](#193261) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Nikita Indik","email":"nikita.indik@elastic.co"},"sourceCommit":{"committedDate":"2024-09-24T08:04:38Z","message":"[Security Solution] ThreeWayDiff UI: Add remaining field components for `FieldReadOnly` (#193261)\n\n**Partially addresses: https://github.com/elastic/kibana/issues/171520**\r\n**Is a follow-up PR to: https://github.com/elastic/kibana/pull/192342**\r\n\r\nThis is the 3rd of the 3 PRs for `FieldReadOnly`.\r\n- The 1st [PR](#191499) added the\r\n`FieldReadOnly` and a bunch of field components.\r\n- The 2nd [PR](#192342) moved away\r\nfrom using `DiffableAllFields` type in favour of `DiffableRule` and\r\nsplit the large `FieldReadOnly` component into smaller ones for\r\nreadability.\r\n - This (3rd) PR adds the remaining field components.\r\n\r\n## Summary\r\n\r\nThis PR adds field components for `FieldReadOnly`. Field components\r\ndisplay a read-only view of a particular `DiffableRule` field, similar\r\nto how fields are shown on the Rule Details page.\r\n\r\n`FieldReadOnly` and field components will be displayed in the right side\r\nof the new Diff tab of the Upgrade flyout (see it on the [Miro\r\nboard](https://miro.com/app/board/uXjVK0gqjjQ=/?moveToWidget=3458764594148126123&cot=14)).\r\nThey will let the user see how an upgraded version of a rule will look\r\nlike in a user-friendly way.\r\n\r\n\r\n### Running\r\n`FinalReadOnly` and its field components are not yet integrated into the\r\nflyout, but you can view components in Storybook.\r\n1. Run Storybook: `yarn storybook security_solution`\r\n2. Go to `http://localhost:9001` in browser.\r\n\r\n<img width=\"1062\" alt=\"Schermafbeelding 2024-09-03 om 13 05 11\"\r\nsrc=\"https://github.com/user-attachments/assets/13b227d4-1321-47d9-a0a7-93868c9f4a15\">\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\r\nCo-authored-by: Maxim Palenov <maxim.palenov@elastic.co>","sha":"b78b6337970b2e7332266cd0e181e14d26c3ed45","branchLabelMapping":{"^v9.0.0$":"main","^v8.16.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","Team:Detections and Resp","Team: SecuritySolution","Team:Detection Rule Management","Feature:Prebuilt Detection Rules","backport:prev-minor"],"title":"[Security Solution] ThreeWayDiff UI: Add remaining field components for `FieldReadOnly`","number":193261,"url":"https://github.com/elastic/kibana/pull/193261","mergeCommit":{"message":"[Security Solution] ThreeWayDiff UI: Add remaining field components for `FieldReadOnly` (#193261)\n\n**Partially addresses: https://github.com/elastic/kibana/issues/171520**\r\n**Is a follow-up PR to: https://github.com/elastic/kibana/pull/192342**\r\n\r\nThis is the 3rd of the 3 PRs for `FieldReadOnly`.\r\n- The 1st [PR](#191499) added the\r\n`FieldReadOnly` and a bunch of field components.\r\n- The 2nd [PR](#192342) moved away\r\nfrom using `DiffableAllFields` type in favour of `DiffableRule` and\r\nsplit the large `FieldReadOnly` component into smaller ones for\r\nreadability.\r\n - This (3rd) PR adds the remaining field components.\r\n\r\n## Summary\r\n\r\nThis PR adds field components for `FieldReadOnly`. Field components\r\ndisplay a read-only view of a particular `DiffableRule` field, similar\r\nto how fields are shown on the Rule Details page.\r\n\r\n`FieldReadOnly` and field components will be displayed in the right side\r\nof the new Diff tab of the Upgrade flyout (see it on the [Miro\r\nboard](https://miro.com/app/board/uXjVK0gqjjQ=/?moveToWidget=3458764594148126123&cot=14)).\r\nThey will let the user see how an upgraded version of a rule will look\r\nlike in a user-friendly way.\r\n\r\n\r\n### Running\r\n`FinalReadOnly` and its field components are not yet integrated into the\r\nflyout, but you can view components in Storybook.\r\n1. Run Storybook: `yarn storybook security_solution`\r\n2. Go to `http://localhost:9001` in browser.\r\n\r\n<img width=\"1062\" alt=\"Schermafbeelding 2024-09-03 om 13 05 11\"\r\nsrc=\"https://github.com/user-attachments/assets/13b227d4-1321-47d9-a0a7-93868c9f4a15\">\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\r\nCo-authored-by: Maxim Palenov <maxim.palenov@elastic.co>","sha":"b78b6337970b2e7332266cd0e181e14d26c3ed45"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/193261","number":193261,"mergeCommit":{"message":"[Security Solution] ThreeWayDiff UI: Add remaining field components for `FieldReadOnly` (#193261)\n\n**Partially addresses: https://github.com/elastic/kibana/issues/171520**\r\n**Is a follow-up PR to: https://github.com/elastic/kibana/pull/192342**\r\n\r\nThis is the 3rd of the 3 PRs for `FieldReadOnly`.\r\n- The 1st [PR](#191499) added the\r\n`FieldReadOnly` and a bunch of field components.\r\n- The 2nd [PR](#192342) moved away\r\nfrom using `DiffableAllFields` type in favour of `DiffableRule` and\r\nsplit the large `FieldReadOnly` component into smaller ones for\r\nreadability.\r\n - This (3rd) PR adds the remaining field components.\r\n\r\n## Summary\r\n\r\nThis PR adds field components for `FieldReadOnly`. Field components\r\ndisplay a read-only view of a particular `DiffableRule` field, similar\r\nto how fields are shown on the Rule Details page.\r\n\r\n`FieldReadOnly` and field components will be displayed in the right side\r\nof the new Diff tab of the Upgrade flyout (see it on the [Miro\r\nboard](https://miro.com/app/board/uXjVK0gqjjQ=/?moveToWidget=3458764594148126123&cot=14)).\r\nThey will let the user see how an upgraded version of a rule will look\r\nlike in a user-friendly way.\r\n\r\n\r\n### Running\r\n`FinalReadOnly` and its field components are not yet integrated into the\r\nflyout, but you can view components in Storybook.\r\n1. Run Storybook: `yarn storybook security_solution`\r\n2. Go to `http://localhost:9001` in browser.\r\n\r\n<img width=\"1062\" alt=\"Schermafbeelding 2024-09-03 om 13 05 11\"\r\nsrc=\"https://github.com/user-attachments/assets/13b227d4-1321-47d9-a0a7-93868c9f4a15\">\r\n\r\n---------\r\n\r\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\r\nCo-authored-by: Maxim Palenov <maxim.palenov@elastic.co>","sha":"b78b6337970b2e7332266cd0e181e14d26c3ed45"}}]}] BACKPORT--> Co-authored-by: Nikita Indik <nikita.indik@elastic.co>
- Loading branch information