@ilo-org/react 0.12.0 → 0.13.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.
Files changed (159) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/lib/cjs/components/Cards/CardGroup/CardGroup.js +42 -0
  3. package/lib/cjs/components/Cards/CardGroup/index.js +759 -0
  4. package/lib/cjs/components/Cards/DataCard/DataCard.js +27 -0
  5. package/lib/cjs/components/Cards/DataCard/index.js +73 -19
  6. package/lib/cjs/components/Cards/DetailCard/DetailCard.js +20 -0
  7. package/lib/cjs/components/Cards/DetailCard/index.js +17 -12
  8. package/lib/cjs/components/Cards/FactlistCard/FactListCard.js +23 -0
  9. package/lib/cjs/components/Cards/FactlistCard/index.js +16 -14
  10. package/lib/cjs/components/Cards/FeatureCard/FeatureCard.js +24 -0
  11. package/lib/cjs/components/Cards/FeatureCard/index.js +31 -16
  12. package/lib/cjs/components/Cards/MultilinkCard/MultiLinkCard.js +24 -0
  13. package/lib/cjs/components/Cards/MultilinkCard/index.js +35 -16
  14. package/lib/cjs/components/Cards/PromoCard/PromoCard.js +23 -0
  15. package/lib/cjs/components/Cards/PromoCard/index.js +18 -15
  16. package/lib/cjs/components/Cards/StatCard/StatCard.js +21 -0
  17. package/lib/cjs/components/Cards/StatCard/index.js +15 -13
  18. package/lib/cjs/components/Cards/TextCard/TextCard.js +23 -0
  19. package/lib/cjs/components/Cards/TextCard/index.js +22 -17
  20. package/lib/cjs/components/Footer/Footer.js +1 -1
  21. package/lib/cjs/components/Navigation/Navigation.js +3 -3
  22. package/lib/cjs/components/Pagination/Pagination.js +1 -1
  23. package/lib/cjs/components/index.js +10 -12
  24. package/lib/cjs/index.js +10 -12
  25. package/lib/esm/components/Cards/CardGroup/CardGroup.js +40 -0
  26. package/lib/esm/components/Cards/CardGroup/index.js +756 -0
  27. package/lib/esm/components/Cards/DataCard/DataCard.js +25 -0
  28. package/lib/esm/components/Cards/DataCard/index.js +72 -19
  29. package/lib/esm/components/Cards/DetailCard/DetailCard.js +18 -0
  30. package/lib/esm/components/Cards/DetailCard/index.js +16 -12
  31. package/lib/esm/components/Cards/FactlistCard/FactListCard.js +21 -0
  32. package/lib/esm/components/Cards/FactlistCard/index.js +15 -14
  33. package/lib/esm/components/Cards/FeatureCard/FeatureCard.js +22 -0
  34. package/lib/esm/components/Cards/FeatureCard/index.js +30 -16
  35. package/lib/esm/components/Cards/MultilinkCard/MultiLinkCard.js +22 -0
  36. package/lib/esm/components/Cards/MultilinkCard/index.js +34 -16
  37. package/lib/esm/components/Cards/PromoCard/PromoCard.js +21 -0
  38. package/lib/esm/components/Cards/PromoCard/index.js +17 -15
  39. package/lib/esm/components/Cards/StatCard/StatCard.js +19 -0
  40. package/lib/esm/components/Cards/StatCard/index.js +14 -13
  41. package/lib/esm/components/Cards/TextCard/TextCard.js +21 -0
  42. package/lib/esm/components/Cards/TextCard/index.js +21 -17
  43. package/lib/esm/components/Footer/Footer.js +1 -1
  44. package/lib/esm/components/Navigation/Navigation.js +3 -3
  45. package/lib/esm/components/Pagination/Pagination.js +1 -1
  46. package/lib/esm/components/index.js +9 -10
  47. package/lib/esm/index.js +9 -10
  48. package/lib/types/react/src/components/Cards/CardGroup/CardGroup.args.d.ts +13 -0
  49. package/lib/types/react/src/components/Cards/CardGroup/CardGroup.props.d.ts +58 -0
  50. package/lib/types/react/src/components/Cards/CardGroup/index.d.ts +3 -0
  51. package/lib/types/react/src/components/Cards/DataCard/DataCard.args.d.ts +2 -0
  52. package/lib/types/react/src/components/Cards/DataCard/DataCard.d.ts +4 -0
  53. package/lib/types/react/src/components/Cards/DataCard/DataCard.props.d.ts +50 -0
  54. package/lib/types/react/src/components/Cards/DataCard/index.d.ts +3 -4
  55. package/lib/types/react/src/components/Cards/DetailCard/DetailCard.args.d.ts +3 -0
  56. package/lib/types/react/src/components/Cards/DetailCard/DetailCard.d.ts +4 -0
  57. package/lib/types/react/src/components/Cards/DetailCard/DetailCard.props.d.ts +35 -0
  58. package/lib/types/react/src/components/Cards/DetailCard/index.d.ts +3 -4
  59. package/lib/types/react/src/components/Cards/FactlistCard/FactListCard.args.d.ts +3 -0
  60. package/lib/types/react/src/components/Cards/FactlistCard/FactListCard.d.ts +4 -0
  61. package/lib/types/react/src/components/Cards/FactlistCard/FactListCard.props.d.ts +16 -0
  62. package/lib/types/react/src/components/Cards/FactlistCard/index.d.ts +3 -4
  63. package/lib/types/react/src/components/Cards/FeatureCard/FeatureCard.args.d.ts +3 -0
  64. package/lib/types/react/src/components/Cards/FeatureCard/FeatureCard.d.ts +4 -0
  65. package/lib/types/react/src/components/Cards/FeatureCard/FeatureCard.props.d.ts +31 -0
  66. package/lib/types/react/src/components/Cards/FeatureCard/index.d.ts +3 -4
  67. package/lib/types/react/src/components/Cards/MultilinkCard/MultiLinkCard.d.ts +4 -0
  68. package/lib/types/react/src/components/Cards/MultilinkCard/MultilinkCard.args.d.ts +2 -0
  69. package/lib/types/react/src/components/Cards/MultilinkCard/MultilinkCard.props.d.ts +25 -0
  70. package/lib/types/react/src/components/Cards/MultilinkCard/index.d.ts +3 -4
  71. package/lib/types/react/src/components/Cards/PromoCard/PromoCard.args.d.ts +3 -0
  72. package/lib/types/react/src/components/Cards/PromoCard/PromoCard.d.ts +4 -0
  73. package/lib/types/react/src/components/Cards/PromoCard/PromoCard.props.d.ts +30 -0
  74. package/lib/types/react/src/components/Cards/PromoCard/index.d.ts +3 -4
  75. package/lib/types/react/src/components/Cards/StatCard/StatCard.args.d.ts +3 -0
  76. package/lib/types/react/src/components/Cards/StatCard/StatCard.d.ts +4 -0
  77. package/lib/types/react/src/components/Cards/StatCard/StatCard.props.d.ts +18 -0
  78. package/lib/types/react/src/components/Cards/StatCard/index.d.ts +3 -4
  79. package/lib/types/react/src/components/Cards/TextCard/TextCard.args.d.ts +3 -0
  80. package/lib/types/react/src/components/Cards/TextCard/TextCard.d.ts +4 -0
  81. package/lib/types/react/src/components/Cards/TextCard/TextCard.props.d.ts +26 -0
  82. package/lib/types/react/src/components/Cards/TextCard/index.d.ts +3 -4
  83. package/lib/types/react/src/components/index.d.ts +1 -1
  84. package/lib/types/react/src/types/index.d.ts +4 -0
  85. package/package.json +2 -2
  86. package/src/components/Cards/{CardGroup.args.ts → CardGroup/CardGroup.args.ts} +196 -373
  87. package/src/components/Cards/CardGroup/CardGroup.props.ts +78 -0
  88. package/src/components/Cards/CardGroup/CardGroup.tsx +54 -0
  89. package/src/components/Cards/CardGroup/index.tsx +3 -0
  90. package/src/components/Cards/DataCard/DataCard.args.ts +69 -0
  91. package/src/components/Cards/DataCard/DataCard.props.ts +60 -0
  92. package/src/components/Cards/DataCard/DataCard.tsx +107 -0
  93. package/src/components/Cards/DataCard/index.tsx +3 -107
  94. package/src/components/Cards/DetailCard/DetailCard.args.ts +17 -0
  95. package/src/components/Cards/DetailCard/DetailCard.props.ts +43 -0
  96. package/src/components/Cards/DetailCard/DetailCard.tsx +62 -0
  97. package/src/components/Cards/DetailCard/index.tsx +3 -62
  98. package/src/components/Cards/FactlistCard/FactListCard.args.ts +14 -0
  99. package/src/components/Cards/FactlistCard/FactListCard.props.ts +19 -0
  100. package/src/components/Cards/FactlistCard/FactListCard.tsx +42 -0
  101. package/src/components/Cards/FactlistCard/index.tsx +3 -42
  102. package/src/components/Cards/FeatureCard/FeatureCard.args.ts +30 -0
  103. package/src/components/Cards/FeatureCard/FeatureCard.props.ts +38 -0
  104. package/src/components/Cards/FeatureCard/FeatureCard.tsx +69 -0
  105. package/src/components/Cards/FeatureCard/index.tsx +3 -69
  106. package/src/components/Cards/MultilinkCard/MultiLinkCard.tsx +76 -0
  107. package/src/components/Cards/MultilinkCard/MultilinkCard.args.ts +33 -0
  108. package/src/components/Cards/MultilinkCard/MultilinkCard.props.ts +30 -0
  109. package/src/components/Cards/MultilinkCard/index.tsx +3 -76
  110. package/src/components/Cards/PromoCard/PromoCard.args.ts +19 -0
  111. package/src/components/Cards/PromoCard/PromoCard.props.ts +36 -0
  112. package/src/components/Cards/PromoCard/PromoCard.tsx +60 -0
  113. package/src/components/Cards/PromoCard/index.tsx +3 -60
  114. package/src/components/Cards/StatCard/StatCard.args.ts +14 -0
  115. package/src/components/Cards/StatCard/StatCard.props.ts +21 -0
  116. package/src/components/Cards/StatCard/StatCard.tsx +36 -0
  117. package/src/components/Cards/StatCard/index.tsx +3 -36
  118. package/src/components/Cards/TextCard/TextCard.args.ts +21 -0
  119. package/src/components/Cards/TextCard/TextCard.props.ts +32 -0
  120. package/src/components/Cards/TextCard/TextCard.tsx +62 -0
  121. package/src/components/Cards/TextCard/index.tsx +3 -63
  122. package/src/components/Footer/Footer.args.ts +4 -16
  123. package/src/components/Footer/Footer.tsx +41 -37
  124. package/src/components/Navigation/Navigation.tsx +5 -5
  125. package/src/components/Pagination/Pagination.tsx +2 -1
  126. package/src/components/index.ts +1 -1
  127. package/src/types/index.ts +6 -0
  128. package/lib/cjs/components/Cards/Card.js +0 -40
  129. package/lib/cjs/components/Cards/CardGroup.js +0 -33
  130. package/lib/cjs/components/Cards/index.js +0 -37
  131. package/lib/esm/components/Cards/Card.js +0 -38
  132. package/lib/esm/components/Cards/CardGroup.js +0 -31
  133. package/lib/esm/components/Cards/index.js +0 -22
  134. package/lib/types/react/src/components/Cards/Card.d.ts +0 -4
  135. package/lib/types/react/src/components/Cards/Card.props.d.ts +0 -307
  136. package/lib/types/react/src/components/Cards/CardGroup.props.d.ts +0 -16
  137. package/lib/types/react/src/components/Cards/index.d.ts +0 -11
  138. package/public/fao-logo.svg +0 -195
  139. package/public/favicon.ico +0 -0
  140. package/public/hero.jpg +0 -0
  141. package/public/ilo-dg.jpg +0 -0
  142. package/public/ilo-headquarters.jpg +0 -0
  143. package/public/large.jpg +0 -0
  144. package/public/media-file-poster.jpg +0 -0
  145. package/public/medium.jpg +0 -0
  146. package/public/small.jpg +0 -0
  147. package/public/unhcr-logo.svg +0 -1
  148. package/public/unicef-logo.png +0 -0
  149. package/public/video-example.mp4 +0 -0
  150. package/public/wfp-logo.svg +0 -1
  151. package/public/who-logo.svg +0 -1
  152. package/public/youtube-video-poster.avif +0 -0
  153. package/src/components/Cards/Card.args.ts +0 -220
  154. package/src/components/Cards/Card.props.ts +0 -382
  155. package/src/components/Cards/Card.tsx +0 -36
  156. package/src/components/Cards/CardGroup.props.ts +0 -19
  157. package/src/components/Cards/CardGroup.tsx +0 -54
  158. package/src/components/Cards/index.ts +0 -22
  159. /package/lib/types/react/src/components/Cards/{CardGroup.d.ts → CardGroup/CardGroup.d.ts} +0 -0
