@uob-web-and-digital/component-library 1.0.9 → 1.2.0

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.
@@ -10,3 +10,4 @@ type Story = StoryObj<typeof meta>;
10
10
  export declare const Default: Story;
11
11
  export declare const WithOptionalLink: Story;
12
12
  export declare const NoServices: Story;
13
+ export declare const NoLink: Story;
@@ -1,13 +1,18 @@
1
1
  import { ReactElement } from 'react';
2
2
  import { ThemeProps } from '../../../themeProps';
3
3
  import { CardRelatedProps } from '../../molecules/CardRelatedCourse/CardRelatedCourse';
4
+ import { LinkWithArrowProps } from '../../atoms/LinkWithArrow/LinkWithArrow';
4
5
  import './relatedCourses.scss';
6
+ type LinkProps = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
5
7
  export interface RelatedCoursesProps {
6
8
  theme: ThemeProps;
7
9
  inverse?: boolean;
8
10
  heading: string;
11
+ description?: string;
12
+ linkProps?: LinkProps;
9
13
  fullWidth?: boolean;
10
14
  headingStyle?: 'news' | null;
11
15
  cards: CardRelatedProps[];
12
16
  }
13
- export default function RelatedCourses({ theme, inverse, heading, headingStyle, fullWidth, cards }: RelatedCoursesProps): ReactElement;
17
+ export default function RelatedCourses({ theme, inverse, heading, description, linkProps, headingStyle, fullWidth, cards }: RelatedCoursesProps): ReactElement;
18
+ export {};
@@ -8,6 +8,8 @@ declare const meta: {
8
8
  export default meta;
9
9
  type Story = StoryObj<typeof meta>;
10
10
  export declare const ExampleFourOrMoreCourses: Story;
11
+ export declare const ExampleWihDescription: Story;
12
+ export declare const ExampleWihLink: Story;
11
13
  export declare const ExampleWithNewsStyleHeading: Story;
12
14
  export declare const ExampleOneCourse: Story;
13
15
  export declare const ExampleTwoCourses: Story;
package/dist/index.d.ts CHANGED
@@ -54,7 +54,7 @@ interface HeadingProps$1 {
54
54
  children?: ReactNode;
55
55
  }
56
56
 
57
- type LinkProps$1 = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
57
+ type LinkProps$2 = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
58
58
  interface HeadingProps {
59
59
  /**
60
60
  * The theme to use
@@ -67,7 +67,7 @@ interface HeadingProps {
67
67
  htmlTag?: HeadingProps$1['htmlTag'];
68
68
  title?: string;
69
69
  description?: string | ReactElement;
70
- linkProps?: LinkProps$1;
70
+ linkProps?: LinkProps$2;
71
71
  fullWidth?: boolean;
72
72
  }
73
73
  declare function Heading({ title, description, linkProps, theme, inverse, fullWidth, htmlTag }: HeadingProps): ReactElement | null;
@@ -1317,7 +1317,7 @@ interface PromoBlockProps {
1317
1317
  }
1318
1318
  declare function PromoBlockGrid({ theme, inverse, type, title, description, link, cards, imageOrientation, fullWidth }: PromoBlockProps): ReactElement | null;
1319
1319
 
1320
- type LinkProps = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
1320
+ type LinkProps$1 = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
1321
1321
  interface QuoteBlockProps extends HeadingProps {
1322
1322
  theme: ThemeProps;
1323
1323
  inverse?: boolean;
@@ -1327,20 +1327,23 @@ interface QuoteBlockProps extends HeadingProps {
1327
1327
  quote: string;
1328
1328
  quoteeProfileImage?: string;
1329
1329
  quoteeProfileImageAltText?: string;
1330
- cta?: LinkProps;
1330
+ cta?: LinkProps$1;
1331
1331
  fullWidth?: boolean;
1332
1332
  }
1333
1333
  declare function QuoteBlock({ theme, inverse, title, description, cite, role, quote, quoteeProfileImage, quoteeProfileImageAltText, cta, fullWidth, htmlTag }: QuoteBlockProps): ReactElement;
1334
1334
 
1335
+ type LinkProps = Omit<LinkWithArrowProps, 'theme' | 'inverse'>;
1335
1336
  interface RelatedCoursesProps {
1336
1337
  theme: ThemeProps;
1337
1338
  inverse?: boolean;
1338
1339
  heading: string;
1340
+ description?: string;
1341
+ linkProps?: LinkProps;
1339
1342
  fullWidth?: boolean;
1340
1343
  headingStyle?: 'news' | null;
1341
1344
  cards: CardRelatedProps[];
1342
1345
  }
1343
- declare function RelatedCourses({ theme, inverse, heading, headingStyle, fullWidth, cards }: RelatedCoursesProps): ReactElement;
1346
+ declare function RelatedCourses({ theme, inverse, heading, description, linkProps, headingStyle, fullWidth, cards }: RelatedCoursesProps): ReactElement;
1344
1347
 
1345
1348
  interface ScholarshipCarouselProps {
1346
1349
  theme: ThemeProps;