@conduction/components 2.1.19 → 2.1.20

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.
Files changed (66) hide show
  1. package/.github/workflows/github-actions.yml +26 -0
  2. package/.nvmrc +1 -0
  3. package/README.md +19 -18
  4. package/lib/components/badgeCounter/BadgeCounter.d.ts +1 -1
  5. package/lib/components/badgeCounter/BadgeCounter.js +1 -1
  6. package/lib/components/card/detailsCard/DetailsCard.d.ts +2 -2
  7. package/lib/components/card/downloadCard/DownloadCard.d.ts +2 -2
  8. package/lib/components/card/horizontalImageCard/HorizontalImageCard.d.ts +2 -2
  9. package/lib/components/card/imageAndDetailsCard/ImageAndDetailsCard.d.ts +2 -2
  10. package/lib/components/card/infoCard/InfoCard.d.ts +2 -2
  11. package/lib/components/card/richContentCard/RichContentCard.d.ts +2 -2
  12. package/lib/components/codeBlock/CodeBlock.d.ts +2 -2
  13. package/lib/components/container/Container.d.ts +1 -1
  14. package/lib/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.d.ts +2 -2
  15. package/lib/components/denhaag-wrappers/pagination/Pagination.d.ts +2 -2
  16. package/lib/components/editableTableRow/EditableTableRow.d.ts +2 -2
  17. package/lib/components/formFields/checkbox/checkbox.d.ts +1 -1
  18. package/lib/components/formFields/createKeyValue/CreateKeyValue.d.ts +2 -2
  19. package/lib/components/formFields/date/Date.d.ts +2 -2
  20. package/lib/components/formFields/radio.d.ts +1 -1
  21. package/lib/components/formFields/select/select.d.ts +4 -4
  22. package/lib/components/formFields/textarea.d.ts +2 -2
  23. package/lib/components/formFields/textarea.js +1 -1
  24. package/lib/components/imageDivider/ImageDivider.d.ts +2 -2
  25. package/lib/components/logo/Logo.d.ts +3 -3
  26. package/lib/components/metaIcon/MetaIcon.d.ts +2 -2
  27. package/lib/components/notificationPopUp/NotificationPopUp.d.ts +2 -2
  28. package/lib/components/privateRoute/PrivateRoute.d.ts +1 -1
  29. package/lib/components/quoteWrapper/QuoteWrapper.d.ts +1 -1
  30. package/lib/components/quoteWrapper/QuoteWrapper.js +1 -1
  31. package/lib/components/statusSteps/StatusSteps.d.ts +2 -2
  32. package/lib/components/tag/Tag.d.ts +2 -2
  33. package/lib/components/toolTip/ToolTip.d.ts +1 -1
  34. package/lib/components/topNav/primaryTopNav/PrimaryTopNav.d.ts +2 -2
  35. package/lib/components/topNav/secondaryTopNav/SecondaryTopNav.d.ts +2 -2
  36. package/lib/index.d.ts +1 -1
  37. package/package.json +9 -2
  38. package/src/components/badgeCounter/BadgeCounter.tsx +5 -1
  39. package/src/components/card/detailsCard/DetailsCard.tsx +2 -2
  40. package/src/components/card/downloadCard/DownloadCard.tsx +2 -2
  41. package/src/components/card/horizontalImageCard/HorizontalImageCard.tsx +2 -2
  42. package/src/components/card/imageAndDetailsCard/ImageAndDetailsCard.tsx +2 -2
  43. package/src/components/card/infoCard/InfoCard.tsx +1 -1
  44. package/src/components/card/richContentCard/RichContentCard.tsx +4 -4
  45. package/src/components/codeBlock/CodeBlock.tsx +1 -1
  46. package/src/components/container/Container.tsx +1 -1
  47. package/src/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.tsx +3 -3
  48. package/src/components/denhaag-wrappers/pagination/Pagination.tsx +4 -4
  49. package/src/components/editableTableRow/EditableTableRow.tsx +6 -6
  50. package/src/components/formFields/checkbox/checkbox.tsx +2 -2
  51. package/src/components/formFields/createKeyValue/CreateKeyValue.tsx +3 -3
  52. package/src/components/formFields/date/Date.tsx +2 -2
  53. package/src/components/formFields/radio.tsx +2 -2
  54. package/src/components/formFields/select/select.tsx +6 -6
  55. package/src/components/formFields/textarea.tsx +4 -2
  56. package/src/components/imageDivider/ImageDivider.tsx +1 -1
  57. package/src/components/logo/Logo.tsx +2 -2
  58. package/src/components/metaIcon/MetaIcon.tsx +1 -1
  59. package/src/components/notificationPopUp/NotificationPopUp.tsx +2 -2
  60. package/src/components/privateRoute/PrivateRoute.tsx +1 -1
  61. package/src/components/quoteWrapper/QuoteWrapper.tsx +5 -1
  62. package/src/components/statusSteps/StatusSteps.tsx +1 -1
  63. package/src/components/tag/Tag.tsx +1 -1
  64. package/src/components/toolTip/ToolTip.tsx +1 -1
  65. package/src/components/topNav/primaryTopNav/PrimaryTopNav.tsx +1 -1
  66. package/src/components/topNav/secondaryTopNav/SecondaryTopNav.tsx +1 -1
@@ -0,0 +1,26 @@
1
+ name: Continuous Delivery
2
+
3
+ on:
4
+ push:
5
+ pull_request:
6
+
7
+ jobs:
8
+ install:
9
+ runs-on: ubuntu-latest
10
+
11
+ steps:
12
+ - name: Checkout branch
13
+ uses: actions/checkout@v3
14
+
15
+ - name: Set up Node.js version
16
+ uses: actions/setup-node@v3
17
+ with:
18
+ node-version: 16
19
+
20
+ - name: Install dependencies
21
+ run: |
22
+ npm ci
23
+
24
+ - name: Build
25
+ run: |
26
+ npm run build
package/.nvmrc ADDED
@@ -0,0 +1 @@
1
+ 16
package/README.md CHANGED
@@ -4,24 +4,25 @@
4
4
 
5
5
  - **Version 2.1 (breaking changes from 2.0.x)**
6
6
 
