redux-devtools/packages/redux-devtools-ui/src/SegmentedControl/SegmentedControl.stories.tsx
Nathan Bierema 61632768a7
Replace styled-components with Emotion (#1883)
* Replace styled-components with Emotion in ui

* react-dock

* Remainder

* Fix

* Format

* Update snapshots

* Create bright-sheep-joke.md
2025-06-01 13:59:13 +00:00

39 lines
847 B
TypeScript

import React from 'react';
import styled from '@emotion/styled';
import { Meta, StoryObj } from '@storybook/react-vite';
import SegmentedControl from './';
const Container = styled.div`
display: flex;
height: 100%;
width: 100%;
justify-content: center;
align-items: center;
`;
const meta: Meta = {
title: 'SegmentedControl',
component: SegmentedControl,
};
export default meta;
type Story = StoryObj<typeof SegmentedControl>;
export const Default: Story = {
render: ({ values, ...args }) => (
<Container>
<SegmentedControl values={['Button1', 'Button2', 'Button3']} {...args} />
</Container>
),
args: {
selected: 'Button1',
disabled: false,
},
argTypes: {
values: { control: { disable: true } },
onClick: { control: { disable: true } },
theme: { control: { disable: true } },
},
};