diff --git a/.storybook/main.ts b/.storybook/main.ts index 5de8735a..6f8dca60 100644 --- a/.storybook/main.ts +++ b/.storybook/main.ts @@ -4,13 +4,15 @@ import { type InlineConfig, mergeConfig } from 'vite'; import tsConfigPaths from 'vite-tsconfig-paths'; const config: StorybookConfig = { - stories: ['../stories/**/*.stories.@(ts|tsx)', '../stories/**/*.mdx'], addons: ['@storybook/addon-links', '@storybook/addon-docs'], framework: { name: '@storybook/react-vite', options: {}, }, + staticDirs: ['../node_modules/nhsuk-frontend/dist/nhsuk'], + stories: ['../stories/**/*.stories.@(ts|tsx)', '../stories/**/*.mdx'], + typescript: { reactDocgen: 'react-docgen-typescript', }, diff --git a/.storybook/preview-head.html b/.storybook/preview-head.html new file mode 100644 index 00000000..5a85c138 --- /dev/null +++ b/.storybook/preview-head.html @@ -0,0 +1 @@ + diff --git a/.storybook/storybook.scss b/.storybook/storybook.scss index ea4b70a2..1cf1ac12 100644 --- a/.storybook/storybook.scss +++ b/.storybook/storybook.scss @@ -1,5 +1,3 @@ -@forward 'nhsuk-frontend/dist/nhsuk'; - .tag-wrapper { display: flex; flex-direction: column; diff --git a/.storybook/theme.ts b/.storybook/theme.ts index c47f6582..e2a816a2 100644 --- a/.storybook/theme.ts +++ b/.storybook/theme.ts @@ -4,6 +4,6 @@ import packageJson from '../package.json' with { type: 'json' }; export default create({ base: 'light', - brandTitle: `NHS.UK React Components (v${packageJson.version})`, + brandTitle: `NHS.UK React components (v${packageJson.version})`, brandUrl: 'https://github.com/NHSDigital/nhsuk-react-components', }); diff --git a/README.md b/README.md index d80ff5f2..5d239140 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # NHS.UK React components -This repository contains the code for NHS.UK React components - a port of the [NHS.UK Frontend components](https://github.com/nhsuk/nhsuk-frontend). +This repository contains the code for NHS.UK React components - a port of the [NHS.UK frontend components](https://github.com/nhsuk/nhsuk-frontend). [](https://github.com/NHSDigital/nhsuk-react-components/actions?query=workflow%3A%22CI+Build%22+branch%3Amain) [](https://bundlephobia.com/result?p=nhsuk-react-components) @@ -22,7 +22,7 @@ yarn add nhsuk-react-components ## Usage ```jsx -import { DateInput, Form } from 'nhsuk-react-components'; +import { Button, DateInput, Form } from 'nhsuk-react-components';