7
- - 2.1.19: Refactor Tooltip layout.
8
- - 2.1.18: Add default value to Textarea component.
9
- - 2.1.17: Refactor to NotificationPopUp to include layoutClassName.
10
- - 2.1.16: Refactor ToolTip layoutClassName placement.
11
- - 2.1.15: Add InputDate component based on react-datepicker.
12
- - 2.1.14: Refactor checkbox to remove svg errors
13
- - 2.1.13: Refactor components to remove svg errors (e.g. shape-rendering => shapeRendering)
14
- - 2.1.12: Added ToolTip max-width and break-word
15
- - 2.1.11: Added CreateKeyValue component disabled state on delete buttons
16
- - 2.1.10: PrimaryTopNav overflow scroll removed from desktop
17
- - 2.1.8 & 2.1.9: PrimaryTopNav will always show subItems on mobile
18
- - 2.1.7: Add disabled placholders to all Select elements.
19
- - 2.1.6: Add disabled state to CreateKeyValue component
20
- - 2.1.4 & 2.1.5: Remove IInputProps from CreateKeyValue to undo duplicate defaultValue prop
21
- - 2.1.3: Export IKeyValue from CreateKeyValue component.
22
- - 2.1.2: REVERT 2.1.1 and 2.1.0.
23
- - 2.1.1: Deploy issues.
24
- - 2.1.0: InputDate now includes Den Haag InputDate component, requiring react-hook-form controls.
7
+ - 2.1.20: Updated react.fc code and github actions added.
8
+ - 2.1.19: Refactor Tooltip layout.
9
+ - 2.1.18: Add default value to Textarea component.
10
+ - 2.1.17: Refactor to NotificationPopUp to include layoutClassName.
11
+ - 2.1.16: Refactor ToolTip layoutClassName placement.
12
+ - 2.1.15: Add InputDate component based on react-datepicker.
13
+ - 2.1.14: Refactor checkbox to remove svg errors
14
+ - 2.1.13: Refactor components to remove svg errors (e.g. shape-rendering => shapeRendering)
15
+ - 2.1.12: Added ToolTip max-width and break-word
16
+ - 2.1.11: Added CreateKeyValue component disabled state on delete buttons
17
+ - 2.1.10: PrimaryTopNav overflow scroll removed from desktop
18
+ - 2.1.8 & 2.1.9: PrimaryTopNav will always show subItems on mobile
19
+ - 2.1.7: Add disabled placholders to all Select elements.
20
+ - 2.1.6: Add disabled state to CreateKeyValue component
21
+ - 2.1.4 & 2.1.5: Remove IInputProps from CreateKeyValue to undo duplicate defaultValue prop
22
+ - 2.1.3: Export IKeyValue from CreateKeyValue component.
23
+ - 2.1.2: REVERT 2.1.1 and 2.1.0.
24
+ - 2.1.1: Deploy issues.
25
+ - 2.1.0: InputDate now includes Den Haag InputDate component, requiring react-hook-form controls.
25
26
 
26
27
  - **Version 2**
27
28
 
@@ -4,5 +4,5 @@ interface BadgeCounterProps {
4
4
  children: React.ReactNode;
5
5
  layoutClassName?: string;
6
6
  }
7
- export declare const BadgeCounter: React.FC<BadgeCounterProps>;
7
+ export declare const BadgeCounter: ({ number, children, layoutClassName, }: React.PropsWithChildren<BadgeCounterProps>) => JSX.Element;
8
8
  export {};
@@ -1,4 +1,4 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import * as styles from "./BadgeCounter.module.css";
3
3
  import clsx from "clsx";
