2023-01-19 23:32:26 +01:00
|
|
|
import type { Meta, StoryObj } from "@storybook/svelte";
|
|
|
|
import BlobViewer from "../components/display/BlobViewer.svelte";
|
2023-01-21 13:26:18 +01:00
|
|
|
import {
|
2023-01-28 20:00:21 +01:00
|
|
|
audioAddress,
|
2023-01-21 13:26:18 +01:00
|
|
|
imageAddress,
|
|
|
|
imageVerticalAddress,
|
2023-01-24 19:23:39 +01:00
|
|
|
stlAddress,
|
2023-01-21 13:26:18 +01:00
|
|
|
videoAddress,
|
|
|
|
videoVerticalAddress,
|
|
|
|
} from "./common";
|
2023-02-26 15:33:27 +01:00
|
|
|
import RouterDecorator from "./RouterDecorator.svelte";
|
2023-01-19 23:32:26 +01:00
|
|
|
|
|
|
|
const meta: Meta<BlobViewer> = {
|
|
|
|
title: "Blobs/BlobViewer",
|
|
|
|
component: BlobViewer,
|
|
|
|
tags: ["autodocs"],
|
2023-01-28 20:00:21 +01:00
|
|
|
args: {
|
|
|
|
editable: false,
|
|
|
|
},
|
2023-01-19 23:32:26 +01:00
|
|
|
argTypes: {
|
|
|
|
detail: {
|
|
|
|
control: {
|
2023-01-20 13:15:58 +01:00
|
|
|
type: "boolean",
|
|
|
|
},
|
|
|
|
},
|
2023-01-28 20:00:21 +01:00
|
|
|
editable: {
|
|
|
|
control: {
|
|
|
|
type: "boolean",
|
|
|
|
default: false,
|
|
|
|
},
|
|
|
|
},
|
2023-01-19 23:32:26 +01:00
|
|
|
},
|
2023-02-26 15:33:27 +01:00
|
|
|
decorators: [() => RouterDecorator],
|
2023-01-19 23:32:26 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
export default meta;
|
|
|
|
type Story = StoryObj<BlobViewer>;
|
|
|
|
|
2023-01-21 13:26:18 +01:00
|
|
|
export const Image: Story = {
|
|
|
|
args: { address: imageAddress },
|
|
|
|
};
|
|
|
|
|
|
|
|
export const ImageVertical: Story = {
|
|
|
|
args: { address: imageVerticalAddress },
|
|
|
|
};
|
|
|
|
|
2023-01-28 20:00:21 +01:00
|
|
|
export const Audio: Story = {
|
|
|
|
args: { address: audioAddress },
|
|
|
|
};
|
|
|
|
|
2023-01-19 23:32:26 +01:00
|
|
|
export const Video: Story = {
|
|
|
|
args: { address: videoAddress },
|
|
|
|
};
|
2023-01-20 13:15:58 +01:00
|
|
|
|
|
|
|
export const VideoVertical: Story = {
|
|
|
|
args: { address: videoVerticalAddress },
|
|
|
|
};
|
2023-01-24 19:23:39 +01:00
|
|
|
|
|
|
|
export const Model3d: Story = {
|
|
|
|
args: { address: stlAddress },
|
|
|
|
};
|