From 23c5fcce65d746125de73829409260ddf2488519 Mon Sep 17 00:00:00 2001 From: 王强 Date: Fri, 22 Mar 2024 09:39:46 +0800 Subject: [PATCH] feat: init --- src/components//index.module.less | 4 ++++ src/components//index.tsx | 11 +++++++++++ stories/.stories.ts | 29 +++++++++++++++++++++++++++++ 3 files changed, 44 insertions(+), 0 deletions(-) create mode 100644 src/components//index.module.less create mode 100644 src/components//index.tsx create mode 100644 stories/.stories.ts diff --git a/src/components//index.module.less b/src/components//index.module.less new file mode 100644 index 0000000..ba8c1db --- /dev/null +++ b/src/components//index.module.less @@ -0,0 +1,4 @@ +. { + background-color: #4189fd; + color: #fff; +} diff --git a/src/components//index.tsx b/src/components//index.tsx new file mode 100644 index 0000000..41d3d37 --- /dev/null +++ b/src/components//index.tsx @@ -0,0 +1,11 @@ +import React from "react"; +import clsx from "clsx"; +import st from "./index.module.less"; + +export interface BaseProps {} + +export default function ({}: BaseProps) { + const className = clsx(st['']); + + return (); +} diff --git a/stories/.stories.ts b/stories/.stories.ts new file mode 100644 index 0000000..01c4dcd --- /dev/null +++ b/stories/.stories.ts @@ -0,0 +1,29 @@ +import type { Meta, StoryObj } from "@storybook/react"; +// import { userEvent, within, fn } from '@storybook/test'; +import from '../src/components/'; + +const meta: Meta> = { + title: "H5-Common/Componet/", + component: , + tags: ["autodocs"], + parameters: { + layout: "centered", + }, + args: { + }, + argTypes: { + }, +}; + +export default meta; +type Story = StoryObj>; + +/* + *👇 Render functions are a framework specific feature to allow you control on how the component renders. + * See https://storybook.js.org/docs/api/csf + * to learn how to use render functions. + */ +export const Primary: Story = { + args: { + }, +}; -- libgit2 0.22.2