Skip to content

Commit

Permalink
chore: simplified config
Browse files Browse the repository at this point in the history
  • Loading branch information
basilgood committed Aug 3, 2024
1 parent 6fbfbe1 commit e078d9d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 26 deletions.
16 changes: 2 additions & 14 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,11 @@
/** @type { import('@storybook/web-components-vite').StorybookConfig } */
const config = {
export default {
stories: ['../stories/**/*.stories.{js,ts,mdx}'],
addons: ['@storybook/addon-essentials', '@storybook/addon-links'],
core: {
builder: '@storybook/builder-vite',
disableTelemetry: true,
},
framework: {
name: '@storybook/web-components-vite',
options: {},
},
docs: {
autodocs: true,
defaultName: 'Docs',
},
framework: '@storybook/web-components-vite',
staticDirs: ['../stories/images'],
async viteFinal(config) {
return config;
},
};

export default config;
16 changes: 4 additions & 12 deletions stories/cosmoz-image-viewer.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { images } from './data.js';
export default {
title: 'Cosmoz Image Viewer',
component: 'cosmoz-image-viewer',
tags: ['autodocs'],
};

export const Basic = ({
Expand Down Expand Up @@ -36,10 +37,7 @@ export const Basic = ({
?loop=${loop}
?show-zoom=${showZoom}
?detached-show-zoom=${detachedShowZoom}
.images=${[
'cosmos1.jpg',
'cosmos2.jpg',
]}
.images=${['cosmos1.jpg', 'cosmos2.jpg']}
></cosmoz-image-viewer>
`;

Expand All @@ -54,14 +52,8 @@ Basic.args = {
};

export const Issue21 = () => {
const images1 = [
'stockholm.jpg',
'strasbourg.jpg',
],
images2 = [
'cosmos1.jpg',
'cosmos2.jpg',
];
const images1 = ['stockholm.jpg', 'strasbourg.jpg'],
images2 = ['cosmos1.jpg', 'cosmos2.jpg'];
return html`
<cosmoz-image-viewer
show-detach
Expand Down
2 changes: 2 additions & 0 deletions stories/haunted-pan-zoom.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import '../cosmoz-image-viewer.js';
export default {
title: 'Pan Zoom',
component: 'haunted-pan-zoom',
tags: ['autodocs'],
};

const Template = ({ disabled, height, zoomStiffness, panStiffness }) => html`
<haunted-pan-zoom
src="a_size.png"
Expand Down

0 comments on commit e078d9d

Please sign in to comment.