Files
twenty/front/src/__stories__/App.darkMode.stories.tsx
Félix Malfait 5ae5f28dcb Add new story for darkmode (#317)
* Add a new story for dark mode

* Reorganize storybook menu

* Fix command menu margins

* Fix tests
2023-06-17 14:52:49 +02:00

31 lines
653 B
TypeScript

import { Meta } from '@storybook/react';
import { App } from '~/App';
import { graphqlMocks } from '~/testing/graphqlMocks';
import { mockedUserJWT } from '~/testing/mock-data/jwt';
import { Story } from './App.stories';
import { renderWithDarkMode } from './shared';
const meta: Meta<typeof App> = {
title: 'App/App/DarkMode',
component: App,
};
export default meta;
export const DarkMode: Story = {
render: () => renderWithDarkMode(true),
loaders: [
async () => ({
accessTokenStored: window.localStorage.setItem(
'accessToken',
mockedUserJWT,
),
}),
],
parameters: {
msw: graphqlMocks,
},
};