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

feat: add ItemSelector component #33

Merged
merged 7 commits into from
Apr 18, 2023
Merged

Conversation

Flunt1k
Copy link
Contributor

@Flunt1k Flunt1k commented Apr 17, 2023

No description provided.

@gravity-ui-bot
Copy link
Contributor

Preview is ready.

import {ItemSelector} from '../ItemSelector';

export default {
title: 'Components/AdaptiveTabs',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why adaptive tabs?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

];

const DefaultTemplate: Story = (args) => {
const [value, setValue] = useState<string[]>([]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use story args update instead, like

import {useArgs} from '@storybook/client-api';

const Template: ComponentStory<typeof ItemSelector> = (args) => {
  const [, setStoryArgs] = useArgs();

  return <ItemSelector {...args} onUpdate={(value) => setStoryArg(value)}/>
}

@Flunt1k Flunt1k changed the title feat: introduce ItemSelector component feat: add ItemSelector component Apr 18, 2023
@Flunt1k Flunt1k merged commit 55c33ce into main Apr 18, 2023
@Flunt1k Flunt1k deleted the item-selector/add-component branch April 18, 2023 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants