Skip to content

Commit cfb7959

Browse files
committed
refactored to use relative imports, as storybook didn't like regular imports
1 parent 5bfb37d commit cfb7959

File tree

9 files changed

+12
-12
lines changed

9 files changed

+12
-12
lines changed

src/components/back-link/BackLink.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from 'react';
22
import classNames from 'classnames';
33
import { ChevronLeft } from '../icons';
4-
import type { AsElementLink } from 'util/types/LinkTypes';
4+
import type { AsElementLink } from '../../util/types/LinkTypes';
55

66
const BackLink: React.FC<AsElementLink<HTMLAnchorElement>> = ({
77
children,

src/components/breadcrumb/Breadcrumb.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import React, { HTMLProps, ReactNode } from 'react';
33
import classNames from 'classnames';
44
import { Container } from '../layout';
5-
import type { AsElementLink } from 'util/types/LinkTypes';
5+
import type { AsElementLink } from '../../util/types/LinkTypes';
66

77
type Item = React.FC<AsElementLink<HTMLAnchorElement>>;
88

src/components/header/components/NHSLogo.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React, { useContext, SVGProps } from 'react';
22
import classNames from 'classnames';
33
import HeaderContext, { IHeaderContext } from '../HeaderContext';
4-
import type { AsElementLink } from 'util/types/LinkTypes';
4+
import type { AsElementLink } from '../../../util/types/LinkTypes';
55

66
interface SVGImageWithSrc extends SVGProps<SVGImageElement> {
77
src: string;

src/components/header/components/NavItem.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from 'react';
22
import classNames from 'classnames';
33
import { ChevronRight as ChevronRightIcon } from '../../icons';
4-
import type { AsElementLink } from 'util/types/LinkTypes';
4+
import type { AsElementLink } from '../../../util/types/LinkTypes';
55

66
export interface NavItemProps extends AsElementLink<HTMLAnchorElement> {
77
mobileOnly?: boolean;

src/components/header/components/OrganisationalLogo.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { useContext } from 'react';
22
import HeaderContext, { IHeaderContext } from '../HeaderContext';
3-
import type { AsElementLink } from 'util/types/LinkTypes';
3+
import type { AsElementLink } from '../../../util/types/LinkTypes';
44

55

66
export interface OrganisationalLogoProps extends AsElementLink<HTMLAnchorElement> {

src/components/list-panel/ListPanel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { HTMLProps } from 'react';
22
import classNames from 'classnames';
3-
import type { AsElementLink } from 'util/types/LinkTypes';
3+
import type { AsElementLink } from '../../util/types/LinkTypes';
44

55

66
interface PanelProps extends HTMLProps<HTMLDivElement> {

src/components/nav-a-z/NavAZ.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { HTMLProps } from 'react';
22
import classNames from 'classnames';
3-
import type { AsElementLink } from 'util/types/LinkTypes';
3+
import type { AsElementLink } from '../../util/types/LinkTypes';
44

55
const alphabet = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
66

src/components/promo/Promo.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import React, { HTMLProps, useContext, isValidElement } from 'react';
22
import classNames from 'classnames';
33
import PromoContext, { PromoContextType } from './PromoContext';
44
import { Col, Row } from '../layout';
5-
import type { AsElementLink } from 'util/types/LinkTypes';
5+
import type { AsElementLink } from '../../util/types/LinkTypes';
66

77
interface ImageProps extends HTMLProps<HTMLImageElement> {
88
crossOrigin?: '' | 'anonymous' | 'use-credentials';

src/util/types/LinkTypes.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { HTMLProps } from "react";
1+
import { HTMLProps } from 'react';
22

33
export interface AsElementLink<T extends HTMLElement> extends HTMLProps<T> {
4-
asElement?: React.ElementType;
5-
to?: string;
6-
}
4+
asElement?: React.ElementType;
5+
to?: string;
6+
}

0 commit comments

Comments
 (0)