diff --git a/src/ImageCarousel.svelte b/src/ImageCarousel.svelte index ce50b77..de62788 100644 --- a/src/ImageCarousel.svelte +++ b/src/ImageCarousel.svelte @@ -1,10 +1,44 @@ -
-

{title}

-
+
+ {#if arrows} +
+ < +
+ {/if} +
+ +
+ {#if arrows} +
+ > +
+ {/if} +
\ No newline at end of file diff --git a/src/ImageCarousel.stories.js b/src/stories/ImageCarousel.stories.js similarity index 51% rename from src/ImageCarousel.stories.js rename to src/stories/ImageCarousel.stories.js index d8320c4..25b1795 100644 --- a/src/ImageCarousel.stories.js +++ b/src/stories/ImageCarousel.stories.js @@ -1,19 +1,19 @@ -import ImageCarousel from './ImageCarousel.svelte'; +import ImageCarouselView from './ImageCarouselView.svelte'; export default { title: 'ImageCarousel', - component: ImageCarousel, + component: ImageCarouselView, argTypes: { - title: { control: 'text' }, + arrows: { control: 'boolean' }, }, }; const Template = ({ ...args }) => ({ - Component: ImageCarousel, + Component: ImageCarouselView, props: args, }); export const Primary = Template.bind({}); Primary.args = { - title: 'This is a title' + arrows: true }; diff --git a/src/stories/ImageCarouselView.svelte b/src/stories/ImageCarouselView.svelte new file mode 100644 index 0000000..89c24c2 --- /dev/null +++ b/src/stories/ImageCarouselView.svelte @@ -0,0 +1,22 @@ + + +
+ +

Element 1

+

Element 2

+
+
+ + \ No newline at end of file