[9.0] [SB] Fix graph layout stories (#217766) (#218476)

# Backport

This will backport the following commits from `main` to `9.0`:
- [[SB] Fix graph layout stories
(#217766)](https://github.com/elastic/kibana/pull/217766)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Brad
White","email":"Ikuni17@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-04-16T16:59:08Z","message":"[SB]
Fix graph layout stories (#217766)\n\n## Summary\n\nThis fixes the graph
layout stories not rendering properly after\n#214684. Open to a better
or preferred fix as I'm not familiar with\nthese components.\n\nThere
was a console warning:\n```js\n[React Flow]: The React Flow parent
container needs a width and a height to render the graph. Help:
https://reactflow.dev/error#004\n```\n\n[Storybook
preview\nlink](https://ci-artifacts.kibana.dev/storybooks/pr-217766/cloud_security_posture_graph/index.html?path=/story/components-graph-components-graph-layout--simple-api-mock)\n\n---------\n\nCo-authored-by:
Kfir Peled
<61654899+kfirpeled@users.noreply.github.com>","sha":"a7796cd0d00453f67d0f5c4366352c53d6c63131","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","ci:build-storybooks","backport:version","v9.1.0","v8.19.0"],"title":"[SB]
Fix graph layout
stories","number":217766,"url":"https://github.com/elastic/kibana/pull/217766","mergeCommit":{"message":"[SB]
Fix graph layout stories (#217766)\n\n## Summary\n\nThis fixes the graph
layout stories not rendering properly after\n#214684. Open to a better
or preferred fix as I'm not familiar with\nthese components.\n\nThere
was a console warning:\n```js\n[React Flow]: The React Flow parent
container needs a width and a height to render the graph. Help:
https://reactflow.dev/error#004\n```\n\n[Storybook
preview\nlink](https://ci-artifacts.kibana.dev/storybooks/pr-217766/cloud_security_posture_graph/index.html?path=/story/components-graph-components-graph-layout--simple-api-mock)\n\n---------\n\nCo-authored-by:
Kfir Peled
<61654899+kfirpeled@users.noreply.github.com>","sha":"a7796cd0d00453f67d0f5c4366352c53d6c63131"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/217766","number":217766,"mergeCommit":{"message":"[SB]
Fix graph layout stories (#217766)\n\n## Summary\n\nThis fixes the graph
layout stories not rendering properly after\n#214684. Open to a better
or preferred fix as I'm not familiar with\nthese components.\n\nThere
was a console warning:\n```js\n[React Flow]: The React Flow parent
container needs a width and a height to render the graph. Help:
https://reactflow.dev/error#004\n```\n\n[Storybook
preview\nlink](https://ci-artifacts.kibana.dev/storybooks/pr-217766/cloud_security_posture_graph/index.html?path=/story/components-graph-components-graph-layout--simple-api-mock)\n\n---------\n\nCo-authored-by:
Kfir Peled
<61654899+kfirpeled@users.noreply.github.com>","sha":"a7796cd0d00453f67d0f5c4366352c53d6c63131"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Brad White <Ikuni17@users.noreply.github.com>
This commit is contained in:
Kibana Machine 2025-04-18 21:24:41 +02:00 committed by GitHub
parent 02dc9ab14e
commit f9f11a5e4b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -10,7 +10,7 @@ import { Global, css } from '@emotion/react';
const globalStyles = css`
html,
body,
#root {
#storybook-root {
width: 100%;
height: 100%;
margin: 0;