import React from "react"; import type { Meta, StoryObj } from "@storybook/react"; import { createKcPageStory } from "../KcPageStory"; const { KcPageStory } = createKcPageStory({ pageId: "webauthn-register.ftl" }); const meta = { title: "login/webauthn-register.ftl", component: KcPageStory } satisfies Meta; export default meta; type Story = StoryObj; export const Default: Story = { render: () => }; /** * WithRetryAvailable: * - Purpose: Tests when the user is allowed to retry WebAuthn registration after a failure. * - Scenario: The component renders the form with a retry option. * - Key Aspect: Ensures the retry functionality is available and the form allows the user to retry. */ export const WithRetryAvailable: Story = { render: () => ( ) }; /** * WithErrorDuringRegistration: * - Purpose: Tests when an error occurs during WebAuthn registration. * - Scenario: The component displays an error message related to WebAuthn registration failure. * - Key Aspect: Ensures the error message is displayed correctly, informing the user of the registration failure. */ export const WithErrorDuringRegistration: Story = { render: () => ( ) };