@hmlr/govuk-react-components-library 1.1.0 → 1.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -3
- package/assets/uml-diagram.svg +620 -575
- package/bundle-analysis-main.html +1 -3
- package/bundle-analysis-pdfvc.html +1 -1
- package/dist/PDFViewerCanvas.cjs.js +2003 -16
- package/dist/PDFViewerCanvas.cjs.js.map +1 -1
- package/dist/PDFViewerCanvas.d.ts +30 -0
- package/dist/PDFViewerCanvas.esm.js +1974 -5
- package/dist/PDFViewerCanvas.esm.js.map +1 -1
- package/dist/index.cjs.css +18 -11
- package/dist/index.cjs.js +2120 -125
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +81 -4
- package/dist/index.esm.css +18 -11
- package/dist/index.esm.js +2103 -108
- package/dist/index.esm.js.map +1 -1
- package/package.json +27 -29
- package/scripts/generateStories.mjs +3 -3
- package/dist/types/PDFViewerCanvas.d.ts +0 -1
- package/dist/types/components/Accordion/Accordion.config.d.ts +0 -5
- package/dist/types/components/Accordion/Accordion.d.ts +0 -4
- package/dist/types/components/Accordion/Accordion.types.d.ts +0 -20
- package/dist/types/components/Accordion/index.d.ts +0 -2
- package/dist/types/components/ActionLink/ActionLink.d.ts +0 -4
- package/dist/types/components/ActionLink/ActionLink.types.d.ts +0 -13
- package/dist/types/components/ActionLink/index.d.ts +0 -1
- package/dist/types/components/BackLink/BackLink.d.ts +0 -4
- package/dist/types/components/BackLink/BackLink.types.d.ts +0 -9
- package/dist/types/components/BackLink/index.d.ts +0 -1
- package/dist/types/components/Boolean/Boolean.d.ts +0 -4
- package/dist/types/components/Boolean/Boolean.types.d.ts +0 -39
- package/dist/types/components/Boolean/OmitKey.d.ts +0 -5
- package/dist/types/components/Boolean/index.d.ts +0 -1
- package/dist/types/components/Breadcrumbs/Breadcrumbs.d.ts +0 -4
- package/dist/types/components/Breadcrumbs/Breadcrumbs.types.d.ts +0 -13
- package/dist/types/components/Breadcrumbs/index.d.ts +0 -1
- package/dist/types/components/Button/Button.config.d.ts +0 -2
- package/dist/types/components/Button/Button.d.ts +0 -4
- package/dist/types/components/Button/Button.types.d.ts +0 -13
- package/dist/types/components/Button/index.d.ts +0 -2
- package/dist/types/components/CardColumn/CardColumn.d.ts +0 -5
- package/dist/types/components/CardColumn/CardColumn.types.d.ts +0 -5
- package/dist/types/components/CardColumn/index.d.ts +0 -1
- package/dist/types/components/CardLayout/CardLayout.d.ts +0 -4
- package/dist/types/components/CardLayout/CardLayout.types.d.ts +0 -5
- package/dist/types/components/CardLayout/index.d.ts +0 -1
- package/dist/types/components/CharacterCount/CharacterCount.config.d.ts +0 -2
- package/dist/types/components/CharacterCount/CharacterCount.d.ts +0 -4
- package/dist/types/components/CharacterCount/CharacterCount.types.d.ts +0 -12
- package/dist/types/components/CharacterCount/index.d.ts +0 -1
- package/dist/types/components/Checkboxes/Checkboxes.config.d.ts +0 -1
- package/dist/types/components/Checkboxes/Checkboxes.d.ts +0 -4
- package/dist/types/components/Checkboxes/Checkboxes.types.d.ts +0 -3
- package/dist/types/components/Checkboxes/index.d.ts +0 -2
- package/dist/types/components/CookieBanner/CookieBanner.d.ts +0 -4
- package/dist/types/components/CookieBanner/CookieBanner.types.d.ts +0 -21
- package/dist/types/components/CookieBanner/index.d.ts +0 -1
- package/dist/types/components/DataNavigation/DataNavigation.d.ts +0 -4
- package/dist/types/components/DataNavigation/DataNavigation.types.d.ts +0 -9
- package/dist/types/components/DataNavigation/index.d.ts +0 -1
- package/dist/types/components/DateInput/DateInput.d.ts +0 -4
- package/dist/types/components/DateInput/DateInput.types.d.ts +0 -29
- package/dist/types/components/DateInput/index.d.ts +0 -1
- package/dist/types/components/Details/Details.d.ts +0 -4
- package/dist/types/components/Details/Details.types.d.ts +0 -5
- package/dist/types/components/Details/index.d.ts +0 -1
- package/dist/types/components/DifferenceNavigation/DifferenceNavigation.d.ts +0 -4
- package/dist/types/components/DifferenceNavigation/DifferenceNavigation.types.d.ts +0 -7
- package/dist/types/components/DifferenceNavigation/index.d.ts +0 -1
- package/dist/types/components/ErrorBoundary/ErrorBoundary.d.ts +0 -9
- package/dist/types/components/ErrorBoundary/ErrorBoundary.types.d.ts +0 -11
- package/dist/types/components/ErrorBoundary/index.d.ts +0 -1
- package/dist/types/components/ErrorMessage/ErrorMessage.d.ts +0 -4
- package/dist/types/components/ErrorMessage/ErrorMessage.types.d.ts +0 -6
- package/dist/types/components/ErrorMessage/index.d.ts +0 -1
- package/dist/types/components/ErrorSummary/ErrorSummary.config.d.ts +0 -2
- package/dist/types/components/ErrorSummary/ErrorSummary.d.ts +0 -4
- package/dist/types/components/ErrorSummary/ErrorSummary.types.d.ts +0 -13
- package/dist/types/components/ErrorSummary/index.d.ts +0 -2
- package/dist/types/components/ExitThisPage/ExitThisPage.config.d.ts +0 -1
- package/dist/types/components/ExitThisPage/ExitThisPage.d.ts +0 -4
- package/dist/types/components/ExitThisPage/ExitThisPage.types.d.ts +0 -17
- package/dist/types/components/ExitThisPage/index.d.ts +0 -2
- package/dist/types/components/Fieldset/Fieldset.d.ts +0 -4
- package/dist/types/components/Fieldset/Fieldset.types.d.ts +0 -12
- package/dist/types/components/Fieldset/index.d.ts +0 -1
- package/dist/types/components/FileUpload/FileUpload.d.ts +0 -4
- package/dist/types/components/FileUpload/FileUpload.types.d.ts +0 -15
- package/dist/types/components/FileUpload/index.d.ts +0 -1
- package/dist/types/components/Footer/Footer.d.ts +0 -4
- package/dist/types/components/Footer/Footer.types.d.ts +0 -33
- package/dist/types/components/Footer/index.d.ts +0 -1
- package/dist/types/components/Header/Header.config.d.ts +0 -1
- package/dist/types/components/Header/Header.d.ts +0 -4
- package/dist/types/components/Header/Header.types.d.ts +0 -28
- package/dist/types/components/Header/index.d.ts +0 -2
- package/dist/types/components/Hint/Hint.d.ts +0 -4
- package/dist/types/components/Hint/Hint.types.d.ts +0 -4
- package/dist/types/components/Hint/index.d.ts +0 -1
- package/dist/types/components/Input/Input.d.ts +0 -4
- package/dist/types/components/Input/Input.types.d.ts +0 -22
- package/dist/types/components/Input/index.d.ts +0 -1
- package/dist/types/components/InsetText/InsetText.d.ts +0 -4
- package/dist/types/components/InsetText/InsetText.types.d.ts +0 -4
- package/dist/types/components/InsetText/index.d.ts +0 -1
- package/dist/types/components/Label/Label.d.ts +0 -4
- package/dist/types/components/Label/Label.types.d.ts +0 -6
- package/dist/types/components/Label/index.d.ts +0 -1
- package/dist/types/components/Landing/Landing.d.ts +0 -4
- package/dist/types/components/Landing/Landing.types.d.ts +0 -4
- package/dist/types/components/Landing/index.d.ts +0 -1
- package/dist/types/components/LinkWithRef/LinkWithRef.d.ts +0 -4
- package/dist/types/components/LinkWithRef/LinkWithRef.types.d.ts +0 -9
- package/dist/types/components/LinkWithRef/index.d.ts +0 -1
- package/dist/types/components/Loading/Loading.d.ts +0 -5
- package/dist/types/components/Loading/Loading.types.d.ts +0 -4
- package/dist/types/components/Loading/index.d.ts +0 -1
- package/dist/types/components/Main/Main.d.ts +0 -4
- package/dist/types/components/Main/Main.types.d.ts +0 -5
- package/dist/types/components/Main/index.d.ts +0 -1
- package/dist/types/components/NotFoundPage/NotFoundPage.d.ts +0 -3
- package/dist/types/components/NotFoundPage/index.d.ts +0 -1
- package/dist/types/components/NotificationBanner/NotificationBanner.config.d.ts +0 -2
- package/dist/types/components/NotificationBanner/NotificationBanner.d.ts +0 -4
- package/dist/types/components/NotificationBanner/NotificationBanner.types.d.ts +0 -12
- package/dist/types/components/NotificationBanner/index.d.ts +0 -1
- package/dist/types/components/PDFViewer/ObjectToQueryString.d.ts +0 -1
- package/dist/types/components/PDFViewer/PDFViewer.d.ts +0 -4
- package/dist/types/components/PDFViewer/PDFViewer.types.d.ts +0 -25
- package/dist/types/components/PDFViewer/PDFViewerBackend.d.ts +0 -2
- package/dist/types/components/PDFViewer/ResolvePDFSource.d.ts +0 -27
- package/dist/types/components/PDFViewer/Slugify.d.ts +0 -1
- package/dist/types/components/PDFViewer/index.d.ts +0 -2
- package/dist/types/components/PDFViewer/testutilities/SampleBase64.d.ts +0 -44
- package/dist/types/components/PDFViewerCanvas/PDFViewerCanvas.d.ts +0 -9
- package/dist/types/components/PDFViewerCanvas/PDFViewerCanvas.types.d.ts +0 -8
- package/dist/types/components/PDFViewerCanvas/index.d.ts +0 -1
- package/dist/types/components/Pagination/NavigationButton.d.ts +0 -3
- package/dist/types/components/Pagination/Pagination.d.ts +0 -4
- package/dist/types/components/Pagination/Pagination.types.d.ts +0 -32
- package/dist/types/components/Pagination/SvgIcon.d.ts +0 -3
- package/dist/types/components/Pagination/UsePagination.d.ts +0 -9
- package/dist/types/components/Pagination/index.d.ts +0 -3
- package/dist/types/components/Panel/Panel.d.ts +0 -4
- package/dist/types/components/Panel/Panel.types.d.ts +0 -7
- package/dist/types/components/Panel/index.d.ts +0 -1
- package/dist/types/components/PasswordInput/PasswordInput.config.d.ts +0 -1
- package/dist/types/components/PasswordInput/PasswordInput.d.ts +0 -4
- package/dist/types/components/PasswordInput/PasswordInput.types.d.ts +0 -49
- package/dist/types/components/PasswordInput/index.d.ts +0 -2
- package/dist/types/components/PhaseBanner/PhaseBanner.d.ts +0 -4
- package/dist/types/components/PhaseBanner/PhaseBanner.types.d.ts +0 -6
- package/dist/types/components/PhaseBanner/index.d.ts +0 -1
- package/dist/types/components/ProblemWithService/ProblemWithService.d.ts +0 -4
- package/dist/types/components/ProblemWithService/ProblemWithService.types.d.ts +0 -7
- package/dist/types/components/ProblemWithService/index.d.ts +0 -1
- package/dist/types/components/Radios/Radios.config.d.ts +0 -1
- package/dist/types/components/Radios/Radios.d.ts +0 -4
- package/dist/types/components/Radios/Radios.types.d.ts +0 -7
- package/dist/types/components/Radios/index.d.ts +0 -2
- package/dist/types/components/Select/Select.d.ts +0 -4
- package/dist/types/components/Select/Select.types.d.ts +0 -21
- package/dist/types/components/Select/index.d.ts +0 -1
- package/dist/types/components/ServiceNavigation/ServiceNavigation.d.ts +0 -4
- package/dist/types/components/ServiceNavigation/ServiceNavigation.types.d.ts +0 -21
- package/dist/types/components/ServiceNavigation/index.d.ts +0 -1
- package/dist/types/components/SkipLink/SkipLink.config.d.ts +0 -1
- package/dist/types/components/SkipLink/SkipLink.d.ts +0 -4
- package/dist/types/components/SkipLink/SkipLink.types.d.ts +0 -5
- package/dist/types/components/SkipLink/index.d.ts +0 -2
- package/dist/types/components/SummaryList/SummaryList.d.ts +0 -4
- package/dist/types/components/SummaryList/SummaryList.types.d.ts +0 -22
- package/dist/types/components/SummaryList/index.d.ts +0 -1
- package/dist/types/components/Table/Table.d.ts +0 -4
- package/dist/types/components/Table/Table.types.d.ts +0 -21
- package/dist/types/components/Table/index.d.ts +0 -1
- package/dist/types/components/Tabs/Tabs.config.d.ts +0 -1
- package/dist/types/components/Tabs/Tabs.d.ts +0 -4
- package/dist/types/components/Tabs/Tabs.types.d.ts +0 -14
- package/dist/types/components/Tabs/index.d.ts +0 -2
- package/dist/types/components/Tag/Tag.d.ts +0 -4
- package/dist/types/components/Tag/Tag.types.d.ts +0 -4
- package/dist/types/components/Tag/index.d.ts +0 -1
- package/dist/types/components/TaskList/TaskList.d.ts +0 -4
- package/dist/types/components/TaskList/TaskList.types.d.ts +0 -21
- package/dist/types/components/TaskList/index.d.ts +0 -1
- package/dist/types/components/Textarea/Textarea.d.ts +0 -4
- package/dist/types/components/Textarea/Textarea.types.d.ts +0 -14
- package/dist/types/components/Textarea/index.d.ts +0 -1
- package/dist/types/components/WarningInfo/WarningInfo.d.ts +0 -4
- package/dist/types/components/WarningInfo/WarningInfo.types.d.ts +0 -8
- package/dist/types/components/WarningInfo/index.d.ts +0 -1
- package/dist/types/components/WarningText/WarningText.d.ts +0 -4
- package/dist/types/components/WarningText/WarningText.types.d.ts +0 -4
- package/dist/types/components/WarningText/index.d.ts +0 -1
- package/dist/types/components/index.d.ts +0 -51
- package/dist/types/dynamics/index.d.ts +0 -3
- package/dist/types/dynamics/types.d.ts +0 -37
- package/dist/types/index.d.ts +0 -1
- package/dist/types/utils/ProcessExampleData.d.ts +0 -3
- package/dist/types/utils/StoriesFromFixtures.d.ts +0 -5
- package/dist/types/utils/TitleCase.d.ts +0 -2
- package/dist/types/utils/WithReference.d.ts +0 -5
- package/dist/types/utils/WithReference.types.d.ts +0 -15
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hmlr/govuk-react-components-library",
|
|
3
|
-
"version": "1.1
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "These are common component use for React applications based on GDS and govuk-frontend",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -24,9 +24,10 @@
|
|
|
24
24
|
"storybook": "storybook dev -p 6006 --debug-webpack",
|
|
25
25
|
"build-storybook": "storybook build --debug-webpack",
|
|
26
26
|
"test-storybook": "test-storybook",
|
|
27
|
-
"
|
|
28
|
-
"lint
|
|
27
|
+
"format:check": "prettier --ignore-path .gitignore --check '**/*.+(js|mjs|ts|tsx|json|css|scss|html|md)'",
|
|
28
|
+
"lint": "eslint 'src/**/*.ts*' && npm run format:check && stylelint 'src/**/*.{css,scss,less}'",
|
|
29
29
|
"format": "prettier --ignore-path .gitignore --write '**/*.+(js|mjs|ts|tsx|json|css|scss|html|md)'",
|
|
30
|
+
"lint-fix": "eslint --fix 'src/**/*.ts*' && npm run format && stylelint --fix 'src/**/*.{css,scss,less}' ",
|
|
30
31
|
"prepare": "husky",
|
|
31
32
|
"release": "standard-version",
|
|
32
33
|
"uml": "tsuml2 --glob './src/**/\\!(*.spec|*.test|TestUtilities|JestSetup).[t]s?(x)' -o './assets/uml-diagram.svg'",
|
|
@@ -55,12 +56,12 @@
|
|
|
55
56
|
"license": "MIT",
|
|
56
57
|
"devDependencies": {
|
|
57
58
|
"@babel/core": "^7.29.0",
|
|
58
|
-
"@babel/preset-env": "^7.29.
|
|
59
|
+
"@babel/preset-env": "^7.29.2",
|
|
59
60
|
"@babel/preset-react": "^7.28.5",
|
|
60
61
|
"@babel/preset-typescript": "^7.28.5",
|
|
61
|
-
"@chromatic-com/storybook": "^5.
|
|
62
|
-
"@commitlint/cli": "^20.
|
|
63
|
-
"@commitlint/config-conventional": "^20.
|
|
62
|
+
"@chromatic-com/storybook": "^5.1.1",
|
|
63
|
+
"@commitlint/cli": "^20.5.0",
|
|
64
|
+
"@commitlint/config-conventional": "^20.5.0",
|
|
64
65
|
"@eslint/js": "^9.37.0",
|
|
65
66
|
"@jest/globals": "^30.3.0",
|
|
66
67
|
"@rollup/plugin-commonjs": "^29.0.2",
|
|
@@ -68,34 +69,31 @@
|
|
|
68
69
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
69
70
|
"@rollup/plugin-terser": "^1.0.0",
|
|
70
71
|
"@rollup/plugin-typescript": "^12.3.0",
|
|
71
|
-
"@storybook/addon-a11y": "^10.
|
|
72
|
-
"@storybook/addon-links": "^10.
|
|
73
|
-
"@storybook/addon-styling-webpack": "^3.0.
|
|
74
|
-
"@storybook/addon-webpack5-compiler-swc": "^4.0.
|
|
75
|
-
"@storybook/
|
|
76
|
-
"@storybook/react-
|
|
77
|
-
"@storybook/
|
|
78
|
-
"@storybook/test-runner": "^0.24.2",
|
|
72
|
+
"@storybook/addon-a11y": "^10.3.3",
|
|
73
|
+
"@storybook/addon-links": "^10.3.3",
|
|
74
|
+
"@storybook/addon-styling-webpack": "^3.0.1",
|
|
75
|
+
"@storybook/addon-webpack5-compiler-swc": "^4.0.3",
|
|
76
|
+
"@storybook/react-vite": "^10.3.3",
|
|
77
|
+
"@storybook/react-webpack5": "^10.3.3",
|
|
78
|
+
"@storybook/test-runner": "^0.24.3",
|
|
79
79
|
"@testing-library/jest-dom": "^6.9.1",
|
|
80
80
|
"@testing-library/react": "^16.3.2",
|
|
81
81
|
"@types/govuk-frontend": "^5.11.0",
|
|
82
82
|
"@types/jest": "^30.0.0",
|
|
83
83
|
"@types/react": "^19.2.14",
|
|
84
84
|
"@types/react-dom": "^19.2.3",
|
|
85
|
-
"@typescript-eslint/eslint-plugin": "^8.46.0",
|
|
86
|
-
"@typescript-eslint/parser": "^8.57.0",
|
|
87
85
|
"assert": "^2.1.0",
|
|
88
86
|
"autoprefixer": "^10.4.27",
|
|
89
87
|
"babel-jest": "^30.3.0",
|
|
90
88
|
"bootstrap": "^5.3.8",
|
|
91
|
-
"chromatic": "^
|
|
89
|
+
"chromatic": "^16.0.0",
|
|
92
90
|
"css-loader": "^7.1.4",
|
|
93
91
|
"deep-iterator": "^1.1.0",
|
|
94
92
|
"eslint": "^9.37.0",
|
|
95
93
|
"eslint-plugin-react": "^7.37.5",
|
|
96
|
-
"eslint-plugin-storybook": "^10.
|
|
94
|
+
"eslint-plugin-storybook": "^10.3.3",
|
|
97
95
|
"globals": "^17.4.0",
|
|
98
|
-
"govuk-frontend": "^
|
|
96
|
+
"govuk-frontend": "^6.1.0",
|
|
99
97
|
"html-react-parser": "^5.2.17",
|
|
100
98
|
"husky": "^9.1.7",
|
|
101
99
|
"identity-obj-proxy": "^3.0.0",
|
|
@@ -109,32 +107,32 @@
|
|
|
109
107
|
"react-bootstrap": "^2.10.10",
|
|
110
108
|
"react-dom": "^19.2.4",
|
|
111
109
|
"react-element-to-jsx-string": "^17.0.1",
|
|
112
|
-
"react-router": "^7.13.
|
|
113
|
-
"react-router-dom": "^7.13.
|
|
110
|
+
"react-router": "^7.13.2",
|
|
111
|
+
"react-router-dom": "^7.13.2",
|
|
114
112
|
"rimraf": "^6.1.3",
|
|
115
|
-
"rollup": "^4.
|
|
113
|
+
"rollup": "^4.60.0",
|
|
116
114
|
"rollup-plugin-analyzer": "^4.0.0",
|
|
117
|
-
"rollup-plugin-dts": "^6.4.
|
|
115
|
+
"rollup-plugin-dts": "^6.4.1",
|
|
118
116
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
119
117
|
"rollup-plugin-postcss": "^4.0.2",
|
|
120
118
|
"rollup-plugin-visualizer": "^6.0.4",
|
|
121
119
|
"sass": "^1.98.0",
|
|
122
120
|
"sass-loader": "^16.0.7",
|
|
123
121
|
"standard-version": "^9.5.0",
|
|
124
|
-
"storybook": "^10.
|
|
122
|
+
"storybook": "^10.3.3",
|
|
125
123
|
"style-loader": "^4.0.0",
|
|
126
|
-
"stylelint": "^17.
|
|
127
|
-
"stylelint-config-recess-order": "^7.
|
|
124
|
+
"stylelint": "^17.6.0",
|
|
125
|
+
"stylelint-config-recess-order": "^7.7.0",
|
|
128
126
|
"stylelint-config-standard": "^40.0.0",
|
|
129
127
|
"stylelint-config-standard-scss": "^17.0.0",
|
|
130
128
|
"stylelint-order": "^7.0.1",
|
|
131
129
|
"tslib": "^2.8.1",
|
|
132
130
|
"tsuml2": "^0.17.1",
|
|
133
131
|
"typescript": "^5.9.3",
|
|
134
|
-
"typescript-eslint": "^8.57.
|
|
132
|
+
"typescript-eslint": "^8.57.2",
|
|
135
133
|
"unplugin": "^3.0.0",
|
|
136
134
|
"webpack": "^5.105.4",
|
|
137
|
-
"@storybook/addon-docs": "^10.
|
|
135
|
+
"@storybook/addon-docs": "^10.3.3"
|
|
138
136
|
},
|
|
139
137
|
"peerDependencies": {
|
|
140
138
|
"govuk-frontend": ">=5.14.0",
|
|
@@ -156,10 +156,10 @@ function buildConfigFileCustomisation(componentName) {
|
|
|
156
156
|
React.useEffect(() => {
|
|
157
157
|
const isDocsMode = window.location.search.includes("${docsPath}");
|
|
158
158
|
if (isDocsMode && !configured && parameters.initializeConfigurations) {
|
|
159
|
-
${fnName}();
|
|
159
|
+
void ${fnName}();
|
|
160
160
|
configured = true;
|
|
161
161
|
} else if (!isDocsMode) {
|
|
162
|
-
${fnName}();
|
|
162
|
+
void ${fnName}();
|
|
163
163
|
}
|
|
164
164
|
}, []);
|
|
165
165
|
return <Story />;
|
|
@@ -290,7 +290,7 @@ function generateFile(componentName, visibleFixtures) {
|
|
|
290
290
|
`import React from "react";`,
|
|
291
291
|
hasScss ? `import "./${componentName}.scss";` : null,
|
|
292
292
|
`import ${componentName} from "./${componentName}";`,
|
|
293
|
-
`import { Meta, StoryObj } from "@storybook
|
|
293
|
+
`import { Meta, StoryObj } from "@storybook/react";`,
|
|
294
294
|
`import fixtures from "govuk-frontend/dist/govuk/components/${fixtureName}/fixtures.json";`,
|
|
295
295
|
`import { extractShownFixtures } from "../../utils/ProcessExampleData";`,
|
|
296
296
|
`import { ComponentFixture } from "../../dynamics";`,
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as PDFViewerCanvas } from "./components/PDFViewerCanvas/PDFViewerCanvas";
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { AccordionConfig } from "govuk-frontend/dist/govuk/components/accordion/accordion";
|
|
2
|
-
export declare function ConfigureOverallAccordion($scope?: Document | Element, config?: AccordionConfig): void;
|
|
3
|
-
export declare function ExtractAccordionConfigFromAttributes(remainingAttributes: {
|
|
4
|
-
[key: string]: unknown;
|
|
5
|
-
}): AccordionConfig;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { ElementType, HTMLAttributes } from "react";
|
|
2
|
-
export interface AccordionItem {
|
|
3
|
-
reactListKey?: string | number;
|
|
4
|
-
expanded?: boolean;
|
|
5
|
-
heading: {
|
|
6
|
-
children: React.ReactNode;
|
|
7
|
-
};
|
|
8
|
-
summary?: {
|
|
9
|
-
children: React.ReactNode;
|
|
10
|
-
};
|
|
11
|
-
content: {
|
|
12
|
-
children: React.ReactNode;
|
|
13
|
-
};
|
|
14
|
-
}
|
|
15
|
-
export interface AccordionProps extends HTMLAttributes<HTMLDivElement> {
|
|
16
|
-
className?: string;
|
|
17
|
-
headingLevel?: ElementType;
|
|
18
|
-
id?: string;
|
|
19
|
-
items: AccordionItem[];
|
|
20
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { To } from "react-router-dom";
|
|
2
|
-
export interface ActionLinkProps {
|
|
3
|
-
children?: React.ReactNode;
|
|
4
|
-
visuallyHiddenText?: string;
|
|
5
|
-
className?: string;
|
|
6
|
-
href?: string;
|
|
7
|
-
to?: To;
|
|
8
|
-
[key: string]: unknown;
|
|
9
|
-
}
|
|
10
|
-
export interface Action {
|
|
11
|
-
reactListKey?: string;
|
|
12
|
-
[key: string]: unknown;
|
|
13
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as ActionLink } from "./ActionLink";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as BackLink } from "./BackLink";
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { ErrorMessageProps } from "../ErrorMessage/ErrorMessage.types";
|
|
2
|
-
import { FieldsetProps } from "../Fieldset/Fieldset.types";
|
|
3
|
-
import { HintProps } from "../Hint/Hint.types";
|
|
4
|
-
import { LabelProps } from "../Label/Label.types";
|
|
5
|
-
export interface BooleanItem {
|
|
6
|
-
id?: string;
|
|
7
|
-
children?: React.ReactNode;
|
|
8
|
-
hint?: HintProps;
|
|
9
|
-
conditional?: {
|
|
10
|
-
children: React.ReactNode;
|
|
11
|
-
};
|
|
12
|
-
behaviour?: string;
|
|
13
|
-
label?: LabelProps;
|
|
14
|
-
reactListKey?: string | number;
|
|
15
|
-
divider?: string;
|
|
16
|
-
name?: string;
|
|
17
|
-
checked?: boolean;
|
|
18
|
-
value?: string;
|
|
19
|
-
defaultChecked?: boolean;
|
|
20
|
-
[key: string]: unknown;
|
|
21
|
-
}
|
|
22
|
-
export interface BooleanProps {
|
|
23
|
-
className?: string;
|
|
24
|
-
errorMessage?: ErrorMessageProps;
|
|
25
|
-
fieldset?: FieldsetProps;
|
|
26
|
-
formGroup?: {
|
|
27
|
-
className?: string;
|
|
28
|
-
[key: string]: unknown;
|
|
29
|
-
};
|
|
30
|
-
hint?: HintProps;
|
|
31
|
-
idPrefix?: string;
|
|
32
|
-
items?: BooleanItem[];
|
|
33
|
-
controlType: "radios" | "checkboxes";
|
|
34
|
-
name?: string;
|
|
35
|
-
onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
36
|
-
onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
|
|
37
|
-
"aria-describedby"?: string;
|
|
38
|
-
[key: string]: unknown;
|
|
39
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as Boolean } from "./Boolean";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { HTMLAttributes } from "react";
|
|
2
|
-
export interface BreadcrumbItem {
|
|
3
|
-
href?: string;
|
|
4
|
-
to?: string;
|
|
5
|
-
reactListKey?: string | number;
|
|
6
|
-
children: React.ReactNode;
|
|
7
|
-
[key: string]: unknown;
|
|
8
|
-
}
|
|
9
|
-
export interface BreadcrumbsProps extends HTMLAttributes<HTMLDivElement> {
|
|
10
|
-
items?: BreadcrumbItem[];
|
|
11
|
-
className?: string;
|
|
12
|
-
collapseOnMobile?: boolean;
|
|
13
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as Breadcrumbs } from "./Breadcrumbs";
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import React, { AnchorHTMLAttributes, ButtonHTMLAttributes } from "react";
|
|
2
|
-
import { ButtonProps } from "./Button.types";
|
|
3
|
-
declare const Button: React.FC<ButtonProps & ButtonHTMLAttributes<HTMLButtonElement> & AnchorHTMLAttributes<HTMLAnchorElement>>;
|
|
4
|
-
export default Button;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { To } from "react-router-dom";
|
|
2
|
-
export interface ButtonProps {
|
|
3
|
-
element?: string;
|
|
4
|
-
href?: string;
|
|
5
|
-
to?: To;
|
|
6
|
-
isStartButton?: boolean;
|
|
7
|
-
disabled?: boolean;
|
|
8
|
-
className?: string;
|
|
9
|
-
preventDoubleClick?: boolean;
|
|
10
|
-
name?: string;
|
|
11
|
-
type?: string;
|
|
12
|
-
children?: React.ReactNode;
|
|
13
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as CardColumn } from "./CardColumn";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as CardLayout } from "./CardLayout";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { ErrorMessageProps } from "../ErrorMessage/ErrorMessage.types";
|
|
2
|
-
export interface CharacterCountProps {
|
|
3
|
-
id: string;
|
|
4
|
-
className?: string;
|
|
5
|
-
maxlength?: number;
|
|
6
|
-
threshold?: number;
|
|
7
|
-
maxwords?: number;
|
|
8
|
-
errorMessage?: ErrorMessageProps;
|
|
9
|
-
countMessage?: {
|
|
10
|
-
className?: string;
|
|
11
|
-
};
|
|
12
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as CharacterCount } from "./CharacterCount";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function ConfigureOverallCheckboxes($scope?: Document | Element): void;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
export interface CookieBannerMessageAction {
|
|
3
|
-
className?: string;
|
|
4
|
-
href?: string;
|
|
5
|
-
to?: string;
|
|
6
|
-
children?: React.ReactNode;
|
|
7
|
-
type?: "submit" | "reset" | "button";
|
|
8
|
-
[key: string]: unknown;
|
|
9
|
-
}
|
|
10
|
-
export interface CookieBannerMessageItem {
|
|
11
|
-
headingChildren?: React.ReactNode;
|
|
12
|
-
children?: React.ReactNode;
|
|
13
|
-
"aria-label"?: string;
|
|
14
|
-
actions?: CookieBannerMessageAction[];
|
|
15
|
-
className?: string;
|
|
16
|
-
[key: string]: unknown;
|
|
17
|
-
}
|
|
18
|
-
export interface CookieBannerProps {
|
|
19
|
-
className?: string;
|
|
20
|
-
messages: CookieBannerMessageItem[];
|
|
21
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as CookieBanner } from "./CookieBanner";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as DataNavigation } from "./DataNavigation";
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { ErrorMessageProps } from "../ErrorMessage/ErrorMessage.types";
|
|
2
|
-
import { FieldsetProps } from "../Fieldset/Fieldset.types";
|
|
3
|
-
import { HintProps } from "../Hint/Hint.types";
|
|
4
|
-
export interface DateInputItem {
|
|
5
|
-
name: string;
|
|
6
|
-
className?: string;
|
|
7
|
-
type?: string;
|
|
8
|
-
label?: string;
|
|
9
|
-
reactListKey?: string | number;
|
|
10
|
-
id?: string;
|
|
11
|
-
pattern?: string;
|
|
12
|
-
inputMode?: "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | "search" | undefined;
|
|
13
|
-
[key: string]: unknown;
|
|
14
|
-
}
|
|
15
|
-
export interface DateInputProps {
|
|
16
|
-
className?: string;
|
|
17
|
-
errorMessage?: ErrorMessageProps;
|
|
18
|
-
fieldset?: FieldsetProps;
|
|
19
|
-
formGroup?: {
|
|
20
|
-
className?: string;
|
|
21
|
-
[key: string]: unknown;
|
|
22
|
-
};
|
|
23
|
-
hint?: HintProps;
|
|
24
|
-
id?: string;
|
|
25
|
-
items?: Array<DateInputItem>;
|
|
26
|
-
namePrefix?: string;
|
|
27
|
-
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
28
|
-
[key: string]: unknown;
|
|
29
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as DateInput } from "./DateInput";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as Details } from "./Details";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as DifferenceNavigation } from "./DifferenceNavigation";
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React, { Component, ReactNode } from "react";
|
|
2
|
-
import { ErrorBoundaryProps, ErrorBoundaryState } from "./ErrorBoundary.types";
|
|
3
|
-
declare class ErrorBoundary extends Component<ErrorBoundaryProps, ErrorBoundaryState> {
|
|
4
|
-
constructor(props: ErrorBoundaryProps);
|
|
5
|
-
static getDerivedStateFromError(): Partial<ErrorBoundaryState>;
|
|
6
|
-
componentDidCatch(error: Error, info: React.ErrorInfo): void;
|
|
7
|
-
render(): ReactNode;
|
|
8
|
-
}
|
|
9
|
-
export default ErrorBoundary;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as ErrorBoundary } from "./ErrorBoundary";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as ErrorMessage } from "./ErrorMessage";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { HTMLAttributes } from "react";
|
|
2
|
-
export interface ErrorSummaryProps extends HTMLAttributes<HTMLDivElement> {
|
|
3
|
-
className?: string;
|
|
4
|
-
descriptionChildren?: React.ReactNode;
|
|
5
|
-
errorList?: Array<{
|
|
6
|
-
reactListKey?: string | number;
|
|
7
|
-
children: React.ReactNode;
|
|
8
|
-
href?: string;
|
|
9
|
-
[key: string]: unknown;
|
|
10
|
-
}>;
|
|
11
|
-
titleChildren?: React.ReactNode;
|
|
12
|
-
disableAutoFocus?: boolean;
|
|
13
|
-
}
|