import { Meta, StoryObj } from '@storybook/react-webpack5';
import Logo, { LogoType } from '.';
/**
* **Design guidance**: wise.design/foundations/logo
*/
const meta: Meta = {
component: Logo,
title: 'Content/Logo',
args: {
type: 'WISE',
inverse: false,
},
argTypes: {
type: {
control: 'radio',
options: Object.values(LogoType),
},
},
parameters: {
docs: { toc: true },
},
};
export default meta;
type Story = StoryObj;
/** Explore all props via the controls panel. */
export const Playground: Story = {
render: (args) => (
),
};
/**
* The three logo types: standard Wise, Wise Business, and Wise Platform.
* `WISE_BUSINESS` renders the same SVG as `WISE` but with the accessible label "Wise Business".
*/
export const Types: Story = {
argTypes: {
type: { table: { disable: true } },
},
render: (args) => (
{Object.values(LogoType).map((type) => (
{type}
))}
),
parameters: {
docs: {
source: {
code: ``,
},
},
},
};
/**
* Below `576px` the flag-only mark is shown; at `576px` and above the full wordmark is displayed.
*/
export const Responsive: Story = {
argTypes: {
type: { table: { disable: true } },
inverse: { table: { disable: true } },
},
render: (args) => (
{'< 576px (flag only)'}
{Object.values(LogoType).map((type) => (
))}
{'\u2265 576px (full wordmark)'}
{Object.values(LogoType).map((type) => (
))}
),
parameters: {
docs: {
source: { code: null },
},
},
};
/**
* All logo types on a dark background using the `inverse` prop, which renders a
* light-coloured version suited for dark surfaces.
*/
export const Inverse: Story = {
argTypes: {
type: { table: { disable: true } },
inverse: { table: { disable: true } },
},
decorators: [
(Story) => (