Skip to content

Commit

Permalink
[Interactive Graph Editor - Stories] Fix broken default and controlle…
Browse files Browse the repository at this point in the history
…d stories (#1463)

## Summary:
The stories are broken because of a missing null check.

Adding that here.

Issue: none

## Test plan:
`yarn start`
Check that the following stories work
- http://localhost:6006/?path=/story/perseuseditor-widgets-interactive-graph-editor--default
- http://localhost:6006/?path=/story/perseuseditor-widgets-interactive-graph-editor--controlled

Author: nishasy

Reviewers: jeremywiebe

Required Reviewers:

Approved By: jeremywiebe

Checks: ✅ codecov/project, ✅ codecov/patch, ✅ Upload Coverage (ubuntu-latest, 20.x), ✅ Publish npm snapshot (ubuntu-latest, 20.x), ✅ Check builds for changes in size (ubuntu-latest, 20.x), ✅ Cypress (ubuntu-latest, 20.x), ✅ Jest Coverage (ubuntu-latest, 20.x), ✅ Lint, Typecheck, Format, and Test (ubuntu-latest, 20.x), ✅ Check for .changeset entries for all changed files (ubuntu-latest, 20.x), ✅ Publish Storybook to Chromatic (ubuntu-latest, 20.x), ✅ gerald

Pull Request URL: #1463
  • Loading branch information
nishasy authored Jul 30, 2024
1 parent 5e44b4f commit 0a118ca
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/wicked-rocks-exist.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@khanacademy/perseus-editor": patch
---

[Interactive Graph Editor - Storybook] Fix broken default and controlled stories
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ class InteractiveGraphEditor extends React.Component<Props> {
</LabeledRow>
)}
{this.props.graph?.type &&
this.props.apiOptions.flags?.mafs?.["start-coords-ui"] && (
this.props.apiOptions?.flags?.mafs?.["start-coords-ui"] && (
<StartCoordsSettings
{...this.props.graph}
range={this.props.range}
Expand Down

0 comments on commit 0a118ca

Please sign in to comment.