-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
128 changed files
with
8,094 additions
and
8,539 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -110,3 +110,6 @@ dist | |
lib/ | ||
yarn-error.log | ||
storybook-static/ | ||
|
||
# IDEA files | ||
.idea/ |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import type { StorybookConfig } from '@storybook/react-vite'; | ||
const config: StorybookConfig = { | ||
stories: ['../stories/**/*.stories.@(ts|tsx)', '../stories/**/*.mdx'], | ||
addons: ['@storybook/addon-links', '@storybook/addon-essentials'], | ||
framework: { | ||
name: '@storybook/react-vite', | ||
options: {}, | ||
}, | ||
docs: { | ||
autodocs: true, | ||
}, | ||
}; | ||
export default config; |
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import './storybook.scss'; | ||
import { Preview } from '@storybook/react'; | ||
|
||
const preview: Preview = { | ||
parameters: { | ||
actions: { argTypesRegex: '^on[A-Z].*' }, | ||
options: { | ||
storySort: { | ||
order: ['Welcome', 'Migration Guides', 'Components', 'FormBehaviour', 'Deprecated'], | ||
}, | ||
}, | ||
}, | ||
}; | ||
export default preview; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { create } from '@storybook/theming/create'; | ||
const version = require('../package.json').version; | ||
|
||
export default create({ | ||
base: 'light', | ||
|
||
colorPrimary: '#005eb8', | ||
colorSecondary: '#768692', | ||
|
||
// UI | ||
appBg: 'white', | ||
appContentBg: 'white', | ||
appBorderColor: 'grey', | ||
appBorderRadius: 4, | ||
|
||
// Typography | ||
fontCode: 'monospace', | ||
|
||
// Text colors | ||
textColor: '#212b32', | ||
textInverseColor: 'white', | ||
|
||
// Toolbar default and active colors | ||
barTextColor: 'rgba(255,255,255,0.8)', | ||
barSelectedColor: 'rgba(255,255,255,1)', | ||
barBg: '#005eb8', | ||
|
||
// Form colors | ||
inputBg: 'white', | ||
inputBorder: '#425563', | ||
inputTextColor: '#212b32', | ||
inputBorderRadius: 4, | ||
|
||
brandTitle: `NHS.UK React Components (v${version})`, | ||
brandUrl: 'https://github.com/NHSDigital/nhsuk-react-components', | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "nhsuk-react-components", | ||
"version": "2.2.0", | ||
"version": "2.2.1", | ||
"author": { | ||
"email": "[email protected]", | ||
"name": "Thomas Judd-Cooper", | ||
|
@@ -9,23 +9,31 @@ | |
"license": "MIT", | ||
"devDependencies": { | ||
"@babel/cli": "^7.13.16", | ||
"@babel/core": "^7.14.0", | ||
"@rollup/plugin-commonjs": "^19.0.0", | ||
"@rollup/plugin-node-resolve": "^13.0.0", | ||
"@storybook/addon-actions": "^6.2.9", | ||
"@storybook/addon-essentials": "^6.2.9", | ||
"@storybook/addon-links": "^6.2.9", | ||
"@storybook/react": "^6.2.9", | ||
"@storybook/storybook-deployer": "^2.8.7", | ||
"@babel/core": "^7.19.6", | ||
"@babel/preset-react": "^7.18.6", | ||
"@rollup/plugin-commonjs": "^24.1.0", | ||
"@rollup/plugin-node-resolve": "^15.0.2", | ||
"@rollup/plugin-typescript": "^11.1.0", | ||
"@storybook/addon-actions": "^7.0.2", | ||
"@storybook/addon-essentials": "^7.0.2", | ||
"@storybook/addon-links": "^7.0.2", | ||
"@storybook/addons": "^7.0.2", | ||
"@storybook/blocks": "^7.0.2", | ||
"@storybook/preview-web": "^7.0.2", | ||
"@storybook/react": "^7.0.2", | ||
"@storybook/react-vite": "^7.0.2", | ||
"@storybook/theming": "^7.0.2", | ||
"@types/enzyme": "^3.10.8", | ||
"@types/jest": "^26.0.23", | ||
"@types/jest-axe": "^3.5.1", | ||
"@types/node": "^15.0.2", | ||
"@types/react": "16.14.0", | ||
"@types/react-dom": "^16.9.12", | ||
"@types/rollup-plugin-peer-deps-external": "^2.2.1", | ||
"@typescript-eslint/eslint-plugin": "^4.23.0", | ||
"@typescript-eslint/parser": "^4.23.0", | ||
"babel-loader": "^8.2.2", | ||
"chromatic": "^6.17.3", | ||
"enzyme": "^3.11.0", | ||
"enzyme-adapter-react-16": "^1.15.6", | ||
"enzyme-to-json": "^3.6.2", | ||
|
@@ -45,14 +53,15 @@ | |
"react": "^16.14.0", | ||
"react-dom": "^16.14.0", | ||
"regenerator-runtime": "^0.13.7", | ||
"rollup": "^2.47.0", | ||
"rollup": "^3.20.2", | ||
"rollup-plugin-dts": "^5.3.0", | ||
"rollup-plugin-peer-deps-external": "^2.2.4", | ||
"rollup-plugin-typescript2": "^0.30.0", | ||
"sass": "^1.32.12", | ||
"sass-loader": "10.1.1", | ||
"storybook": "^7.0.2", | ||
"ts-jest": "^26.5.6", | ||
"ts-node": "^9.1.1", | ||
"typescript": "4.2.4" | ||
"typescript": "4.2.4", | ||
"vite": "^4.2.1" | ||
}, | ||
"peerDependencies": { | ||
"nhsuk-frontend": ">=4.0.0", | ||
|
@@ -62,18 +71,21 @@ | |
"dependencies": { | ||
"classnames": "^2.2.6" | ||
}, | ||
"resolutions": { | ||
"@types/react": "16.14.0" | ||
}, | ||
"scripts": { | ||
"cleanup": "rm -rf dist/ > /dev/null && rm -rf lib/ > /dev/null", | ||
"storybook": "start-storybook -p 6006", | ||
"storybook": "storybook dev -p 6006", | ||
"build:dist": "rollup -c", | ||
"build:lib": "NODE_ENV=production babel src --out-dir lib --extensions \".ts,.tsx\" --ignore \"**/__tests__,**/__mocks__,**/setupTests.ts\"", | ||
"build": "yarn cleanup && yarn build:dist && yarn build:lib", | ||
"test": "jest", | ||
"test:ci": "jest --coverage", | ||
"lint": "eslint 'src/**/*.{js,ts,tsx}' 'stories/**/*.{js,ts,tsx}' --fix", | ||
"lint:ci": "eslint 'src/**/*.{js,ts,tsx}' 'stories/**/*.{js,ts,tsx}'", | ||
"build-storybook": "build-storybook", | ||
"prepublishOnly": "yarn lint:ci && yarn test:ci && yarn start-storybook --smoke-test" | ||
"build-storybook": "storybook build", | ||
"prepublishOnly": "yarn lint:ci && yarn test:ci && yarn storybook --smoke-test" | ||
}, | ||
"files": [ | ||
"dist", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.