mirror of
https://github.com/aljazceru/landscape-template.git
synced 2026-01-05 15:34:29 +01:00
Refactored the project structure so that each page has its own tree of components and a global "Components" folder for the components that is used by more than one page. - Added an "assets" directory that exports all static images/icons/fonts/...etc
30 lines
794 B
TypeScript
30 lines
794 B
TypeScript
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
|
|
import CopyToClipboard from './CopyToClipboard';
|
|
|
|
export default {
|
|
title: 'Shared/Copy To Clipboard',
|
|
component: CopyToClipboard,
|
|
|
|
} as ComponentMeta<typeof CopyToClipboard>;
|
|
|
|
const Template: ComponentStory<typeof CopyToClipboard> = (args) => <div className="flex h-[400px] justify-center items-center"><div className="input-wrapper mt-32 max-w-[320px] mx-auto">
|
|
<input
|
|
className="input-field overflow-ellipsis"
|
|
value={'Some Text To Copy'}
|
|
/>
|
|
<CopyToClipboard {...args} text="Some Text To Copy" />
|
|
</div></div>;
|
|
|
|
export const Default = Template.bind({});
|
|
Default.args = {
|
|
text: "Some Text To Copy"
|
|
}
|
|
|
|
export const Above = Template.bind({});
|
|
Above.args = {
|
|
text: "Some Text To Copy",
|
|
direction: "top"
|
|
}
|
|
|