@uob-web-and-digital/component-library 0.0.35 → 0.0.37
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/dist/components/atoms/CourseDeliveryPill/CourseDeliveryPill.d.ts +11 -0
- package/dist/components/atoms/CourseDeliveryPill/CourseDeliveryPill.stories.d.ts +11 -0
- package/dist/components/atoms/CourseIcon/CourseIcon.d.ts +10 -0
- package/dist/components/atoms/CourseIcon/CourseIcon.stories.d.ts +12 -0
- package/dist/components/atoms/Icons/Icons.d.ts +1 -1
- package/dist/components/atoms/TextButton/TextButton.d.ts +2 -1
- package/dist/components/atoms/TextButtonWithIcon/TextButtonWithIcon.d.ts +5 -1
- package/dist/components/atoms/VideoPlaceholder/VideoPlaceholder.d.ts +13 -0
- package/dist/components/atoms/VideoPlaceholder/VideoPlaceholder.stories.d.ts +25 -0
- package/dist/components/atoms/VideoPlaceholder/defaultProps.d.ts +2 -0
- package/dist/components/molecules/CardRelatedCourse/CardRelatedCourse.d.ts +14 -0
- package/dist/components/molecules/CardRelatedCourse/CardRelatedCourse.stories.d.ts +13 -0
- package/dist/components/molecules/CardStaff/CardStaff.d.ts +21 -0
- package/dist/components/molecules/CardStaff/CardStaff.stories.d.ts +14 -0
- package/dist/components/molecules/PaginationNumbers/PaginationNumbers.d.ts +9 -0
- package/dist/components/molecules/PaginationNumbers/PaginationNumbers.stories.d.ts +11 -0
- package/dist/components/molecules/VideoWithPlaceholder/VideoWithPlaceholder.d.ts +14 -0
- package/dist/components/molecules/VideoWithPlaceholder/VideoWithPlaceholder.stories.d.ts +26 -0
- package/dist/components/molecules/VideoWithPlaceholder/defaultProps.d.ts +2 -0
- package/dist/components/organisms/AccreditationPromotion/AccreditationPromotion.d.ts +20 -0
- package/dist/components/organisms/AccreditationPromotion/AccreditationPromotion.stories.d.ts +10 -0
- package/dist/components/organisms/AccreditationPromotion/defaultProps.d.ts +2 -0
- package/dist/components/organisms/CTAComponent/CTAComponent.d.ts +20 -0
- package/dist/components/organisms/CTAComponent/CTAComponent.stories.d.ts +11 -0
- package/dist/components/organisms/CTAComponent/defaultProps.d.ts +2 -0
- package/dist/components/organisms/Carousel/Carousel.d.ts +3 -1
- package/dist/components/organisms/ClearingBanner/ClearingBanner.d.ts +12 -0
- package/dist/components/organisms/ClearingBanner/ClearingBanner.stories.d.ts +10 -0
- package/dist/components/organisms/ClearingBanner/defaultProps.d.ts +2 -0
- package/dist/components/organisms/CourseDeliveryPills/CourseDeliveryPills.d.ts +9 -0
- package/dist/components/organisms/CourseDeliveryPills/CourseDeliveryPills.stories.d.ts +10 -0
- package/dist/components/organisms/CourseDeliveryPills/defaultProps.d.ts +2 -0
- package/dist/components/organisms/ListingResultsCount/ListingResultsCount.d.ts +8 -0
- package/dist/components/organisms/ListingResultsCount/ListingResultsCount.stories.d.ts +15 -0
- package/dist/components/organisms/Pagination/Pagination.d.ts +10 -0
- package/dist/components/organisms/Pagination/Pagination.stories.d.ts +12 -0
- package/dist/components/organisms/QuoteBlock/QuoteBlock.d.ts +18 -0
- package/dist/components/organisms/QuoteBlock/QuoteBlock.stories.d.ts +16 -0
- package/dist/components/organisms/QuoteBlock/defatultProps.d.ts +2 -0
- package/dist/components/organisms/RelatedCourses/RelatedCourses.d.ts +11 -0
- package/dist/components/organisms/RelatedCourses/RelatedCourses.stories.d.ts +11 -0
- package/dist/components/organisms/RelatedCourses/defaultProps.d.ts +2 -0
- package/dist/components/organisms/RichText/RichText.d.ts +5 -1
- package/dist/components/organisms/SearchCourses/SearchCourses.d.ts +13 -4
- package/dist/components/organisms/SearchCourses/SearchCourses.stories.d.ts +1 -0
- package/dist/components/organisms/SidebarWrapper/SidebarWrapper.d.ts +11 -0
- package/dist/components/organisms/SidebarWrapper/SidebarWrapper.stories.d.ts +15 -0
- package/dist/components/organisms/SignPost/SignPost.d.ts +5 -1
- package/dist/components/organisms/StaffListingCarousel/StaffListingCarousel.d.ts +13 -0
- package/dist/components/organisms/StaffListingCarousel/StaffListingCarousel.stories.d.ts +11 -0
- package/dist/components/organisms/StaffListingCarousel/defaultProps.d.ts +2 -0
- package/dist/components/organisms/VideoEmbed/VideoEmbed.d.ts +21 -0
- package/dist/components/organisms/VideoEmbed/VideoEmbed.stories.d.ts +17 -0
- package/dist/components/organisms/VideoEmbed/defaultProps.d.ts +2 -0
- package/dist/index.d.ts +254 -13
- package/dist/main.css +1 -1
- package/dist/main.js +5 -5
- package/dist/module.js +5 -5
- package/package.json +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './courseDeliveryPill.scss';
|
|
4
|
+
type IconType = 'person' | 'people' | 'computer' | 'book' | 'briefcase' | 'notepad';
|
|
5
|
+
export interface CourseDeliveryPillProps {
|
|
6
|
+
theme: ThemeProps;
|
|
7
|
+
label: string;
|
|
8
|
+
iconType?: IconType;
|
|
9
|
+
}
|
|
10
|
+
export default function CourseDeliveryPill({ theme, label, iconType }: CourseDeliveryPillProps): ReactElement;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CourseDeliveryPill from './CourseDeliveryPill';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CourseDeliveryPill;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof CourseDeliveryPill>;
|
|
10
|
+
export declare const Default: Story;
|
|
11
|
+
export declare const NoIcon: Story;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { IconType } from '../Icons/Icons';
|
|
4
|
+
import './courseIcon.scss';
|
|
5
|
+
export interface CourseIconProps {
|
|
6
|
+
theme: ThemeProps;
|
|
7
|
+
inverse?: boolean;
|
|
8
|
+
icon: IconType;
|
|
9
|
+
}
|
|
10
|
+
export default function CourseIcon({ theme, inverse, icon }: CourseIconProps): ReactElement;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CourseIcon from './CourseIcon';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CourseIcon;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof meta>;
|
|
10
|
+
export declare const Clearing: Story;
|
|
11
|
+
export declare const Phone: Story;
|
|
12
|
+
export declare const Email: Story;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
2
|
import { ThemeProps } from '../../../themeProps';
|
|
3
3
|
import './icons.scss';
|
|
4
|
-
export type IconType = 'twitter' | 'facebook' | 'wechat' | 'weibo' | 'youtube' | 'instagram' | 'linkedin' | 'tiktok' | 'chevron-down' | 'chevron-right' | 'arrow-right' | 'arrow-right-large' | 'location' | 'hamburger' | 'cross' | 'arrow-left' | 'search' | 'arrow-down' | 'play';
|
|
4
|
+
export type IconType = 'twitter' | 'facebook' | 'wechat' | 'weibo' | 'youtube' | 'instagram' | 'linkedin' | 'tiktok' | 'chevron-down' | 'chevron-right' | 'arrow-right' | 'arrow-right-large' | 'location' | 'hamburger' | 'cross' | 'arrow-left' | 'search' | 'arrow-down' | 'play' | 'person' | 'people' | 'computer' | 'book' | 'briefcase' | 'notepad' | 'external' | 'clearing-tick' | 'phone' | 'email' | 'quote-marks';
|
|
5
5
|
export type IconProps = {
|
|
6
6
|
/**
|
|
7
7
|
* The theme to use
|
|
@@ -25,5 +25,6 @@ export interface TextButtonProps {
|
|
|
25
25
|
* Whether the button is used as a submit button in a form
|
|
26
26
|
*/
|
|
27
27
|
isSubmit?: boolean;
|
|
28
|
+
disabled?: boolean;
|
|
28
29
|
}
|
|
29
|
-
export default function TextButton({ theme, inverse, label, onClick, url, externalLink, hollow, isSubmit }: TextButtonProps): ReactElement;
|
|
30
|
+
export default function TextButton({ theme, inverse, label, onClick, url, externalLink, hollow, isSubmit, disabled }: TextButtonProps): ReactElement;
|
|
@@ -30,5 +30,9 @@ export interface TextButtonWithIconProps {
|
|
|
30
30
|
* The icon to be used
|
|
31
31
|
*/
|
|
32
32
|
icon: IconType;
|
|
33
|
+
/**
|
|
34
|
+
* The icon to be used
|
|
35
|
+
*/
|
|
36
|
+
iconPosition?: 'left' | 'right';
|
|
33
37
|
}
|
|
34
|
-
export default function TextButtonWithIcon({ theme, inverse, label, onClick, url, externalLink, hollow, isSubmit, icon }: TextButtonWithIconProps): ReactElement;
|
|
38
|
+
export default function TextButtonWithIcon({ theme, inverse, label, onClick, url, externalLink, hollow, isSubmit, icon, iconPosition }: TextButtonWithIconProps): ReactElement;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import './videoPlaceholder.scss';
|
|
3
|
+
import { ThemeProps } from '../../../themeProps';
|
|
4
|
+
export interface VideoPlaceholderProps {
|
|
5
|
+
theme: ThemeProps;
|
|
6
|
+
imageSrc: {
|
|
7
|
+
small?: string;
|
|
8
|
+
medium?: string;
|
|
9
|
+
default: string;
|
|
10
|
+
};
|
|
11
|
+
onClick: () => void;
|
|
12
|
+
}
|
|
13
|
+
export default function VideoPlaceholder({ theme, imageSrc, onClick }: VideoPlaceholderProps): ReactElement;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { StoryObj } from '@storybook/react';
|
|
3
|
+
import VideoPlaceholder from './VideoPlaceholder';
|
|
4
|
+
declare const meta: {
|
|
5
|
+
title: string;
|
|
6
|
+
component: typeof VideoPlaceholder;
|
|
7
|
+
tags: string[];
|
|
8
|
+
parameters: {
|
|
9
|
+
backgrounds: {
|
|
10
|
+
default: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
decorators: ((Story: import("@storybook/types").PartialStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
|
|
14
|
+
theme: import("../../../themeProps").ThemeProps;
|
|
15
|
+
imageSrc: {
|
|
16
|
+
small?: string | undefined;
|
|
17
|
+
medium?: string | undefined;
|
|
18
|
+
default: string;
|
|
19
|
+
};
|
|
20
|
+
onClick: () => void;
|
|
21
|
+
}>) => JSX.Element)[];
|
|
22
|
+
};
|
|
23
|
+
export default meta;
|
|
24
|
+
type Story = StoryObj<typeof VideoPlaceholder>;
|
|
25
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './cardRelatedCourse.scss';
|
|
4
|
+
export interface CardRelatedProps {
|
|
5
|
+
theme: ThemeProps;
|
|
6
|
+
inverse?: boolean;
|
|
7
|
+
title: string;
|
|
8
|
+
subtitle: string;
|
|
9
|
+
href: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Primary UI component for user interaction
|
|
13
|
+
*/
|
|
14
|
+
export default function CardRelated({ theme, inverse, title, subtitle, href }: CardRelatedProps): ReactElement;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CardRelatedCourse from './CardRelatedCourse';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CardRelatedCourse;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof CardRelatedCourse>;
|
|
13
|
+
export declare const Example: Story;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ImageProps } from '../../atoms/Image/Image';
|
|
3
|
+
import { ThemeProps } from '../../../themeProps';
|
|
4
|
+
import './cardStaff.scss';
|
|
5
|
+
export interface CardStaffProps {
|
|
6
|
+
theme: ThemeProps;
|
|
7
|
+
inverse?: boolean;
|
|
8
|
+
image: ImageProps;
|
|
9
|
+
name: string;
|
|
10
|
+
jobTitle: string;
|
|
11
|
+
department: string;
|
|
12
|
+
copy: string;
|
|
13
|
+
href: string;
|
|
14
|
+
isSingle?: boolean;
|
|
15
|
+
phone: string;
|
|
16
|
+
email: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Primary UI component for user interaction
|
|
20
|
+
*/
|
|
21
|
+
export default function CardStaff({ theme, inverse, image, name, jobTitle, department, href, copy, phone, email, isSingle }: CardStaffProps): ReactElement;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CardStaff from './CardStaff';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CardStaff;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof CardStaff>;
|
|
13
|
+
export declare const ExampleSingleCard: Story;
|
|
14
|
+
export declare const OneOfManyStaffCards: Story;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
export interface PaginationNumbersProps {
|
|
4
|
+
theme: ThemeProps;
|
|
5
|
+
numOfPages: number;
|
|
6
|
+
onClick: (pageNumber: number) => void;
|
|
7
|
+
currentPage: number;
|
|
8
|
+
}
|
|
9
|
+
export default function PaginationNumbers({ theme, numOfPages, onClick, currentPage }: PaginationNumbersProps): ReactElement;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import PaginationNumbers from './PaginationNumbers';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof PaginationNumbers;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
export declare const FourItems: () => ReactElement;
|
|
10
|
+
export declare const SixItems: () => ReactElement;
|
|
11
|
+
export declare const SevenItems: () => ReactElement;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './videoWithPlaceholder.scss';
|
|
4
|
+
export interface VideoWithPlaceholderProps {
|
|
5
|
+
theme: ThemeProps;
|
|
6
|
+
videoId?: string;
|
|
7
|
+
videoUrl?: string;
|
|
8
|
+
imageSrc: {
|
|
9
|
+
small?: string;
|
|
10
|
+
medium?: string;
|
|
11
|
+
default: string;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export default function VideoWithPlaceholder({ theme, imageSrc, videoUrl, videoId }: VideoWithPlaceholderProps): ReactElement;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { StoryObj } from '@storybook/react';
|
|
3
|
+
import VideoWithPlaceholder from './VideoWithPlaceholder';
|
|
4
|
+
declare const meta: {
|
|
5
|
+
title: string;
|
|
6
|
+
component: typeof VideoWithPlaceholder;
|
|
7
|
+
tags: string[];
|
|
8
|
+
parameters: {
|
|
9
|
+
backgrounds: {
|
|
10
|
+
default: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
decorators: ((Story: import("@storybook/types").PartialStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
|
|
14
|
+
theme: import("../../../themeProps").ThemeProps;
|
|
15
|
+
videoId?: string | undefined;
|
|
16
|
+
videoUrl?: string | undefined;
|
|
17
|
+
imageSrc: {
|
|
18
|
+
small?: string | undefined;
|
|
19
|
+
medium?: string | undefined;
|
|
20
|
+
default: string;
|
|
21
|
+
};
|
|
22
|
+
}>) => JSX.Element)[];
|
|
23
|
+
};
|
|
24
|
+
export default meta;
|
|
25
|
+
type Story = StoryObj<typeof VideoWithPlaceholder>;
|
|
26
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { ImageProps } from '../../atoms/Image/Image';
|
|
4
|
+
import './accreditationPromotion.scss';
|
|
5
|
+
interface Accreditation {
|
|
6
|
+
text: string;
|
|
7
|
+
image?: ImageProps;
|
|
8
|
+
}
|
|
9
|
+
export interface AccreditationPromotionProps {
|
|
10
|
+
theme: ThemeProps;
|
|
11
|
+
heading: string;
|
|
12
|
+
intro: string;
|
|
13
|
+
accreditations: Accreditation[];
|
|
14
|
+
/**
|
|
15
|
+
* The fullWidth version of this component is used for in study pages
|
|
16
|
+
*/
|
|
17
|
+
fullWidth?: boolean;
|
|
18
|
+
}
|
|
19
|
+
export default function AcreditationPromotion({ theme, heading, intro, accreditations, fullWidth }: AccreditationPromotionProps): ReactElement;
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import AccreditationPromotion from './AccreditationPromotion';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof AccreditationPromotion;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof meta>;
|
|
10
|
+
export declare const Example: Story;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { ImageProps } from '../../atoms/Image/Image';
|
|
4
|
+
import { TextButtonProps } from '../../atoms/TextButton/TextButton';
|
|
5
|
+
import { LinkWithArrowProps } from '../../atoms/LinkWithArrow/LinkWithArrow';
|
|
6
|
+
import './ctaComponent.scss';
|
|
7
|
+
export interface CTAComponentProps {
|
|
8
|
+
theme: ThemeProps;
|
|
9
|
+
image?: ImageProps | null;
|
|
10
|
+
heading: string;
|
|
11
|
+
copy: string;
|
|
12
|
+
primaryCTA: TextButtonProps;
|
|
13
|
+
secondaryCTA?: TextButtonProps;
|
|
14
|
+
link?: LinkWithArrowProps;
|
|
15
|
+
/**
|
|
16
|
+
* The fullWidth version of this component is used for in study pages
|
|
17
|
+
*/
|
|
18
|
+
fullWidth?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export default function CTAComponent({ theme, image, heading, copy, primaryCTA, secondaryCTA, link, fullWidth }: CTAComponentProps): ReactElement;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CTAComponent from './CTAComponent';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CTAComponent;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof meta>;
|
|
10
|
+
export declare const Example: Story;
|
|
11
|
+
export declare const ExampleNoImage: Story;
|
|
@@ -5,6 +5,8 @@ import { CardVideoProps } from '../../molecules/CardVideo/CardVideo';
|
|
|
5
5
|
import { CardPromoProps } from '../../molecules/CardPromo/CardPromo';
|
|
6
6
|
import { CardPromoSignpostProps } from '../../molecules/CardPromoSignpost/CardPromoSignpost';
|
|
7
7
|
import { CardPromoVideoProps } from '../../molecules/CardPromoVideo/CardPromoVideo';
|
|
8
|
+
import { CardStaffProps } from '../../molecules/CardStaff/CardStaff';
|
|
9
|
+
import { CardRelatedProps } from '../../molecules/CardRelatedCourse/CardRelatedCourse';
|
|
8
10
|
import { ThemeProps } from '../../../themeProps';
|
|
9
11
|
import './carousel.scss';
|
|
10
12
|
export interface CarouselProps {
|
|
@@ -12,7 +14,7 @@ export interface CarouselProps {
|
|
|
12
14
|
inverse?: boolean;
|
|
13
15
|
type: string;
|
|
14
16
|
title?: string;
|
|
15
|
-
cards: Omit<CardNewsProps, 'titleTag'>[] | CardFeaturedProps[] | CardVideoProps[] | CardPromoProps[] | CardPromoSignpostProps[] | CardPromoVideoProps[];
|
|
17
|
+
cards: Omit<CardNewsProps, 'titleTag'>[] | CardFeaturedProps[] | CardVideoProps[] | CardPromoProps[] | CardPromoSignpostProps[] | CardPromoVideoProps[] | CardStaffProps[] | CardRelatedProps[];
|
|
16
18
|
exploreMore?: string;
|
|
17
19
|
}
|
|
18
20
|
export default function Carousel({ theme, inverse, type, title, cards, exploreMore }: CarouselProps): ReactElement;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { ParagraphLinkProps } from '../../atoms/ParagraphLink/ParagraphLink';
|
|
4
|
+
import { TextButtonWithIconProps } from '../../atoms/TextButtonWithIcon/TextButtonWithIcon';
|
|
5
|
+
import './clearingBanner.scss';
|
|
6
|
+
export interface ClearingBannerProps {
|
|
7
|
+
theme: ThemeProps;
|
|
8
|
+
text: string;
|
|
9
|
+
smallLink?: ParagraphLinkProps;
|
|
10
|
+
mainLink?: TextButtonWithIconProps;
|
|
11
|
+
}
|
|
12
|
+
export default function ClearingBanner({ theme, text, smallLink, mainLink }: ClearingBannerProps): ReactElement;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import ClearingBanner from './ClearingBanner';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof ClearingBanner;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof meta>;
|
|
10
|
+
export declare const Example: Story;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { CourseDeliveryPillProps } from '../../atoms/CourseDeliveryPill/CourseDeliveryPill';
|
|
4
|
+
import './courseDeliveryPills.scss';
|
|
5
|
+
export interface CourseDeliveryPillsProps {
|
|
6
|
+
theme: ThemeProps;
|
|
7
|
+
pills: Omit<CourseDeliveryPillProps, 'theme'>[];
|
|
8
|
+
}
|
|
9
|
+
export default function CourseDeliveryPills({ pills, theme }: CourseDeliveryPillsProps): ReactElement;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import CourseDeliveryPills from './CourseDeliveryPills';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof CourseDeliveryPills;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof CourseDeliveryPills>;
|
|
10
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './listingResultsCount.scss';
|
|
4
|
+
export interface ListingResultsCountProps {
|
|
5
|
+
theme: ThemeProps;
|
|
6
|
+
count: number;
|
|
7
|
+
}
|
|
8
|
+
export default function ListingResultsCount({ count, theme }: ListingResultsCountProps): ReactElement;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import ListingResultsCount from './ListingResultsCount';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof ListingResultsCount;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
backgrounds: {
|
|
9
|
+
default: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default meta;
|
|
14
|
+
type Story = StoryObj<typeof ListingResultsCount>;
|
|
15
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './pagination.scss';
|
|
4
|
+
export interface PaginationProps {
|
|
5
|
+
theme: ThemeProps;
|
|
6
|
+
numOfPages: number;
|
|
7
|
+
onClick: (pageNumber: number) => void;
|
|
8
|
+
currentPage: number;
|
|
9
|
+
}
|
|
10
|
+
export default function Pagination({ theme, numOfPages, onClick, currentPage }: PaginationProps): ReactElement;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import Pagination from './Pagination';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof Pagination;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
export declare const FourPages: () => ReactElement;
|
|
10
|
+
export declare const SevenPages: () => ReactElement;
|
|
11
|
+
export declare const TenPages: () => ReactElement;
|
|
12
|
+
export declare const TwentyPages: () => ReactElement;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { LinkWithArrowProps } from '../../atoms/LinkWithArrow/LinkWithArrow';
|
|
4
|
+
import { HeadingProps } from '../../molecules/Heading/Heading';
|
|
5
|
+
import './QuoteBlock.scss';
|
|
6
|
+
type LinkProps = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
|
|
7
|
+
export interface QuoteBlockProps extends HeadingProps {
|
|
8
|
+
theme: ThemeProps;
|
|
9
|
+
title?: string;
|
|
10
|
+
cite: string;
|
|
11
|
+
role: string;
|
|
12
|
+
quote: string;
|
|
13
|
+
quoteeProfileImage: string;
|
|
14
|
+
quoteeProfileImageAltText: string;
|
|
15
|
+
cta?: LinkProps;
|
|
16
|
+
}
|
|
17
|
+
export default function QuoteBlock({ theme, inverse, title, description, cite, role, quote, quoteeProfileImage, quoteeProfileImageAltText, cta }: QuoteBlockProps): ReactElement;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import QuoteBlock from './QuoteBlock';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof QuoteBlock;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
backgrounds: {
|
|
9
|
+
default: string;
|
|
10
|
+
};
|
|
11
|
+
quoteBlockProps: import("./QuoteBlock").QuoteBlockProps;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export default meta;
|
|
15
|
+
type Story = StoryObj<typeof QuoteBlock>;
|
|
16
|
+
export declare const Default: Story;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import { CardRelatedProps } from '../../molecules/CardRelatedCourse/CardRelatedCourse';
|
|
4
|
+
import './relatedCourses.scss';
|
|
5
|
+
export interface RelatedCoursesProps {
|
|
6
|
+
theme: ThemeProps;
|
|
7
|
+
inverse?: boolean;
|
|
8
|
+
heading: string;
|
|
9
|
+
cards: CardRelatedProps[];
|
|
10
|
+
}
|
|
11
|
+
export default function RelatedCourses({ theme, inverse, heading, cards }: RelatedCoursesProps): ReactElement;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import RelatedCourses from './RelatedCourses';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof RelatedCourses;
|
|
6
|
+
tags: string[];
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
type Story = StoryObj<typeof meta>;
|
|
10
|
+
export declare const Example: Story;
|
|
11
|
+
export declare const ExampleOneCourse: Story;
|
|
@@ -11,5 +11,9 @@ export interface RichTextProps {
|
|
|
11
11
|
*/
|
|
12
12
|
inverse?: boolean;
|
|
13
13
|
text: string;
|
|
14
|
+
/**
|
|
15
|
+
* The fullWidth version of this component is used for in study pages
|
|
16
|
+
*/
|
|
17
|
+
fullWidth?: boolean;
|
|
14
18
|
}
|
|
15
|
-
export default function RichText({ text, theme, inverse }: RichTextProps): ReactElement;
|
|
19
|
+
export default function RichText({ text, theme, inverse, fullWidth }: RichTextProps): ReactElement;
|
|
@@ -30,15 +30,15 @@ export interface SearchCoursesProps {
|
|
|
30
30
|
/**
|
|
31
31
|
* Display name of the filter
|
|
32
32
|
*/
|
|
33
|
-
filterTitle
|
|
33
|
+
filterTitle?: string;
|
|
34
34
|
/**
|
|
35
35
|
* Field name of the filter (passed to the results page)
|
|
36
36
|
*/
|
|
37
|
-
filterFieldName
|
|
37
|
+
filterFieldName?: string;
|
|
38
38
|
/**
|
|
39
39
|
* Available options in the select filter
|
|
40
40
|
*/
|
|
41
|
-
filterOptions
|
|
41
|
+
filterOptions?: SelectOptionsProps[];
|
|
42
42
|
/**
|
|
43
43
|
* Default value for filter
|
|
44
44
|
*/
|
|
@@ -51,8 +51,17 @@ export interface SearchCoursesProps {
|
|
|
51
51
|
* The wrapped version of this component is used for Hero
|
|
52
52
|
*/
|
|
53
53
|
wrapped?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* The fullWidth version of this component is used for in study pages
|
|
56
|
+
*/
|
|
57
|
+
fullWidth?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* The onGrid version of this component is used for in study pages
|
|
60
|
+
*/
|
|
61
|
+
onGrid?: boolean;
|
|
62
|
+
titleTag?: 'h1' | 'h2';
|
|
54
63
|
}
|
|
55
64
|
/**
|
|
56
65
|
* Search component
|
|
57
66
|
*/
|
|
58
|
-
export default function SearchCourses({ theme, inverse, title, defaultSearchTerm, placeholder, filterTitle, filterFieldName, filterOptions, defaultFilter, resultsUrl, wrapped }: SearchCoursesProps): ReactElement;
|
|
67
|
+
export default function SearchCourses({ theme, inverse, title, defaultSearchTerm, placeholder, filterTitle, filterFieldName, filterOptions, defaultFilter, resultsUrl, wrapped, fullWidth, onGrid, titleTag }: SearchCoursesProps): ReactElement;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactElement, ReactNode } from 'react';
|
|
2
|
+
import { ThemeProps } from '../../../themeProps';
|
|
3
|
+
import './sidebarWrapper.scss';
|
|
4
|
+
export interface SidebarWrapperProps {
|
|
5
|
+
/**
|
|
6
|
+
* The theme to use
|
|
7
|
+
*/
|
|
8
|
+
theme: ThemeProps;
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
}
|
|
11
|
+
export default function SidebarWrapper({ theme, children }: SidebarWrapperProps): ReactElement;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { StoryObj } from '@storybook/react';
|
|
2
|
+
import SidebarWrapper from './SidebarWrapper';
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof SidebarWrapper;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
backgrounds: {
|
|
9
|
+
default: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default meta;
|
|
14
|
+
type Story = StoryObj<typeof SidebarWrapper>;
|
|
15
|
+
export declare const Default: Story;
|