From c4f3e2c309609c3820d0ca7001abd82a69ecadcc Mon Sep 17 00:00:00 2001 From: Cee Chen Date: Mon, 2 Oct 2023 14:02:24 -0700 Subject: [PATCH] moldy potato - update EuiErrorBoundary story - it was the first and one and therefore the worst one, and we are much better at writing stories now --- .../error_boundary/error_boundary.stories.tsx | 31 ++++++++----------- 1 file changed, 13 insertions(+), 18 deletions(-) diff --git a/src/components/error_boundary/error_boundary.stories.tsx b/src/components/error_boundary/error_boundary.stories.tsx index 54b011ba4a7..f62dffba499 100644 --- a/src/components/error_boundary/error_boundary.stories.tsx +++ b/src/components/error_boundary/error_boundary.stories.tsx @@ -11,31 +11,26 @@ import type { Meta, StoryObj } from '@storybook/react'; import { EuiErrorBoundary, EuiErrorBoundaryProps } from './error_boundary'; -const ErrorContent = () => { - throw new Error( - "I'm here to kick butt and chew bubblegum.\n\nAnd I'm all out of gum." - ); -}; - const meta: Meta = { title: 'EuiErrorBoundary', - component: () => ( - - - - ), + component: EuiErrorBoundary, parameters: { layout: 'fullscreen', }, - argTypes: { - onError: { - description: - 'TODO: extract prop descriptions, defaults, and types from Typescript ', - }, - }, }; export default meta; type Story = StoryObj; -export const Default: Story = {}; +const ErrorContent = () => { + throw new Error( + "I'm here to kick butt and chew bubblegum.\n\nAnd I'm all out of gum." + ); +}; + +export const Playground: Story = { + args: { + children: , + onError: console.log, + }, +};