Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: HeaderWithBackButton component shows error in storybook #30773

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/stories/HeaderWithBackButton.stories.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import React from 'react';
import HeaderWithBackButton from '@components/HeaderWithBackButton';
import withNavigationFallback from '@components/withNavigationFallback';

const HeaderWithBackButtonWithNavigation = withNavigationFallback(HeaderWithBackButton);

/**
* We use the Component Story Format for writing stories. Follow the docs here:
Expand All @@ -8,12 +11,12 @@ import HeaderWithBackButton from '@components/HeaderWithBackButton';
*/
const story = {
title: 'Components/HeaderWithBackButton',
component: HeaderWithBackButton,
component: HeaderWithBackButtonWithNavigation,
};

function Template(args) {
// eslint-disable-next-line react/jsx-props-no-spreading
return <HeaderWithBackButton {...args} />;
return <HeaderWithBackButtonWithNavigation {...args} />;
}

// Arguments can be passed to the component by binding
Expand Down
Loading