/*
* Copyright (c) 2020 - present Cloudogu GmbH
*
* This program is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
* details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see https://www.gnu.org/licenses/.
*/
// import React from "react";
// import { MemoryRouter } from "react-router-dom";
// import { storiesOf } from "@storybook/react";
// import CardColumnSmall from "./CardColumnSmall";
// import Icon from "./Icon";
// import styled from "styled-components";
//
// const Wrapper = styled.div`
// margin: 2rem;
// max-width: 400px;
// `;
//
// const link = "/foo/bar";
// const avatar = ;
// const contentLeft = main content;
// const contentRight = more text;
//
// storiesOf("CardColumnSmall", module)
// .addDecorator((story) => {story()})
// .addDecorator((storyFn) => {storyFn()})
// .add("Default", () => (
//
// ))
// .add("Minimal", () => )
// .add("Task", () => (
// }
// contentLeft={Repository created}
// contentRight={over 42 years ago}
// footer="New: scmadmin/spaceship"
// />
// ))
// .add("Linkless", () => (
// }
// contentLeft={Repository deleted}
// contentRight={over 1337 minutes ago}
// footer="Deleted: scmadmin/spaceship"
// />
// ));
import React from "react";
import styled from "styled-components";
import type { Meta, StoryObj } from "@storybook/react";
import CardColumnSmall from "./CardColumnSmall";
import Icon from "./Icon";
import { MemoryRouter } from "react-router-dom";
// --- Mock Data and Helpers (preserved from your original story) ---
const Wrapper = styled.div`
margin: 2rem;
max-width: 400px;
`;
const link = "/foo/bar";
const avatar = ;
const contentLeft = main content;
const contentRight = more text;
// --- Storybook Metadata ---
const meta: Meta = {
title: "Components/CardColumnSmall",
component: CardColumnSmall,
// The Wrapper is now a decorator in the meta object
decorators: [
(Story) => {Story()},
(Story) => {Story()}],
tags: ["autodocs"], // Enables automatic documentation generation
};
export default meta;
// --- Story Definitions ---
type Story = StoryObj;
export const Default: Story = {
args: {
// Props for the component go into the `args` object
link: link,
avatar: avatar,
contentLeft: contentLeft,
contentRight: contentRight,
},
};
export const Minimal: Story = {
args: {
link: link,
contentLeft: contentLeft,
contentRight: contentRight,
},
};
export const Task: Story = {
args: {
link: link,
avatar: ,
contentLeft: Repository created,
contentRight: over 42 years ago,
footer: "New: scmadmin/spaceship",
},
};
export const Linkless: Story = {
args: {
avatar: ,
contentLeft: Repository deleted,
contentRight: over 1337 minutes ago,
footer: "Deleted: scmadmin/spaceship",
},
};