import { Meta, Story, ArgsTable, Canvas } from '@storybook/blocks';
import ReplaceEdition from '../ReplaceEdition';
import * as ReplaceEditionStories from './ReplaceEdition.stories';

export const mockSelectEdition = () => {}
export const mockViewCart = () => {}
export const mockExit = () => {}

<Meta of={ReplaceEditionStories} />

# ReplaceEdition

<br />

## `ReplaceEdition` is used when an edition of a non-stackable product is already in cart.

<br />

### Default

<Canvas>
  <Story of={ReplaceEditionStories.Default} />
</Canvas>

```jsx
import ReplaceEdition from '@appdirect/sfb-theme-components/src/atoms/replace-edition/ReplaceEdition';

<ReplaceEdition
    editionName="Enterprise Plan"
    onSelectEdition={mockSelectEdition}
    onViewCart={onViewCart}
    onExit={mockExit}
/>
```

## Props

<ArgsTable of={ReplaceEdition} />
