Basic storybook setup and update readme
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
//This is to show that you can create stories for pages that you haven't overloaded.
|
||||
|
||||
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
||||
import { createPageStory } from "../createPageStory";
|
||||
|
||||
const { PageStory } = createPageStory({
|
||||
pageId: "login-reset-password.ftl"
|
||||
});
|
||||
|
||||
export default {
|
||||
title: "login/LoginResetPassword",
|
||||
component: PageStory,
|
||||
} as ComponentMeta<typeof PageStory>;
|
||||
|
||||
export const Default: ComponentStory<typeof PageStory> = () => <PageStory />;
|
||||
|
||||
export const WithEmailAsUsername: ComponentStory<typeof PageStory> = () => (
|
||||
<PageStory
|
||||
kcContext={{
|
||||
realm: { loginWithEmailAllowed: true, registrationEmailAsUsername: true }
|
||||
}}
|
||||
/>
|
||||
);
|
||||
@@ -0,0 +1,13 @@
|
||||
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
||||
import { createPageStory } from "../createPageStory";
|
||||
|
||||
const { PageStory } = createPageStory({
|
||||
pageId: "terms.ftl"
|
||||
});
|
||||
|
||||
export default {
|
||||
title: "login/Terms",
|
||||
component: PageStory,
|
||||
} as ComponentMeta<typeof PageStory>;
|
||||
|
||||
export const Primary: ComponentStory<typeof PageStory> = () => <PageStory />;
|
||||
Reference in New Issue
Block a user