4
- export const BadgeCounter = ({ number, children, layoutClassName }) => (_jsxs("div", { className: styles.content, children: [children, _jsx("span", { className: clsx([layoutClassName && layoutClassName], styles.badge), children: number })] }));
4
+ export const BadgeCounter = ({ number, children, layoutClassName, }) => (_jsxs("div", { className: styles.content, children: [children, _jsx("span", { className: clsx([layoutClassName && layoutClassName], styles.badge), children: number })] }));
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface DetailsCardProps {
3
3
  title: string;
4
4
  introduction?: string;
@@ -10,5 +10,5 @@ interface DetailsCardProps {
10
10
  subHeader?: string;
11
11
  layoutClassName?: string;
12
12
  }
13
- export declare const DetailsCard: React.FC<DetailsCardProps>;
13
+ export declare const DetailsCard: ({ title, subHeader, introduction, link, tags, layoutClassName, }: DetailsCardProps) => JSX.Element;
14
14
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface DownloadCardProps {
3
3
  icon: JSX.Element;
4
4
  label: string;
@@ -7,5 +7,5 @@ interface DownloadCardProps {
7
7
  layoutClassName?: string;
8
8
  handleClick: () => any;
9
9
  }
10
- export declare const DownloadCard: React.FC<DownloadCardProps>;
10
+ export declare const DownloadCard: ({ icon, label, sizeKb, layoutClassName, downloadLabel, handleClick, }: DownloadCardProps) => JSX.Element;
11
11
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface HorizontalImageCardProps {
3
3
  iconOrImage: JSX.Element;
4
4
  title: string;
@@ -9,5 +9,5 @@ interface HorizontalImageCardProps {
9
9
  layoutClassName?: string;
10
10
  external?: boolean;
11
11
  }
12
- export declare const HorizontalImageCard: React.FC<HorizontalImageCardProps>;
12
+ export declare const HorizontalImageCard: ({ title, layoutClassName, external, link, iconOrImage, }: HorizontalImageCardProps) => JSX.Element;
13
13
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface ImageAndDetailsCardProps {
3
3
  title: string;
4
4
  image: JSX.Element;
@@ -10,5 +10,5 @@ interface ImageAndDetailsCardProps {
10
10
  subHeader?: string;
11
11
  layoutClassName?: string;
12
12
  }
13
- export declare const ImageAndDetailsCard: React.FC<ImageAndDetailsCardProps>;
13
+ export declare const ImageAndDetailsCard: ({ image, title, subHeader, introduction, link, layoutClassName, }: ImageAndDetailsCardProps) => JSX.Element;
14
14
  export {};
@@ -1,8 +1,8 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface InfoCardProps {
3
3
  title: string;
4
4
  content: JSX.Element | string;
5
5
  layoutClassName?: string;
6
6
  }
7
- export declare const InfoCard: React.FC<InfoCardProps>;
7
+ export declare const InfoCard: ({ title, content, layoutClassName }: InfoCardProps) => JSX.Element;
8
8
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  export interface RichContentCardProps {
3
3
  link: {
4
4
  label: string;
@@ -16,4 +16,4 @@ export interface RichContentCardProps {
16
16
  }[];
17
17
  linkIsExternal?: boolean;
18
18
  }
19
- export declare const RichContentCard: React.FC<RichContentCardProps>;
19
+ export declare const RichContentCard: ({ link, labelsWithIcon, tags, contentLinks, linkIsExternal, }: RichContentCardProps) => JSX.Element;
@@ -1,6 +1,6 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface CodeBlockProps {
3
3
  codeBlock: string | JSX.Element;
4
4
  }
5
- export declare const CodeBlock: React.FC<CodeBlockProps>;
5
+ export declare const CodeBlock: ({ codeBlock }: CodeBlockProps) => JSX.Element;
6
6
  export {};
@@ -2,5 +2,5 @@ import * as React from "react";
2
2
  interface ContainerProps {
3
3
  layoutClassName?: string;
4
4
  }
5
- export declare const Container: React.FC<ContainerProps>;
5
+ export declare const Container: ({ children, layoutClassName }: React.PropsWithChildren<ContainerProps>) => JSX.Element;
6
6
  export {};
@@ -5,7 +5,7 @@
5
5
  *
6
6
  * Note: we do not use css modules here due to this component being a wrapper
7
7
  */
8
- import * as React from "react";
8
+ /// <reference types="react" />
9
9
  import "./Breadcrumbs.css";
10
10
  interface BreadcrumbsProps {
11
11
  crumbs: {
@@ -13,5 +13,5 @@ interface BreadcrumbsProps {
13
13
  crumbLabel: string;
14
14
  }[];
15
15
  }
16
- export declare const Breadcrumbs: React.FC<BreadcrumbsProps>;
16
+ export declare const Breadcrumbs: ({ crumbs }: BreadcrumbsProps) => JSX.Element;
17
17
  export {};
@@ -1,9 +1,9 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  import "./Pagination.css";
3
3
  interface PaginationProps {
4
4
  pages: number;
5
5
  currentPage: number;
6
6
  setPage: (page: number) => any;
7
7
  }
8
- export declare const Pagination: React.FC<PaginationProps>;
8
+ export declare const Pagination: ({ pages, currentPage, setPage }: PaginationProps) => JSX.Element;
9
9
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface InputTypes {
3
3
  inputType: "text" | "email";
4
4
  }
@@ -10,5 +10,5 @@ interface EditableTableRowProps {
10
10
  editLabel: string;
11
11
  handleSave: (value: any) => void;
12
12
  }
13
- export declare const EditableTableRow: React.FC<EditableTableRowProps & InputTypes>;
13
+ export declare const EditableTableRow: ({ thead, value, inputType, editLabel, cancelLabel, saveLabel, handleSave, }: EditableTableRowProps & InputTypes) => JSX.Element;
14
14
  export {};
@@ -6,4 +6,4 @@ export interface ICheckboxProps {
6
6
  defaultChecked?: boolean;
7
7
  disabled?: boolean;
8
8
  }
9
- export declare const InputCheckbox: React.FC<ICheckboxProps & IReactHookFormProps>;
9
+ export declare const InputCheckbox: ({ name, validation, register, label, defaultChecked, disabled, }: ICheckboxProps & IReactHookFormProps) => JSX.Element;
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  import { Control, FieldValues } from "react-hook-form";
3
3
  import { IReactHookFormProps } from "../types";
4
4
  /**
@@ -14,5 +14,5 @@ export interface IKeyValue {
14
14
  key: string;
15
15
  value: string;
16
16
  }
17
- export declare const CreateKeyValue: React.FC<CreateKeyValueProps & IReactHookFormProps>;
17
+ export declare const CreateKeyValue: ({ name, errors, control, validation, defaultValue, disabled, }: CreateKeyValueProps & IReactHookFormProps) => JSX.Element;
18
18
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  import "react-datepicker/dist/react-datepicker.css";
3
3
  import { Control, FieldValues } from "react-hook-form";
4
4
  import { IReactHookFormProps } from "../types";
@@ -8,5 +8,5 @@ interface IDateProps {
8
8
  showTimeSelect?: boolean;
9
9
  disabled?: boolean;
10
10
  }
11
- export declare const InputDate: React.FC<IDateProps & IReactHookFormProps>;
11
+ export declare const InputDate: ({ name, errors, control, validation, disabled, }: IDateProps & IReactHookFormProps) => JSX.Element;
12
12
  export {};
@@ -5,5 +5,5 @@ interface IRadioProps {
5
5
  name: string;
6
6
  value: string;
7
7
  }
8
- export declare const InputRadio: React.FC<IRadioProps & IReactHookFormProps>;
8
+ export declare const InputRadio: ({ name, validation, register, label, value, }: IRadioProps & IReactHookFormProps) => JSX.Element;
9
9
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  import { Control, FieldValues } from "react-hook-form";
3
3
  import { IReactHookFormProps } from "../types";
4
4
  interface ISelectProps {
@@ -12,7 +12,7 @@ interface ISelectProps {
12
12
  disabled?: boolean;
13
13
  isClearable?: boolean;
14
14
  }
15
- export declare const SelectMultiple: React.FC<ISelectProps & IReactHookFormProps>;
16
- export declare const SelectCreate: React.FC<ISelectProps & IReactHookFormProps>;
17
- export declare const SelectSingle: React.FC<ISelectProps & IReactHookFormProps>;
15
+ export declare const SelectMultiple: ({ name, options, errors, control, validation, defaultValue, disabled, }: ISelectProps & IReactHookFormProps) => JSX.Element;
16
+ export declare const SelectCreate: ({ name, options, errors, control, validation, defaultValue, disabled, }: ISelectProps & IReactHookFormProps) => JSX.Element;
17
+ export declare const SelectSingle: ({ name, options, errors, control, validation, isClearable, defaultValue, disabled, }: ISelectProps & IReactHookFormProps) => JSX.Element;
18
18
  export {};
@@ -1,8 +1,8 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  import { IReactHookFormProps } from "./types";
3
3
  export interface ITextAreaProps {
4
4
  name: string;
5
5
  disabled?: boolean;
6
6
  defaultValue?: string;
7
7
  }
8
- export declare const Textarea: React.FC<ITextAreaProps & IReactHookFormProps>;
8
+ export declare const Textarea: ({ name, validation, register, errors, disabled, defaultValue, }: ITextAreaProps & IReactHookFormProps) => JSX.Element;
@@ -1,3 +1,3 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { TextArea } from "@gemeente-denhaag/textarea";
3
- export const Textarea = ({ name, validation, register, errors, disabled, defaultValue, }) => _jsx(TextArea, { ...register(name, { ...validation }), ...{ disabled, defaultValue }, invalid: errors[name] });
3
+ export const Textarea = ({ name, validation, register, errors, disabled, defaultValue, }) => (_jsx(TextArea, { ...register(name, { ...validation }), ...{ disabled, defaultValue }, invalid: errors[name] }));
@@ -1,7 +1,7 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface ImageDividerProps {
3
3
  image: string;
4
4
  layoutClassName: string;
5
5
  }
6
- export declare const ImageDivider: React.FC<ImageDividerProps>;
6
+ export declare const ImageDivider: ({ image, layoutClassName }: ImageDividerProps) => JSX.Element;
7
7
  export {};
@@ -1,8 +1,8 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface LogoProps {
3
3
  layoutClassName: string;
4
4
  href?: string;
5
5
  }
6
- export declare const AuthenticatedLogo: React.FC<LogoProps>;
7
- export declare const UnauthenticatedLogo: React.FC<LogoProps>;
6
+ export declare const AuthenticatedLogo: ({ layoutClassName, href }: LogoProps) => JSX.Element;
7
+ export declare const UnauthenticatedLogo: ({ layoutClassName, href }: LogoProps) => JSX.Element;
8
8
  export {};
@@ -1,7 +1,7 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  export interface MetaIconProps {
3
3
  icon: JSX.Element;
4
4
  label: string;
5
5
  value: string;
6
6
  }
7
- export declare const MetaIcon: React.FC<MetaIconProps>;
7
+ export declare const MetaIcon: ({ icon, label, value }: MetaIconProps) => JSX.Element;
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  export interface NotificationPopUpProps {
3
3
  title: string;
4
4
  description: string | JSX.Element;
@@ -18,7 +18,7 @@ export interface NotificationPopUpProps {
18
18
  };
19
19
  layoutClassName?: string;
20
20
  }
21
- export declare const NotificationPopUp: React.FC<NotificationPopUpProps>;
21
+ export declare const NotificationPopUp: ({ title, description, isVisible, hide, primaryButton, secondaryButton, layoutClassName, }: NotificationPopUpProps) => JSX.Element | null;
22
22
  export declare const NotificationPopUpController: () => {
23
23
  isVisible: boolean;
24
24
  show: () => void;
@@ -2,5 +2,5 @@ import React from "react";
2
2
  interface PrivateRouteProps {
3
3
  authenticated: boolean;
4
4
  }
5
- export declare const PrivateRoute: React.FC<PrivateRouteProps>;
5
+ export declare const PrivateRoute: ({ children, authenticated }: React.PropsWithChildren<PrivateRouteProps>) => JSX.Element;
6
6
  export {};
@@ -3,5 +3,5 @@ interface QuoteWrapperProps {
3
3
  borderColor?: string;
4
4
  borderWidth?: string;
5
5
  }
6
- export declare const QuoteWrapper: React.FC<QuoteWrapperProps>;
6
+ export declare const QuoteWrapper: ({ children, borderColor, borderWidth, }: React.PropsWithChildren<QuoteWrapperProps>) => JSX.Element;
7
7
  export {};
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import * as styles from "./QuoteWrapper.module.css";
3
- export const QuoteWrapper = ({ children, borderColor, borderWidth }) => {
3
+ export const QuoteWrapper = ({ children, borderColor, borderWidth, }) => {
4
4
  return (_jsx("div", { style: { borderLeftColor: borderColor, borderLeftWidth: borderWidth }, className: styles.container, children: children }));
5
5
  };
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface IStatusStep {
3
3
  title: string;
4
4
  checked?: boolean;
@@ -9,5 +9,5 @@ interface IStatusStep {
9
9
  interface StatusStepsProps {
10
10
  steps: IStatusStep[];
11
11
  }
12
- export declare const StatusSteps: React.FC<StatusStepsProps>;
12
+ export declare const StatusSteps: ({ steps }: StatusStepsProps) => JSX.Element;
13
13
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface TagProps {
3
3
  label: string;
4
4
  icon?: JSX.Element;
@@ -6,5 +6,5 @@ interface TagProps {
6
6
  remove?: () => any;
7
7
  layoutClassName?: string;
8
8
  }
9
- export declare const Tag: React.FC<TagProps>;
9
+ export declare const Tag: ({ label, icon, onClick, remove, layoutClassName }: TagProps) => JSX.Element;
10
10
  export {};
@@ -5,5 +5,5 @@ interface ToolTipProps {
5
5
  tooltip: string;
6
6
  layoutClassName?: string;
7
7
  }
8
- export declare const ToolTip: React.FC<ToolTipProps>;
8
+ export declare const ToolTip: ({ children, layoutClassName, tooltip }: React.PropsWithChildren<ToolTipProps>) => JSX.Element;
9
9
  export { ReactTooltip };
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface ITopNavItem {
3
3
  label: string;
4
4
  icon?: JSX.Element;
@@ -16,5 +16,5 @@ export interface TopNavProps {
16
16
  mobileLogo?: JSX.Element;
17
17
  layoutClassName?: string;
18
18
  }
19
- export declare const PrimaryTopNav: React.FC<TopNavProps>;
19
+ export declare const PrimaryTopNav: ({ items, mobileLogo, layoutClassName }: TopNavProps) => JSX.Element;
20
20
  export {};
@@ -1,4 +1,4 @@
1
- import * as React from "react";
1
+ /// <reference types="react" />
2
2
  interface TopNavProps {
3
3
  items: {
4
4
  label: string;
@@ -8,5 +8,5 @@ interface TopNavProps {
8
8
  }[];
9
9
  layoutClassName?: string;
10
10
  }
11
- export declare const SecondaryTopNav: React.FC<TopNavProps>;
11
+ export declare const SecondaryTopNav: ({ items, layoutClassName }: TopNavProps) => JSX.Element;
12
12
  export {};
package/lib/index.d.ts CHANGED
@@ -17,7 +17,7 @@ declare const NotificationPopUp: {
17
17
  show: () => void;
18
18
  hide: () => void;
19
19
  };
20
- NotificationPopUp: import("react").FC<import("./components/notificationPopUp/NotificationPopUp").NotificationPopUpProps>;
20
+ NotificationPopUp: ({ title, description, isVisible, hide, primaryButton, secondaryButton, layoutClassName, }: import("./components/notificationPopUp/NotificationPopUp").NotificationPopUpProps) => JSX.Element | null;
21
21
  };
22
22
  import { QuoteWrapper } from "./components/quoteWrapper/QuoteWrapper";
23
23
  import { Pagination } from "./components/denhaag-wrappers/pagination/Pagination";
package/package.json CHANGED
@@ -1,9 +1,10 @@
1
1
  {
2
2
  "name": "@conduction/components",
3
- "version": "2.1.19",
3
+ "version": "2.1.20",
4
4
  "description": "React (Gatsby) components used within the Conduction Skeleton Application (and its implementations)",
5
5
  "main": "lib/index.js",
6
6
  "scripts": {
7
+ "clean": "rimraf lib/",
7
8
  "build": "tsc",
8
9
  "test": "echo \"Error: no test specified\" && exit 1"
9
10
  },
@@ -11,7 +12,12 @@
11
12
  "type": "git",
12
13
  "url": "git+https://github.com/ConductionNL/conduction-components.git"
13
14
  },
14
- "keywords": ["React", "Gatsby", "Conduction", "Components"],
15
+ "keywords": [
16
+ "React",
17
+ "Gatsby",
18
+ "Conduction",
19
+ "Components"
20
+ ],
15
21
  "author": "Conduction B.V.",
16
22
  "license": "ISC",
17
23
  "bugs": {
@@ -42,6 +48,7 @@
42
48
  "@types/react": "^17.0.43",
43
49
  "@types/react-datepicker": "^4.8.0",
44
50
  "@types/react-dom": "^17.0.14",
51
+ "rimraf": "^4.4.0",
45
52
  "tsc-hooks": "^1.1.1",
46
53
  "typescript": "^4.6.3"
47
54
  }
@@ -8,7 +8,11 @@ interface BadgeCounterProps {
8
8
  layoutClassName?: string;
9
9
  }
10
10
 
11
- export const BadgeCounter: React.FC<BadgeCounterProps> = ({ number, children, layoutClassName }) => (
11
+ export const BadgeCounter = ({
12
+ number,
13
+ children,
14
+ layoutClassName,
15
+ }: React.PropsWithChildren<BadgeCounterProps>): JSX.Element => (
12
16
  <div className={styles.content}>
13
17
  {children}
14
18
  <span className={clsx([layoutClassName && layoutClassName], styles.badge)}>{number}</span>
@@ -18,14 +18,14 @@ interface DetailsCardProps {
18
18
  layoutClassName?: string;
19
19
  }
20
20
 
21
- export const DetailsCard: React.FC<DetailsCardProps> = ({
21
+ export const DetailsCard = ({
22
22
  title,
23
23
  subHeader,
24
24
  introduction,
25
25
  link,
26
26
  tags,
27
27
  layoutClassName,
28
- }) => {
28
+ }: DetailsCardProps): JSX.Element => {
29
29
  return (
30
30
  <div className={clsx(styles.container, [layoutClassName && layoutClassName])} onClick={() => navigate(link.href)}>
31
31
  <div className={styles.content}>
@@ -13,14 +13,14 @@ interface DownloadCardProps {
13
13
  handleClick: () => any;
14
14
  }
15
15
 
16
- export const DownloadCard: React.FC<DownloadCardProps> = ({
16
+ export const DownloadCard = ({
17
17
  icon,
18
18
  label,
19
19
  sizeKb,
20
20
  layoutClassName,
21
21
  downloadLabel,
22
22
  handleClick,
23
- }) => {
23
+ }: DownloadCardProps): JSX.Element => {
24
24
  return (
25
25
  <div className={clsx(styles.container, [layoutClassName && layoutClassName])}>
26
26
  <div className={styles.content}>
@@ -16,13 +16,13 @@ interface HorizontalImageCardProps {
16
16
  external?: boolean;
17
17
  }
18
18
 
19
- export const HorizontalImageCard: React.FC<HorizontalImageCardProps> = ({
19
+ export const HorizontalImageCard = ({
20
20
  title,
21
21
  layoutClassName,
22
22
  external,
23
23
  link,
24
24
  iconOrImage,
25
- }) => {
25
+ }: HorizontalImageCardProps): JSX.Element => {
26
26
  return (
27
27
  <div className={clsx(styles.container, [layoutClassName && layoutClassName])} onClick={() => navigate(link.href)}>
28
28
  <div className={styles.imageOrIconContainer}>{iconOrImage}</div>
@@ -17,14 +17,14 @@ interface ImageAndDetailsCardProps {
17
17
  layoutClassName?: string;
18
18
  }
19
19
 
20
- export const ImageAndDetailsCard: React.FC<ImageAndDetailsCardProps> = ({
20
+ export const ImageAndDetailsCard = ({
21
21
  image,
22
22
  title,
23
23
  subHeader,
24
24
  introduction,
25
25
  link,
26
26
  layoutClassName,
27
- }) => {
27
+ }: ImageAndDetailsCardProps): JSX.Element => {
28
28
  return (
29
29
  <div className={clsx(styles.container, [layoutClassName && layoutClassName])} onClick={() => navigate(link.href)}>
30
30
  <div className={styles.image}>{image}</div>
@@ -8,7 +8,7 @@ interface InfoCardProps {
8
8
  layoutClassName?: string;
9
9
  }
10
10
 
11
- export const InfoCard: React.FC<InfoCardProps> = ({ title, content, layoutClassName }) => {
11
+ export const InfoCard = ({ title, content, layoutClassName }: InfoCardProps): JSX.Element => {
12
12
  return (
13
13
  <div className={clsx([layoutClassName && layoutClassName], styles.container)}>
14
14
  <span className={styles.title}>{title}</span>
@@ -23,13 +23,13 @@ export interface RichContentCardProps {
23
23
  linkIsExternal?: boolean;
24
24
  }
25
25
 
26
- export const RichContentCard: React.FC<RichContentCardProps> = ({
26
+ export const RichContentCard = ({
27
27
  link,
28
28
  labelsWithIcon,
29
29
  tags,
30
30
  contentLinks,
31
31
  linkIsExternal,
32
- }) => {
32
+ }: RichContentCardProps): JSX.Element => {
33
33
  return (
34
34
  <div className={styles.container}>
35
35
  <div className={styles.link} onClick={() => navigate(link.href)}>
@@ -67,7 +67,7 @@ interface LabelWithIconProps {
67
67
  icon: JSX.Element;
68
68
  }
69
69
 
70
- const LabelWithIcon: React.FC<LabelWithIconProps> = ({ label, icon }) => {
70
+ const LabelWithIcon = ({ label, icon }: LabelWithIconProps): JSX.Element => {
71
71
  return (
72
72
  <div className={styles.labelWithIcon}>
73
73
  <span className={styles.labelWithIcon_icon}>{icon}</span>
@@ -82,7 +82,7 @@ interface ContentLinkProps {
82
82
  href: string;
83
83
  }
84
84
 
85
- const ContentLink: React.FC<ContentLinkProps> = ({ title, subTitle, href }) => {
85
+ const ContentLink = ({ title, subTitle, href }: ContentLinkProps): JSX.Element => {
86
86
  return (
87
87
  <Link className={styles.contentLink}>
88
88
  <div className={styles.contentLink_content}>
@@ -5,4 +5,4 @@ interface CodeBlockProps {
5
5
  codeBlock: string | JSX.Element;
6
6
  }
7
7
 
8
- export const CodeBlock: React.FC<CodeBlockProps> = ({ codeBlock }) => <div className={styles.code}>{codeBlock}</div>;
8
+ export const CodeBlock = ({ codeBlock }: CodeBlockProps): JSX.Element => <div className={styles.code}>{codeBlock}</div>;
@@ -6,6 +6,6 @@ interface ContainerProps {
6
6
  layoutClassName?: string;
7
7
  }
8
8
 
9
- export const Container: React.FC<ContainerProps> = ({ children, layoutClassName }) => (
9
+ export const Container = ({ children, layoutClassName }: React.PropsWithChildren<ContainerProps>): JSX.Element => (
10
10
  <div className={clsx(styles.container, [layoutClassName && layoutClassName])}>{children}</div>
11
11
  );
@@ -17,7 +17,7 @@ interface BreadcrumbsProps {
17
17
  }[];
18
18
  }
19
19
 
20
- export const Breadcrumbs: React.FC<BreadcrumbsProps> = ({ crumbs }) => {
20
+ export const Breadcrumbs = ({ crumbs }: BreadcrumbsProps): JSX.Element => {
21
21
  return (
22
22
  <nav aria-label="Breadcrumb" className="denhaag-breadcrumb">
23
23
  <ol className="denhaag-breadcrumb__list" itemScope itemType="https://schema.org/BreadcrumbList">
@@ -39,7 +39,7 @@ interface CrumbItemProps {
39
39
  idx: number;
40
40
  }
41
41
 
42
- const CrumbItem: React.FC<CrumbItemProps> = ({ pathname, crumbLabel, idx }) => (
42
+ const CrumbItem = ({ pathname, crumbLabel, idx }: CrumbItemProps): JSX.Element => (
43
43
  <li className="denhaag-breadcrumb__item" itemProp="itemListElement" itemScope itemType="https://schema.org/ListItem">
44
44
  <Link className="denhaag-breadcrumb__link" to={pathname} itemProp="item">
45
45
  <span className="denhaag-breadcrumb__text" itemProp="name">
@@ -66,7 +66,7 @@ const CrumbItem: React.FC<CrumbItemProps> = ({ pathname, crumbLabel, idx }) => (
66
66
  </li>
67
67
  );
68
68
 
69
- const LastCrumbItem: React.FC<CrumbItemProps> = ({ pathname, crumbLabel, idx }) => (
69
+ const LastCrumbItem = ({ pathname, crumbLabel, idx }: CrumbItemProps): JSX.Element => (
70
70
  <li
71
71
  aria-current="page"
72
72
  className="denhaag-breadcrumb__item"
@@ -8,7 +8,7 @@ interface PaginationProps {
8
8
  setPage: (page: number) => any;
9
9
  }
10
10
 
11
- export const Pagination: React.FC<PaginationProps> = ({ pages, currentPage, setPage }) => {
11
+ export const Pagination = ({ pages, currentPage, setPage }: PaginationProps): JSX.Element => {
12
12
  return (
13
13
  <nav className="denhaag-pagination">
14
14
  <PreviousButton previousPage={currentPage > 1 ? currentPage - 1 : undefined} {...{ setPage }} />
@@ -30,7 +30,7 @@ interface LinkProps {
30
30
  current?: boolean;
31
31
  }
32
32
 
33
- const Link: React.FC<LinkProps> = ({ page, current, setPage }) => {
33
+ const Link = ({ page, current, setPage }: LinkProps): JSX.Element => {
34
34
  return (
35
35
  <a
36
36
  aria-current={current && "page"}
@@ -48,7 +48,7 @@ interface PreviousButtonProps {
48
48
  previousPage?: number;
49
49
  }
50
50
 
51
- const PreviousButton: React.FC<PreviousButtonProps> = ({ previousPage, setPage }) => {
51
+ const PreviousButton = ({ previousPage, setPage }: PreviousButtonProps): JSX.Element => {
52
52
  return (
53
53
  <a
54
54
  aria-label="Previous page"
@@ -82,7 +82,7 @@ interface NextButtonProps {
82
82
  nextPage?: number;
83
83
  }
84
84
 
85
- const NextButton: React.FC<NextButtonProps> = ({ nextPage, setPage }) => {
85
+ const NextButton = ({ nextPage, setPage }: NextButtonProps): JSX.Element => {
86
86
  return (
87
87
  <a
88
88
  aria-label="Next page"
@@ -19,7 +19,7 @@ interface EditableTableRowProps {
19
19
  handleSave: (value: any) => void;
20
20
  }
21
21
 
22
- export const EditableTableRow: React.FC<EditableTableRowProps & InputTypes> = ({
22
+ export const EditableTableRow = ({
23
23
  thead,
24
24
  value,
25
25
  inputType,
@@ -27,7 +27,7 @@ export const EditableTableRow: React.FC<EditableTableRowProps & InputTypes> = ({
27
27
  cancelLabel,
28
28
  saveLabel,
29
29
  handleSave,
30
- }) => {
30
+ }: EditableTableRowProps & InputTypes): JSX.Element => {
31
31
  const [editing, setEditing] = React.useState<boolean>(false);
32
32
 
33
33
  return (
@@ -50,7 +50,7 @@ interface RegularTableRowProps {
50
50
  setEditing: React.Dispatch<React.SetStateAction<boolean>>;
51
51
  }
52
52
 
53
- const RegularTableRow: React.FC<RegularTableRowProps> = ({ value, editLabel, setEditing }) => {
53
+ const RegularTableRow = ({ value, editLabel, setEditing }: RegularTableRowProps): JSX.Element => {
54
54
  return (
55
55
  <>
56
56
  <TableCell>{value}</TableCell>
@@ -74,14 +74,14 @@ interface EditingTableRowProps {
74
74
  handleSave: (value: any) => void;
75
75
  }
76
76
 
77
- const EditingTableRow: React.FC<EditingTableRowProps & InputTypes> = ({
77
+ const EditingTableRow = ({
78
78
  value,
79
79
  setEditing,
80
80
  handleSave,
81
81
  inputType,
82
82
  saveLabel,
83
83
  cancelLabel,
84
- }) => {
84
+ }: EditingTableRowProps & InputTypes): JSX.Element => {
85
85
  const {
86
86
  register,
87
87
  handleSubmit,
@@ -128,7 +128,7 @@ interface FormFieldProps {
128
128
  };
129
129
  }
130
130
 
131
- const FormField: React.FC<FormFieldProps & InputTypes> = ({ inputType, value, register, errors }) => {
131
+ const FormField = ({ inputType, value, register, errors }: FormFieldProps & InputTypes): JSX.Element => {
132
132
  switch (inputType) {
133
133
  case "email":
134
134
  return <InputEmail defaultValue={value} {...{ register, errors }} name="value" validation={{ required: true }} />;
@@ -8,14 +8,14 @@ export interface ICheckboxProps {
8
8
  disabled?: boolean;
9
9
  }
10
10
 
11
- export const InputCheckbox: React.FC<ICheckboxProps & IReactHookFormProps> = ({
11
+ export const InputCheckbox = ({
12
12
  name,
13
13
  validation,
14
14
  register,
15
15
  label,
16
16
  defaultChecked,
17
17
  disabled,
18
- }) => (
18
+ }: ICheckboxProps & IReactHookFormProps): JSX.Element => (
19
19
  <div className={styles.container}>
20
20
  <input
21
21
  type="checkbox"
@@ -21,14 +21,14 @@ export interface IKeyValue {
21
21
  value: string;
22
22
  }
23
23
 
24
- export const CreateKeyValue: React.FC<CreateKeyValueProps & IReactHookFormProps> = ({
24
+ export const CreateKeyValue = ({
25
25
  name,
26
26
  errors,
27
27
  control,
28
28
  validation,
29
29
  defaultValue,
30
30
  disabled,
31
- }) => {
31
+ }: CreateKeyValueProps & IReactHookFormProps): JSX.Element => {
32
32
  return (
33
33
  <Controller
34
34
  {...{ control, name, errors }}
@@ -49,7 +49,7 @@ interface CreateKeyValueComponentProps {
49
49
  disabled?: boolean;
50
50
  }
51
51
 
52
- const KeyValueComponent: React.FC<CreateKeyValueComponentProps> = ({ defaultValue, handleChange, disabled }) => {
52
+ const KeyValueComponent = ({ defaultValue, handleChange, disabled }: CreateKeyValueComponentProps): JSX.Element => {
53
53
  const [currentKey, setCurrentKey] = React.useState<string>("");
54
54
  const [currentValue, setCurrentValue] = React.useState<string>("");
55
55
  const [keyValues, setKeyValues] = React.useState<IKeyValue[]>(defaultValue ?? []);
@@ -12,13 +12,13 @@ interface IDateProps {
12
12
  disabled?: boolean;
13
13
  }
14
14
 
15
- export const InputDate: React.FC<IDateProps & IReactHookFormProps> = ({
15
+ export const InputDate = ({
16
16
  name,
17
17
  errors,
18
18
  control,
19
19
  validation,
20
20
  disabled,
21
- }) => {
21
+ }: IDateProps & IReactHookFormProps): JSX.Element => {
22
22
  return (
23
23
  <Controller
24
24
  {...{ control, name }}
@@ -7,13 +7,13 @@ interface IRadioProps {
7
7
  value: string;
8
8
  }
9
9
 
10
- export const InputRadio: React.FC<IRadioProps & IReactHookFormProps> = ({
10
+ export const InputRadio = ({
11
11
  name,
12
12
  validation,
13
13
  register,
14
14
  label,
15
15
  value,
16
- }) => (
16
+ }: IRadioProps & IReactHookFormProps): JSX.Element => (
17
17
  <FormControlLabel
18
18
  input={<input type="radio" {...{ value }} {...register(name, { ...validation })} />}
19
19
  {...{ label }}
@@ -15,7 +15,7 @@ interface ISelectProps {
15
15
  isClearable?: boolean;
16
16
  }
17
17
 
18
- export const SelectMultiple: React.FC<ISelectProps & IReactHookFormProps> = ({
18
+ export const SelectMultiple = ({
19
19
  name,
20
20
  options,
21
21
  errors,
@@ -23,7 +23,7 @@ export const SelectMultiple: React.FC<ISelectProps & IReactHookFormProps> = ({
23
23
  validation,
24
24
  defaultValue,
25
25
  disabled,
26
- }) => {
26
+ }: ISelectProps & IReactHookFormProps): JSX.Element => {
27
27
  return (
28
28
  <Controller
29
29
  {...{ control, name, defaultValue }}
@@ -46,7 +46,7 @@ export const SelectMultiple: React.FC<ISelectProps & IReactHookFormProps> = ({
46
46
  );
47
47
  };
48
48
 
49
- export const SelectCreate: React.FC<ISelectProps & IReactHookFormProps> = ({
49
+ export const SelectCreate = ({
50
50
  name,
51
51
  options,
52
52
  errors,
@@ -54,7 +54,7 @@ export const SelectCreate: React.FC<ISelectProps & IReactHookFormProps> = ({
54
54
  validation,
55
55
  defaultValue,
56
56
  disabled,
57
- }) => {
57
+ }: ISelectProps & IReactHookFormProps): JSX.Element => {
58
58
  return (
59
59
  <Controller
60
60
  {...{ control, name, defaultValue }}
@@ -77,7 +77,7 @@ export const SelectCreate: React.FC<ISelectProps & IReactHookFormProps> = ({
77
77
  );
78
78
  };
79
79
 
80
- export const SelectSingle: React.FC<ISelectProps & IReactHookFormProps> = ({
80
+ export const SelectSingle = ({
81
81
  name,
82
82
  options,
83
83
  errors,
@@ -86,7 +86,7 @@ export const SelectSingle: React.FC<ISelectProps & IReactHookFormProps> = ({
86
86
  isClearable,
87
87
  defaultValue,
88
88
  disabled,
89
- }) => {
89
+ }: ISelectProps & IReactHookFormProps): JSX.Element => {
90
90
  return (
91
91
  <Controller
92
92
  {...{ control, name, defaultValue }}
@@ -8,11 +8,13 @@ export interface ITextAreaProps {
8
8
  defaultValue?: string;
9
9
  }
10
10
 
11
- export const Textarea: React.FC<ITextAreaProps & IReactHookFormProps> = ({
11
+ export const Textarea = ({
12
12
  name,
13
13
  validation,
14
14
  register,
15
15
  errors,
16
16
  disabled,
17
17
  defaultValue,
18
- }) => <TextArea {...register(name, { ...validation })} {...{ disabled, defaultValue }} invalid={errors[name]} />;
18
+ }: ITextAreaProps & IReactHookFormProps): JSX.Element => (
19
+ <TextArea {...register(name, { ...validation })} {...{ disabled, defaultValue }} invalid={errors[name]} />
20
+ );
@@ -7,6 +7,6 @@ interface ImageDividerProps {
7
7
  layoutClassName: string;
8
8
  }
9
9
 
10
- export const ImageDivider: React.FC<ImageDividerProps> = ({ image, layoutClassName }) => {
10
+ export const ImageDivider = ({ image, layoutClassName }: ImageDividerProps): JSX.Element => {
11
11
  return <img src={image} className={clsx(styles.divider, layoutClassName)} />;
12
12
  };
@@ -8,7 +8,7 @@ interface LogoProps {
8
8
  href?: string;
9
9
  }
10
10
 
11
- export const AuthenticatedLogo: React.FC<LogoProps> = ({ layoutClassName, href }) => {
11
+ export const AuthenticatedLogo = ({ layoutClassName, href }: LogoProps): JSX.Element => {
12
12
  return (
13
13
  <Link className={styles.logoContainer} to={href ?? "#"}>
14
14
  <div className={clsx(styles.authenticatedLogo, styles.logo, layoutClassName)} />
@@ -16,7 +16,7 @@ export const AuthenticatedLogo: React.FC<LogoProps> = ({ layoutClassName, href }
16
16
  );
17
17
  };
18
18
 
19
- export const UnauthenticatedLogo: React.FC<LogoProps> = ({ layoutClassName, href }) => {
19
+ export const UnauthenticatedLogo = ({ layoutClassName, href }: LogoProps): JSX.Element => {
20
20
  return (
21
21
  <Link className={styles.logoContainer} to={href ?? "#"}>
22
22
  <div className={clsx(styles.unauthenticatedLogo, styles.logo, layoutClassName)} />
@@ -7,7 +7,7 @@ export interface MetaIconProps {
7
7
  value: string;
8
8
  }
9
9
 
10
- export const MetaIcon: React.FC<MetaIconProps> = ({ icon, label, value }) => (
10
+ export const MetaIcon = ({ icon, label, value }: MetaIconProps): JSX.Element => (
11
11
  <div className={styles.container}>
12
12
  <span className={styles.icon}>{icon}</span>
13
13
 
@@ -25,7 +25,7 @@ export interface NotificationPopUpProps {
25
25
  layoutClassName?: string;
26
26
  }
27
27
 
28
- export const NotificationPopUp: React.FC<NotificationPopUpProps> = ({
28
+ export const NotificationPopUp = ({
29
29
  title,
30
30
  description,
31
31
  isVisible,
@@ -33,7 +33,7 @@ export const NotificationPopUp: React.FC<NotificationPopUpProps> = ({
33
33
  primaryButton,
34
34
  secondaryButton,
35
35
  layoutClassName,
36
- }) => {
36
+ }: NotificationPopUpProps): JSX.Element | null => {
37
37
  const [animationVisible, setAnimationVisible] = React.useState<boolean>(true);
38
38
 
39
39
  const animationDuration = parseInt(styles.animationDuration, 10);
@@ -5,7 +5,7 @@ interface PrivateRouteProps {
5
5
  authenticated: boolean;
6
6
  }
7
7
 
8
- export const PrivateRoute: React.FC<PrivateRouteProps> = ({ children, authenticated }) => {
8
+ export const PrivateRoute = ({ children, authenticated }: React.PropsWithChildren<PrivateRouteProps>): JSX.Element => {
9
9
  const [_authenticated, setAuthenticated] = React.useState<boolean>(false);
10
10
 
11
11
  React.useEffect(() => {
@@ -6,7 +6,11 @@ interface QuoteWrapperProps {
6
6
  borderWidth?: string;
7
7
  }
8
8
 
9
- export const QuoteWrapper: React.FC<QuoteWrapperProps> = ({ children, borderColor, borderWidth }) => {
9
+ export const QuoteWrapper = ({
10
+ children,
11
+ borderColor,
12
+ borderWidth,
13
+ }: React.PropsWithChildren<QuoteWrapperProps>): JSX.Element => {
10
14
  return (
11
15
  <div style={{ borderLeftColor: borderColor, borderLeftWidth: borderWidth }} className={styles.container}>
12
16
  {children}
@@ -25,7 +25,7 @@ interface StatusStepsProps {
25
25
  steps: IStatusStep[];
26
26
  }
27
27
 
28
- export const StatusSteps: React.FC<StatusStepsProps> = ({ steps }) => {
28
+ export const StatusSteps = ({ steps }: StatusStepsProps): JSX.Element => {
29
29
  return (
30
30
  <StepList>
31
31
  {steps.map(({ title, checked, current, expanded, subSteps }, idx) => (
@@ -12,7 +12,7 @@ interface TagProps {
12
12
  layoutClassName?: string;
13
13
  }
14
14
 
15
- export const Tag: React.FC<TagProps> = ({ label, icon, onClick, remove, layoutClassName }) => (
15
+ export const Tag = ({ label, icon, onClick, remove, layoutClassName }: TagProps): JSX.Element => (
16
16
  <div className={remove && styles.tagContainer}>
17
17
  <div
18
18
  className={clsx(
@@ -10,7 +10,7 @@ interface ToolTipProps {
10
10
  layoutClassName?: string;
11
11
  }
12
12
 
13
- export const ToolTip: React.FC<ToolTipProps> = ({ children, layoutClassName, tooltip }) => {
13
+ export const ToolTip = ({ children, layoutClassName, tooltip }: React.PropsWithChildren<ToolTipProps>): JSX.Element => {
14
14
  return (
15
15
  <div className={clsx(styles.wrapper, layoutClassName && layoutClassName)}>
16
16
  <div data-tip={tooltip}>{children}</div>
@@ -24,7 +24,7 @@ export interface TopNavProps {
24
24
  layoutClassName?: string;
25
25
  }
26
26
 
27
- export const PrimaryTopNav: React.FC<TopNavProps> = ({ items, mobileLogo, layoutClassName }) => {
27
+ export const PrimaryTopNav = ({ items, mobileLogo, layoutClassName }: TopNavProps): JSX.Element => {
28
28
  const [isOpen, setIsOpen] = React.useState<boolean>(false);
29
29
 
30
30
  const handleItemClick = (handleClick?: () => any) => {
@@ -8,7 +8,7 @@ interface TopNavProps {
8
8
  layoutClassName?: string;
9
9
  }
10
10
 
11
- export const SecondaryTopNav: React.FC<TopNavProps> = ({ items, layoutClassName }) => {
11
+ export const SecondaryTopNav = ({ items, layoutClassName }: TopNavProps): JSX.Element => {
12
12
  return (
13
13
  <div className={clsx(styles.secondary, layoutClassName && layoutClassName)}>
14
14
  <nav>