@@ -1,37 +0,0 @@
1
- 'use strict';
2
-
3
- var components_Cards_FeatureCard_index = require('./FeatureCard/index.js');
4
- var components_Cards_DataCard_index = require('./DataCard/index.js');
5
- var components_Cards_DetailCard_index = require('./DetailCard/index.js');
6
- var components_Cards_FactlistCard_index = require('./FactlistCard/index.js');
7
- var components_Cards_MultilinkCard_index = require('./MultilinkCard/index.js');
8
- var components_Cards_PromoCard_index = require('./PromoCard/index.js');
9
- var components_Cards_StatCard_index = require('./StatCard/index.js');
10
- var components_Cards_TextCard_index = require('./TextCard/index.js');
11
- var components_Cards_Card = require('./Card.js');
12
- var components_Cards_CardGroup = require('./CardGroup.js');
13
- require('react/jsx-runtime');
14
- require('classnames');
15
- require('../../hooks/useGlobalSettings.js');
16
- require('tslib');
17
- require('react');
18
- require('../../GlobalCtx-10114bdd.js');
19
- require('../LinkList/LinkList.js');
20
- require('../Link/Link.js');
21
- require('../List/List.js');
22
- require('../../ListCtx-14aa546f.js');
23
- require('../List/ListItem.js');
24
- require('../Profile/Profile.js');
25
-
26
-
27
-
28
- exports.FeatureCard = components_Cards_FeatureCard_index;
29
- exports.DataCard = components_Cards_DataCard_index;
30
- exports.DetailCard = components_Cards_DetailCard_index;
31
- exports.FactlistCard = components_Cards_FactlistCard_index;
32
- exports.MultilinkCard = components_Cards_MultilinkCard_index;
33
- exports.PromoCard = components_Cards_PromoCard_index;
34
- exports.StatCard = components_Cards_StatCard_index;
35
- exports.TextCard = components_Cards_TextCard_index;
36
- exports.Card = components_Cards_Card;
37
- exports.CardGroup = components_Cards_CardGroup;
@@ -1,38 +0,0 @@
1
- import { jsx } from 'react/jsx-runtime';
2
- import FeatureCard from './FeatureCard/index.js';
3
- import DataCard from './DataCard/index.js';
4
- import DetailCard from './DetailCard/index.js';
5
- import FactlistCard from './FactlistCard/index.js';
6
- import MultilinkCard from './MultilinkCard/index.js';
7
- import PromoCard from './PromoCard/index.js';
8
- import StatCard from './StatCard/index.js';
9
- import TextCard from './TextCard/index.js';
10
- import 'classnames';
11
- import 'tslib';
12
- import 'react';
13
- import '../../GlobalCtx-7fb23cfa.js';
14
- import '../../hooks/useGlobalSettings.js';
15
- import '../LinkList/LinkList.js';
16
- import '../Link/Link.js';
17
- import '../List/List.js';
18
- import '../../ListCtx-da435fdf.js';
19
- import '../List/ListItem.js';
20
- import '../Profile/Profile.js';
21
-
22
- const Card = (props) => {
23
- const componentMap = {
24
- data: DataCard,
25
- detail: DetailCard,
26
- factlist: FactlistCard,
27
- featurecard: FeatureCard,
28
- multilink: MultilinkCard,
29
- promo: PromoCard,
30
- stat: StatCard,
31
- text: TextCard,
32
- };
33
- const { type } = props;
34
- const SelectedCardComponent = componentMap[type] || FeatureCard;
35
- return jsx(SelectedCardComponent, Object.assign({}, props));
36
- };
37
-
38
- export { Card as default };
@@ -1,31 +0,0 @@
1
- import './FeatureCard/index.js';
2
- import './DataCard/index.js';
3
- import './DetailCard/index.js';
4
- import './FactlistCard/index.js';
5
- import './MultilinkCard/index.js';
6
- import './PromoCard/index.js';
7
- import './StatCard/index.js';
8
- import './TextCard/index.js';
9
- import Card from './Card.js';
10
- import { jsxs, jsx } from 'react/jsx-runtime';
11
- import classNames from 'classnames';
12
- import useGlobalSettings from '../../hooks/useGlobalSettings.js';
13
- import 'tslib';
14
- import 'react';
15
- import '../../ListCtx-da435fdf.js';
16
- import '../LinkList/LinkList.js';
17
- import '../../GlobalCtx-7fb23cfa.js';
18
- import '../Link/Link.js';
19
- import '../List/List.js';
20
- import '../List/ListItem.js';
21
- import '../Profile/Profile.js';
22
-
23
- const CardGroup = ({ cards, cardcount, cta }) => {
24
- const { prefix } = useGlobalSettings();
25
- const baseClass = `${prefix}--cardgroup`;
26
- const cardGroupClasses = classNames(baseClass, `${baseClass}--${cardcount}`);
27
- return (jsxs("div", Object.assign({ className: cardGroupClasses }, { children: [jsx("div", Object.assign({ className: `${baseClass}--inner` }, { children: cards &&
28
- cards.map((card) => (jsx(Card, { title: card.title, image: card.image, intro: card.intro, eyebrow: card.eyebrow, date: card.date, dataset: card.dataset, link: card.link, profile: card.profile, cta: card.cta, source: card.source, listitems: card.listitems, linklist: card.linklist, color: card.color, theme: card.theme, cornercut: card.cornercut, alignment: card.alignment, type: card.type, size: card.size }))) })), cta && (jsx("div", Object.assign({ className: `${baseClass}--button-wrap` }, { children: jsx("a", Object.assign({ className: `${prefix}--button ${prefix}--button--medium ${prefix}--button--secondary`, href: cta.url }, { children: jsx("span", Object.assign({ className: "button__label" }, { children: cta.label })) })) })))] })));
29
- };
30
-
31
- export { CardGroup as default };
@@ -1,22 +0,0 @@
1
- export { default as FeatureCard } from './FeatureCard/index.js';
2
- export { default as DataCard } from './DataCard/index.js';
3
- export { default as DetailCard } from './DetailCard/index.js';
4
- export { default as FactlistCard } from './FactlistCard/index.js';
5
- export { default as MultilinkCard } from './MultilinkCard/index.js';
6
- export { default as PromoCard } from './PromoCard/index.js';
7
- export { default as StatCard } from './StatCard/index.js';
8
- export { default as TextCard } from './TextCard/index.js';
9
- export { default as Card } from './Card.js';
10
- export { default as CardGroup } from './CardGroup.js';
11
- import 'react/jsx-runtime';
12
- import 'classnames';
13
- import '../../hooks/useGlobalSettings.js';
14
- import 'tslib';
15
- import 'react';
16
- import '../../GlobalCtx-7fb23cfa.js';
17
- import '../LinkList/LinkList.js';
18
- import '../Link/Link.js';
19
- import '../List/List.js';
20
- import '../../ListCtx-da435fdf.js';
21
- import '../List/ListItem.js';
22
- import '../Profile/Profile.js';
@@ -1,4 +0,0 @@
1
- import { FC } from "react";
2
- import { CardProps } from "./Card.props";
3
- declare const Card: FC<CardProps>;
4
- export default Card;
@@ -1,307 +0,0 @@
1
- import { CardAlignment, ThemeTypes, CardCornerType, CardColor, CardSize, CardTypes } from "../../types";
2
- import { LinkProps, LinkListProps } from "../LinkList/LinkList.props";
3
- import { ProfileProps } from "../Profile/Profile.props";
4
- export type DataCardProps = {
5
- /**
6
- * A line of text that appears as a small heading at the top of the card
7
- */
8
- eyebrow?: string;
9
- /**
10
- * How big should the card be
11
- */
12
- size?: Omit<CardSize, "standard">;
13
- /**
14
- * The image to show in the card
15
- */
16
- image?: string;
17
- /**
18
- * Array of Content (label, copy), Files object (optional headline, array of items with label and url) and Links * * object (optional headline, array of items with label and url)
19
- */
20
- dataset?: CardDataset;
21
- /**
22
- * Make the content appear in one or two columns. Only applies when the size is set to `wide` or `fluid`
23
- */
24
- columns?: string;
25
- };
26
- export type DetailCardProps = {
27
- /**
28
- * A line of text that appears as a small heading above the title of the card
29
- */
30
- eyebrow?: string;
31
- /**
32
- * The title of the card
33
- */
34
- title: string;
35
- /**
36
- * Introductory text in the card
37
- */
38
- intro?: string;
39
- /**
40
- * Specify the event Date, in both human and Unix format.
41
- */
42
- date?: EventDate;
43
- /**
44
- * Information about an event
45
- */
46
- eventdetails?: string;
47
- /**
48
- * A URL to link to
49
- */
50
- link?: string;
51
- /**
52
- * The image to show in the card
53
- */
54
- image?: string;
55
- /**
56
- * How big should the card be
57
- */
58
- size?: Omit<CardSize, "standard">;
59
- };
60
- export type FactlistCardProps = {
61
- /**
62
- * The title of the card
63
- */
64
- title: string;
65
- /**
66
- * Will render the card to appear on light or dark backgrounds
67
- */
68
- theme?: ThemeTypes;
69
- /**
70
- * How big should the card be
71
- */
72
- size?: Omit<CardSize, "standard">;
73
- list?: string[];
74
- };
75
- export type FeatureCardProps = {
76
- isvideo?: boolean;
77
- /**
78
- * A line of text that appears as a small heading above the title of the card
79
- */
80
- eyebrow?: string;
81
- /**
82
- * The title of the card
83
- */
84
- title: string;
85
- /**
86
- * Will render the card to appear on light or dark backgrounds
87
- */
88
- theme?: ThemeTypes;
89
- /**
90
- * How big should the card be
91
- */
92
- size?: Omit<CardSize, "standard">;
93
- /**
94
- * Specify the event Date, in both human and Unix format.
95
- */
96
- date?: EventDate;
97
- link?: string;
98
- linklist?: LinkListProps;
99
- /**
100
- * The image to show in the card
101
- */
102
- image?: string;
103
- };
104
- export type MultilinkCardProps = {
105
- isvideo?: boolean;
106
- /**
107
- * A line of text that appears as a small heading above the title of the card
108
- */
109
- eyebrow?: string;
110
- /**
111
- * The title of the card
112
- */
113
- title: string;
114
- /**
115
- * How big should the card be
116
- */
117
- size?: CardSize;
118
- alignment?: CardAlignment;
119
- intro?: string;
120
- link?: string;
121
- linklist?: LinkListProps;
122
- /**
123
- * The image to show in the card
124
- */
125
- image?: string;
126
- };
127
- export type PromoCardProps = {
128
- /**
129
- * A line of text that appears as a small heading above the title of the card
130
- */
131
- eyebrow?: string;
132
- /**
133
- * The title of the card
134
- */
135
- title: string;
136
- /**
137
- * Will render the card to appear on light or dark backgrounds
138
- */
139
- theme?: ThemeTypes;
140
- /**
141
- * How big should the card be
142
- */
143
- size?: CardSize;
144
- /**
145
- * Apply an optional corner cut to the top of the card
146
- */
147
- cornercut?: CardCornerType;
148
- /**
149
- * Introductory text in the card
150
- */
151
- intro?: string;
152
- link?: string;
153
- cta?: LinkProps;
154
- };
155
- export type StatCardProps = {
156
- /**
157
- * The title of the card
158
- */
159
- title: string;
160
- color?: CardColor;
161
- /**
162
- * How big should the card be
163
- */
164
- size?: Omit<CardSize, "narrow" | "wide">;
165
- /**
166
- * Introductory text in the card
167
- */
168
- intro?: string;
169
- source?: LinkProps;
170
- };
171
- export type TextCardProps = {
172
- /**
173
- * A line of text that appears as a small heading above the title of the card
174
- */
175
- eyebrow?: string;
176
- /**
177
- * The title of the card
178
- */
179
- title: string;
180
- /**
181
- * Will render the card to appear on light or dark backgrounds
182
- */
183
- theme?: ThemeTypes;
184
- /**
185
- * How big should the card be
186
- */
187
- size?: Omit<CardSize, "standard">;
188
- /**
189
- * Specify the event Date, in both human and Unix format.
190
- */
191
- date?: EventDate;
192
- profile: ProfileProps;
193
- link?: string;
194
- };
195
- export interface CardProps {
196
- /**
197
- * Specify whether the card should display a video icon (for Feature card). Possible options: true | false
198
- */
199
- isvideo?: boolean;
200
- /**
201
- * Eyebrow field for the card.
202
- */
203
- eyebrow: string;
204
- /**
205
- * Title field for the card
206
- */
207
- title: string;
208
- /**
209
- * Color of the stat cards, options are turquoise | green| yellow| blue. Only used for stat cards.
210
- */
211
- color?: CardColor;
212
- /**
213
- * The theme type for the card. Theme doesn't apply to these card types: Multilink, Data, Stat and Detail. Possible themes: light | dark.
214
- */
215
- theme?: ThemeTypes;
216
- /**
217
- * Type - Sets the type of card to render.
218
- Option keys: feature, text, detail, promo, multilink, data, stat, factlist
219
- */
220
- type: CardTypes;
221
- /**
222
- * Size of the cards (usually reduces padding). `Wide` on Multilink and Feature cause a two column structure above a desktop breakpoint. Possible options: Wide | Standard | Narrow.
223
- */
224
- size?: CardSize;
225
- /**
226
- * Specify whether the card has a cut corner. The only card that uses this setting are `Promo`.
227
- */
228
- cornercut?: CardCornerType;
229
- /**
230
- * Specify whether a card image is right-aligned or left-aligned for `Multilink` cards. Possible options: left | right.
231
- */
232
- alignment?: CardAlignment;
233
- /**
234
- * Intro text field for the card
235
- */
236
- intro?: string;
237
- /**
238
- * Specify the event Date, in both human and Unix format.
239
- */
240
- date?: EventDate;
241
- /**
242
- * Event details for `Detail` card
243
- */
244
- eventdetails?: string;
245
- /**
246
- * Profile to embed in the card for `Text` card
247
- */
248
- profile?: ProfileProps;
249
- /**
250
- * A list of text itmes to be embed in the card, specifically used in `Factlist` card.
251
- */
252
- listitems?: Array<string>;
253
- /**
254
- * A Link behind a clickable card. Do no use on `Multilink`, `Factlist`, `Data`, or `Stat` cards.
255
- */
256
- link?: string;
257
- /**
258
- * Props of the LinkList component. Appears at the bottom of `Multilink` or `Feature` card.
259
- */
260
- linklist?: LinkListProps;
261
- /**
262
- * Items for clickable CTA button, specifically used for `Promo` card.
263
- */
264
- cta?: LinkProps;
265
- /**
266
- * The image used in a card. Images should be avoided on `Promo`, `Text`, `Factlist`, and `Stat` card.
267
- */
268
- image?: string;
269
- /**
270
- * Source link for `Stat` cards.
271
- */
272
- source?: LinkProps;
273
- /**
274
- * Dataset object for the `Data` card. An array of Content (label, copy), Files (optional headline, array of items with label and url), and Links (optional headline, array of items with label and url).
275
- */
276
- dataset?: CardDataset;
277
- }
278
- interface EventDate {
279
- unix?: string;
280
- human?: string;
281
- }
282
- interface CardDataset {
283
- content?: DataContent;
284
- files?: DataFile;
285
- links?: DataLink;
286
- cta?: Cta;
287
- }
288
- interface DataContent {
289
- items?: Array<ContentItem>;
290
- }
291
- interface ContentItem {
292
- label?: string;
293
- copy?: string;
294
- }
295
- interface DataFile {
296
- headline?: string;
297
- items?: Array<LinkProps>;
298
- }
299
- interface DataLink {
300
- headline?: string;
301
- items?: Array<LinkProps>;
302
- }
303
- interface Cta {
304
- headline?: string;
305
- items?: Array<LinkProps>;
306
- }
307
- export {};
@@ -1,16 +0,0 @@
1
- import { CardProps } from "./Card.props";
2
- import { LinkProps } from "../LinkList/LinkList.props";
3
- export interface CardGroupProps {
4
- /**
5
- * An array of card objects
6
- */
7
- cards?: Required<CardProps>[];
8
- /**
9
- * Number of cards in the group
10
- */
11
- cardcount: Required<string>;
12
- /**
13
- * A Button to display after all the cards in the group
14
- */
15
- cta?: LinkProps;
16
- }
@@ -1,11 +0,0 @@
1
- import FeatureCard from "./FeatureCard";
2
- import DataCard from "./DataCard";
3
- import DetailCard from "./DetailCard";
4
- import FactlistCard from "./FactlistCard";
5
- import MultilinkCard from "./MultilinkCard";
6
- import PromoCard from "./PromoCard";
7
- import StatCard from "./StatCard";
8
- import TextCard from "./TextCard";
9
- export { FeatureCard, DataCard, DetailCard, FactlistCard, MultilinkCard, PromoCard, StatCard, TextCard, };
10
- export { default as Card } from "./Card";
11
- export { default as CardGroup } from "./CardGroup";