@hmlr/govuk-react-components-library 1.0.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/.nvmrc +1 -0
- package/.stylelintrc.json +8 -0
- package/LICENCE +21 -0
- package/README.md +636 -0
- package/assets/Advance-submodule-behaviours.png +0 -0
- package/assets/logo.png +0 -0
- package/assets/uml-diagram.svg +2541 -0
- package/bundle-analysis-main.html +4951 -0
- package/bundle-analysis-pdfvc.html +4949 -0
- package/dist/PDFViewerCanvas.cjs.css +86 -0
- package/dist/PDFViewerCanvas.cjs.js +243 -0
- package/dist/PDFViewerCanvas.cjs.js.map +1 -0
- package/dist/PDFViewerCanvas.d.ts +19 -0
- package/dist/PDFViewerCanvas.esm.css +86 -0
- package/dist/PDFViewerCanvas.esm.js +241 -0
- package/dist/PDFViewerCanvas.esm.js.map +1 -0
- package/dist/index.cjs.css +11962 -0
- package/dist/index.cjs.js +1362 -0
- package/dist/index.cjs.js.map +1 -0
- package/dist/index.d.ts +743 -0
- package/dist/index.esm.css +11962 -0
- package/dist/index.esm.js +1284 -0
- package/dist/index.esm.js.map +1 -0
- package/dist/types/JestSetup.d.ts +1 -0
- package/dist/types/PDFViewerCanvas.d.ts +1 -0
- package/dist/types/components/Accordion/Accordion.config.d.ts +5 -0
- package/dist/types/components/Accordion/Accordion.d.ts +4 -0
- package/dist/types/components/Accordion/Accordion.types.d.ts +20 -0
- package/dist/types/components/Accordion/index.d.ts +2 -0
- package/dist/types/components/ActionLink/ActionLink.d.ts +4 -0
- package/dist/types/components/ActionLink/ActionLink.types.d.ts +13 -0
- package/dist/types/components/ActionLink/index.d.ts +1 -0
- package/dist/types/components/BackLink/BackLink.d.ts +4 -0
- package/dist/types/components/BackLink/BackLink.types.d.ts +9 -0
- package/dist/types/components/BackLink/index.d.ts +1 -0
- package/dist/types/components/Boolean/Boolean.d.ts +4 -0
- package/dist/types/components/Boolean/Boolean.types.d.ts +39 -0
- package/dist/types/components/Boolean/OmitKey.d.ts +5 -0
- package/dist/types/components/Boolean/index.d.ts +1 -0
- package/dist/types/components/Breadcrumbs/Breadcrumbs.d.ts +4 -0
- package/dist/types/components/Breadcrumbs/Breadcrumbs.types.d.ts +13 -0
- package/dist/types/components/Breadcrumbs/index.d.ts +1 -0
- package/dist/types/components/Button/Button.config.d.ts +2 -0
- package/dist/types/components/Button/Button.d.ts +4 -0
- package/dist/types/components/Button/Button.types.d.ts +13 -0
- package/dist/types/components/Button/index.d.ts +2 -0
- package/dist/types/components/CardColumn/CardColumn.d.ts +5 -0
- package/dist/types/components/CardColumn/CardColumn.types.d.ts +5 -0
- package/dist/types/components/CardColumn/index.d.ts +1 -0
- package/dist/types/components/CardLayout/CardLayout.d.ts +4 -0
- package/dist/types/components/CardLayout/CardLayout.types.d.ts +5 -0
- package/dist/types/components/CardLayout/index.d.ts +1 -0
- package/dist/types/components/CharacterCount/CharacterCount.config.d.ts +2 -0
- package/dist/types/components/CharacterCount/CharacterCount.d.ts +4 -0
- package/dist/types/components/CharacterCount/CharacterCount.types.d.ts +12 -0
- package/dist/types/components/CharacterCount/index.d.ts +1 -0
- package/dist/types/components/Checkboxes/Checkboxes.config.d.ts +1 -0
- package/dist/types/components/Checkboxes/Checkboxes.d.ts +4 -0
- package/dist/types/components/Checkboxes/Checkboxes.types.d.ts +3 -0
- package/dist/types/components/Checkboxes/index.d.ts +2 -0
- package/dist/types/components/CookieBanner/CookieBanner.d.ts +4 -0
- package/dist/types/components/CookieBanner/CookieBanner.types.d.ts +21 -0
- package/dist/types/components/CookieBanner/index.d.ts +1 -0
- package/dist/types/components/DataNavigation/DataNavigation.d.ts +4 -0
- package/dist/types/components/DataNavigation/DataNavigation.types.d.ts +9 -0
- package/dist/types/components/DataNavigation/index.d.ts +1 -0
- package/dist/types/components/DateInput/DateInput.d.ts +4 -0
- package/dist/types/components/DateInput/DateInput.types.d.ts +29 -0
- package/dist/types/components/DateInput/index.d.ts +1 -0
- package/dist/types/components/Details/Details.d.ts +4 -0
- package/dist/types/components/Details/Details.types.d.ts +5 -0
- package/dist/types/components/Details/index.d.ts +1 -0
- package/dist/types/components/DifferenceNavigation/DifferenceNavigation.d.ts +4 -0
- package/dist/types/components/DifferenceNavigation/DifferenceNavigation.types.d.ts +7 -0
- package/dist/types/components/DifferenceNavigation/index.d.ts +1 -0
- package/dist/types/components/ErrorBoundary/ErrorBoundary.d.ts +9 -0
- package/dist/types/components/ErrorBoundary/ErrorBoundary.types.d.ts +11 -0
- package/dist/types/components/ErrorBoundary/index.d.ts +1 -0
- package/dist/types/components/ErrorMessage/ErrorMessage.d.ts +4 -0
- package/dist/types/components/ErrorMessage/ErrorMessage.types.d.ts +6 -0
- package/dist/types/components/ErrorMessage/index.d.ts +1 -0
- package/dist/types/components/ErrorSummary/ErrorSummary.config.d.ts +2 -0
- package/dist/types/components/ErrorSummary/ErrorSummary.d.ts +4 -0
- package/dist/types/components/ErrorSummary/ErrorSummary.types.d.ts +13 -0
- package/dist/types/components/ErrorSummary/index.d.ts +2 -0
- package/dist/types/components/Fieldset/Fieldset.d.ts +4 -0
- package/dist/types/components/Fieldset/Fieldset.types.d.ts +12 -0
- package/dist/types/components/Fieldset/index.d.ts +1 -0
- package/dist/types/components/FileUpload/FileUpload.d.ts +4 -0
- package/dist/types/components/FileUpload/FileUpload.types.d.ts +15 -0
- package/dist/types/components/FileUpload/index.d.ts +1 -0
- package/dist/types/components/Footer/Footer.d.ts +4 -0
- package/dist/types/components/Footer/Footer.types.d.ts +33 -0
- package/dist/types/components/Footer/index.d.ts +1 -0
- package/dist/types/components/Header/Header.config.d.ts +1 -0
- package/dist/types/components/Header/Header.d.ts +4 -0
- package/dist/types/components/Header/Header.types.d.ts +28 -0
- package/dist/types/components/Header/index.d.ts +2 -0
- package/dist/types/components/Hint/Hint.d.ts +4 -0
- package/dist/types/components/Hint/Hint.types.d.ts +4 -0
- package/dist/types/components/Hint/index.d.ts +1 -0
- package/dist/types/components/Input/Input.d.ts +4 -0
- package/dist/types/components/Input/Input.types.d.ts +22 -0
- package/dist/types/components/Input/index.d.ts +1 -0
- package/dist/types/components/InsetText/InsetText.d.ts +4 -0
- package/dist/types/components/InsetText/InsetText.types.d.ts +4 -0
- package/dist/types/components/InsetText/index.d.ts +1 -0
- package/dist/types/components/Label/Label.d.ts +4 -0
- package/dist/types/components/Label/Label.types.d.ts +6 -0
- package/dist/types/components/Label/index.d.ts +1 -0
- package/dist/types/components/Landing/Landing.d.ts +4 -0
- package/dist/types/components/Landing/Landing.types.d.ts +4 -0
- package/dist/types/components/Landing/index.d.ts +1 -0
- package/dist/types/components/LinkWithRef/LinkWithRef.d.ts +4 -0
- package/dist/types/components/LinkWithRef/LinkWithRef.types.d.ts +9 -0
- package/dist/types/components/LinkWithRef/index.d.ts +1 -0
- package/dist/types/components/Loading/Loading.d.ts +5 -0
- package/dist/types/components/Loading/Loading.types.d.ts +4 -0
- package/dist/types/components/Loading/index.d.ts +1 -0
- package/dist/types/components/Main/Main.d.ts +4 -0
- package/dist/types/components/Main/Main.types.d.ts +5 -0
- package/dist/types/components/Main/index.d.ts +1 -0
- package/dist/types/components/NotFoundPage/NotFoundPage.d.ts +3 -0
- package/dist/types/components/NotFoundPage/index.d.ts +1 -0
- package/dist/types/components/NotificationBanner/NotificationBanner.config.d.ts +2 -0
- package/dist/types/components/NotificationBanner/NotificationBanner.d.ts +4 -0
- package/dist/types/components/NotificationBanner/NotificationBanner.types.d.ts +12 -0
- package/dist/types/components/NotificationBanner/index.d.ts +1 -0
- package/dist/types/components/PDFViewer/ObjectToQueryString.d.ts +1 -0
- package/dist/types/components/PDFViewer/PDFViewer.d.ts +4 -0
- package/dist/types/components/PDFViewer/PDFViewer.types.d.ts +25 -0
- package/dist/types/components/PDFViewer/PDFViewerBackend.d.ts +2 -0
- package/dist/types/components/PDFViewer/ResolvePDFSource.d.ts +4 -0
- package/dist/types/components/PDFViewer/Slugify.d.ts +1 -0
- package/dist/types/components/PDFViewer/index.d.ts +2 -0
- package/dist/types/components/PDFViewer/testutilities/SampleBase64.d.ts +44 -0
- package/dist/types/components/PDFViewerCanvas/PDFViewerCanvas.d.ts +9 -0
- package/dist/types/components/PDFViewerCanvas/PDFViewerCanvas.types.d.ts +8 -0
- package/dist/types/components/PDFViewerCanvas/index.d.ts +1 -0
- package/dist/types/components/Pagination/NavigationButton.d.ts +3 -0
- package/dist/types/components/Pagination/Pagination.d.ts +4 -0
- package/dist/types/components/Pagination/Pagination.types.d.ts +22 -0
- package/dist/types/components/Pagination/SvgIcon.d.ts +3 -0
- package/dist/types/components/Pagination/UsePagination.d.ts +9 -0
- package/dist/types/components/Pagination/index.d.ts +1 -0
- package/dist/types/components/Panel/Panel.d.ts +4 -0
- package/dist/types/components/Panel/Panel.types.d.ts +7 -0
- package/dist/types/components/Panel/index.d.ts +1 -0
- package/dist/types/components/PhaseBanner/PhaseBanner.d.ts +4 -0
- package/dist/types/components/PhaseBanner/PhaseBanner.types.d.ts +6 -0
- package/dist/types/components/PhaseBanner/index.d.ts +1 -0
- package/dist/types/components/ProblemWithService/ProblemWithService.d.ts +4 -0
- package/dist/types/components/ProblemWithService/ProblemWithService.types.d.ts +7 -0
- package/dist/types/components/ProblemWithService/index.d.ts +1 -0
- package/dist/types/components/Radios/Radios.config.d.ts +1 -0
- package/dist/types/components/Radios/Radios.d.ts +4 -0
- package/dist/types/components/Radios/Radios.types.d.ts +7 -0
- package/dist/types/components/Radios/index.d.ts +2 -0
- package/dist/types/components/Select/Select.d.ts +4 -0
- package/dist/types/components/Select/Select.types.d.ts +21 -0
- package/dist/types/components/Select/index.d.ts +1 -0
- package/dist/types/components/ServiceNavigation/ServiceNavigation.d.ts +4 -0
- package/dist/types/components/ServiceNavigation/ServiceNavigation.types.d.ts +21 -0
- package/dist/types/components/ServiceNavigation/index.d.ts +1 -0
- package/dist/types/components/SkipLink/SkipLink.config.d.ts +1 -0
- package/dist/types/components/SkipLink/SkipLink.d.ts +4 -0
- package/dist/types/components/SkipLink/SkipLink.types.d.ts +5 -0
- package/dist/types/components/SkipLink/index.d.ts +2 -0
- package/dist/types/components/SummaryList/SummaryList.d.ts +4 -0
- package/dist/types/components/SummaryList/SummaryList.types.d.ts +22 -0
- package/dist/types/components/SummaryList/index.d.ts +1 -0
- package/dist/types/components/Table/Table.d.ts +4 -0
- package/dist/types/components/Table/Table.types.d.ts +21 -0
- package/dist/types/components/Table/index.d.ts +1 -0
- package/dist/types/components/Tabs/Tabs.config.d.ts +1 -0
- package/dist/types/components/Tabs/Tabs.d.ts +4 -0
- package/dist/types/components/Tabs/Tabs.types.d.ts +14 -0
- package/dist/types/components/Tabs/index.d.ts +2 -0
- package/dist/types/components/Tag/Tag.d.ts +4 -0
- package/dist/types/components/Tag/Tag.types.d.ts +4 -0
- package/dist/types/components/Tag/index.d.ts +1 -0
- package/dist/types/components/TaskList/TaskList.d.ts +4 -0
- package/dist/types/components/TaskList/TaskList.types.d.ts +21 -0
- package/dist/types/components/TaskList/index.d.ts +1 -0
- package/dist/types/components/Textarea/Textarea.d.ts +4 -0
- package/dist/types/components/Textarea/Textarea.types.d.ts +14 -0
- package/dist/types/components/Textarea/index.d.ts +1 -0
- package/dist/types/components/WarningInfo/WarningInfo.d.ts +4 -0
- package/dist/types/components/WarningInfo/WarningInfo.types.d.ts +8 -0
- package/dist/types/components/WarningInfo/index.d.ts +1 -0
- package/dist/types/components/WarningText/WarningText.d.ts +4 -0
- package/dist/types/components/WarningText/WarningText.types.d.ts +4 -0
- package/dist/types/components/WarningText/index.d.ts +1 -0
- package/dist/types/components/index.d.ts +49 -0
- package/dist/types/dynamics/index.d.ts +3 -0
- package/dist/types/dynamics/types.d.ts +37 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/utils/ProcessExampleData.d.ts +3 -0
- package/dist/types/utils/StoriesFromFixtures.d.ts +5 -0
- package/dist/types/utils/TitleCase.d.ts +2 -0
- package/dist/types/utils/WithReference.d.ts +5 -0
- package/dist/types/utils/WithReference.types.d.ts +10 -0
- package/package.json +180 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface PaginationProps {
|
|
2
|
+
onPageChange: (page: number) => void;
|
|
3
|
+
totalCount: number;
|
|
4
|
+
siblingCount?: number;
|
|
5
|
+
currentPage: number;
|
|
6
|
+
pageSize: number;
|
|
7
|
+
className?: string;
|
|
8
|
+
previousName?: string;
|
|
9
|
+
previousChildren?: React.ReactNode;
|
|
10
|
+
nextName?: string;
|
|
11
|
+
nextChildren?: React.ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export interface SvgIconProps {
|
|
14
|
+
type: string;
|
|
15
|
+
}
|
|
16
|
+
export interface NavigationButtonProps {
|
|
17
|
+
isDisabled: boolean;
|
|
18
|
+
onClick: () => void;
|
|
19
|
+
children?: React.ReactNode;
|
|
20
|
+
name: string;
|
|
21
|
+
type: "next" | "previous";
|
|
22
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const DOTS = "...";
|
|
2
|
+
interface UsePaginationProps {
|
|
3
|
+
totalCount: number;
|
|
4
|
+
pageSize: number;
|
|
5
|
+
siblingCount?: number;
|
|
6
|
+
currentPage: number;
|
|
7
|
+
}
|
|
8
|
+
export declare const UsePagination: ({ totalCount, pageSize, siblingCount, currentPage, }: UsePaginationProps) => (number | string)[] | undefined;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Pagination } from "./Pagination";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Panel } from "./Panel";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as PhaseBanner } from "./PhaseBanner";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ProblemWithService } from "./ProblemWithService";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function ConfigureOverallRadios($scope?: Document | Element): void;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ErrorMessageProps } from "../ErrorMessage/ErrorMessage.types";
|
|
2
|
+
import { HintProps } from "../Hint/Hint.types";
|
|
3
|
+
import { LabelProps } from "../Label/Label.types";
|
|
4
|
+
export interface Option {
|
|
5
|
+
reactListKey?: string | number;
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
[key: string]: unknown;
|
|
8
|
+
}
|
|
9
|
+
export interface SelectProps {
|
|
10
|
+
className?: string;
|
|
11
|
+
"aria-describedby"?: string;
|
|
12
|
+
errorMessage?: ErrorMessageProps;
|
|
13
|
+
formGroup?: {
|
|
14
|
+
className?: string;
|
|
15
|
+
[key: string]: unknown;
|
|
16
|
+
};
|
|
17
|
+
hint?: HintProps;
|
|
18
|
+
id: string;
|
|
19
|
+
items?: Option[];
|
|
20
|
+
label: LabelProps;
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Select } from "./Select";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { To } from "react-router-dom";
|
|
2
|
+
export interface NavigationItem {
|
|
3
|
+
active?: boolean;
|
|
4
|
+
className?: string;
|
|
5
|
+
children?: React.ReactNode;
|
|
6
|
+
href?: string;
|
|
7
|
+
to?: To;
|
|
8
|
+
reactListKey?: string | number;
|
|
9
|
+
[key: string]: unknown;
|
|
10
|
+
}
|
|
11
|
+
export interface ServiceNavigationProps {
|
|
12
|
+
className?: string;
|
|
13
|
+
containerClassName?: string;
|
|
14
|
+
menuButtonLabel?: string;
|
|
15
|
+
navigation?: NavigationItem[];
|
|
16
|
+
navigationClassName?: string;
|
|
17
|
+
navigationLabel?: string;
|
|
18
|
+
serviceName?: string;
|
|
19
|
+
serviceUrlHref?: string;
|
|
20
|
+
serviceUrlTo?: To;
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ServiceNavigation } from "./ServiceNavigation";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function ConfigureOverallSkipLink($scope?: Document | Element): void;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Action } from "../ActionLink/ActionLink.types";
|
|
2
|
+
export interface Row {
|
|
3
|
+
reactListKey?: string;
|
|
4
|
+
key?: {
|
|
5
|
+
className?: string;
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
};
|
|
8
|
+
value?: {
|
|
9
|
+
className?: string;
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
};
|
|
12
|
+
actions?: {
|
|
13
|
+
items: Action[];
|
|
14
|
+
className?: string;
|
|
15
|
+
};
|
|
16
|
+
className?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface SummaryListProps {
|
|
19
|
+
className?: string;
|
|
20
|
+
rows?: Row[];
|
|
21
|
+
[key: string]: unknown;
|
|
22
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as SummaryList } from "./SummaryList";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from "react";
|
|
2
|
+
export interface TableItem {
|
|
3
|
+
className?: string;
|
|
4
|
+
format?: string;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
reactListKey?: string | number;
|
|
7
|
+
[key: string]: unknown;
|
|
8
|
+
}
|
|
9
|
+
export interface TableRow {
|
|
10
|
+
cells: TableItem[];
|
|
11
|
+
reactListKey?: string | number;
|
|
12
|
+
}
|
|
13
|
+
export interface TableProps extends HTMLAttributes<HTMLTableElement> {
|
|
14
|
+
caption?: string;
|
|
15
|
+
captionClassName?: string;
|
|
16
|
+
firstCellIsHeader?: boolean;
|
|
17
|
+
className?: string;
|
|
18
|
+
head?: TableItem[];
|
|
19
|
+
rows?: TableRow[];
|
|
20
|
+
footer?: TableItem[];
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Table } from "./Table";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function ConfigureOverallTabs($scope?: Document | Element): void;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HTMLAttributes } from "react";
|
|
2
|
+
export interface TabItem {
|
|
3
|
+
id?: string;
|
|
4
|
+
label: string;
|
|
5
|
+
panel: HTMLAttributes<HTMLDivElement>;
|
|
6
|
+
[key: string]: unknown;
|
|
7
|
+
}
|
|
8
|
+
export interface TabsProps extends HTMLAttributes<HTMLDivElement> {
|
|
9
|
+
className?: string;
|
|
10
|
+
id: string;
|
|
11
|
+
idPrefix?: string;
|
|
12
|
+
items: TabItem[];
|
|
13
|
+
title?: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Tag } from "./Tag";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { HintProps } from "../Hint/Hint.types";
|
|
3
|
+
export interface TaskListItemProps {
|
|
4
|
+
title: {
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
};
|
|
7
|
+
hint: HintProps;
|
|
8
|
+
status: {
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
tag?: {
|
|
11
|
+
children: React.ReactNode;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
href?: string;
|
|
15
|
+
[key: string]: unknown;
|
|
16
|
+
}
|
|
17
|
+
export interface TaskListProps {
|
|
18
|
+
className?: string;
|
|
19
|
+
idPrefix?: string;
|
|
20
|
+
items: TaskListItemProps[];
|
|
21
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as TaskList } from "./TaskList";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { TextareaHTMLAttributes } from "react";
|
|
2
|
+
import { ErrorMessageProps } from "../ErrorMessage/ErrorMessage.types";
|
|
3
|
+
export interface TextareaProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {
|
|
4
|
+
className?: string;
|
|
5
|
+
"aria-describedby"?: string;
|
|
6
|
+
errorMessage?: ErrorMessageProps;
|
|
7
|
+
formGroup?: {
|
|
8
|
+
className?: string;
|
|
9
|
+
[key: string]: unknown;
|
|
10
|
+
};
|
|
11
|
+
hint?: object;
|
|
12
|
+
label?: object;
|
|
13
|
+
id?: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Textarea } from "./Textarea";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as WarningInfo } from "./WarningInfo";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as WarningText } from "./WarningText";
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
export * from "./Accordion";
|
|
2
|
+
export * from "./ActionLink";
|
|
3
|
+
export * from "./BackLink";
|
|
4
|
+
export * from "./Boolean";
|
|
5
|
+
export * from "./Breadcrumbs";
|
|
6
|
+
export * from "./Button";
|
|
7
|
+
export * from "./CardColumn";
|
|
8
|
+
export * from "./CardLayout";
|
|
9
|
+
export * from "./CharacterCount";
|
|
10
|
+
export * from "./Checkboxes";
|
|
11
|
+
export * from "./CookieBanner";
|
|
12
|
+
export * from "./DataNavigation";
|
|
13
|
+
export * from "./DateInput";
|
|
14
|
+
export * from "./Details";
|
|
15
|
+
export * from "./DifferenceNavigation";
|
|
16
|
+
export * from "./ErrorBoundary";
|
|
17
|
+
export * from "./ErrorMessage";
|
|
18
|
+
export * from "./ErrorSummary";
|
|
19
|
+
export * from "./Fieldset";
|
|
20
|
+
export * from "./FileUpload";
|
|
21
|
+
export * from "./Footer";
|
|
22
|
+
export * from "./Header";
|
|
23
|
+
export * from "./Hint";
|
|
24
|
+
export * from "./Input";
|
|
25
|
+
export * from "./InsetText";
|
|
26
|
+
export * from "./Label";
|
|
27
|
+
export * from "./Landing";
|
|
28
|
+
export * from "./LinkWithRef";
|
|
29
|
+
export * from "./Loading";
|
|
30
|
+
export * from "./Main";
|
|
31
|
+
export * from "./NotFoundPage";
|
|
32
|
+
export * from "./NotificationBanner";
|
|
33
|
+
export * from "./Pagination";
|
|
34
|
+
export * from "./Panel";
|
|
35
|
+
export * from "./PDFViewer";
|
|
36
|
+
export * from "./PhaseBanner";
|
|
37
|
+
export * from "./ProblemWithService";
|
|
38
|
+
export * from "./Radios";
|
|
39
|
+
export * from "./Select";
|
|
40
|
+
export * from "./ServiceNavigation";
|
|
41
|
+
export * from "./SkipLink";
|
|
42
|
+
export * from "./SummaryList";
|
|
43
|
+
export * from "./Table";
|
|
44
|
+
export * from "./Tabs";
|
|
45
|
+
export * from "./Tag";
|
|
46
|
+
export * from "./TaskList";
|
|
47
|
+
export * from "./Textarea";
|
|
48
|
+
export * from "./WarningInfo";
|
|
49
|
+
export * from "./WarningText";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { ArgTypes, Tag } from "@storybook/csf";
|
|
2
|
+
type AnyJson = boolean | number | string | null | Array<AnyJson> | JsonMap | React.ReactNode | undefined;
|
|
3
|
+
interface JsonMap {
|
|
4
|
+
[key: string]: AnyJson;
|
|
5
|
+
}
|
|
6
|
+
interface AnnotationsConfig {
|
|
7
|
+
parameters?: JsonMap;
|
|
8
|
+
args?: JsonMap;
|
|
9
|
+
argTypes?: ArgTypes;
|
|
10
|
+
tags?: Tag[];
|
|
11
|
+
}
|
|
12
|
+
export interface MetaConfig extends AnnotationsConfig {
|
|
13
|
+
title?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface StoryConfig extends AnnotationsConfig {
|
|
16
|
+
name?: string;
|
|
17
|
+
}
|
|
18
|
+
export type StoryConfigs = Record<string, StoryConfig>;
|
|
19
|
+
export interface DynamicConfig {
|
|
20
|
+
baseCsf: string;
|
|
21
|
+
storiesCsf?: string;
|
|
22
|
+
stories?: () => Promise<StoryConfigs> | StoryConfigs;
|
|
23
|
+
}
|
|
24
|
+
export interface ComponentFixture {
|
|
25
|
+
name: string;
|
|
26
|
+
options?: object;
|
|
27
|
+
hidden?: boolean;
|
|
28
|
+
description?: string;
|
|
29
|
+
previewLayoutModifiers?: unknown[];
|
|
30
|
+
screenshot?: boolean;
|
|
31
|
+
html?: string;
|
|
32
|
+
}
|
|
33
|
+
export interface ComponentFixtureRoot {
|
|
34
|
+
component: string;
|
|
35
|
+
fixtures: ComponentFixture[];
|
|
36
|
+
}
|
|
37
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./components";
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ComponentFixture, ComponentFixtureRoot } from "../dynamics";
|
|
2
|
+
export default function processExampleData(data: unknown, componentName: string): Array<ComponentFixture>;
|
|
3
|
+
export declare function extractShownFixtures(fixtures: ComponentFixtureRoot): Array<ComponentFixture>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { ComponentFixtureRoot, StoryConfigs } from "../dynamics";
|
|
2
|
+
export declare function loadFixturesAsJson(fileLocation: string): Promise<any>;
|
|
3
|
+
export declare function storiesFromFixtures(fixtures: ComponentFixtureRoot): StoryConfigs;
|
|
4
|
+
export declare function storiesFromFixturesSCF(fixtures: ComponentFixtureRoot, hasConfig?: boolean): string;
|
|
5
|
+
export declare function createBaseCSF(fixtureName: string, hasConfig?: boolean): string;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
export interface WithRefProps {
|
|
3
|
+
Component: React.ComponentType<unknown>;
|
|
4
|
+
[key: string]: unknown;
|
|
5
|
+
}
|
|
6
|
+
export interface InfoSectionProps {
|
|
7
|
+
refName: string;
|
|
8
|
+
Component: React.ComponentType<unknown>;
|
|
9
|
+
restProps: Record<string, unknown>;
|
|
10
|
+
}
|