@apolitical/component-library 1.4.1-beta.1 → 1.6.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 (62) hide show
  1. package/accessibility/visually-hidden/visually-hidden.d.ts +2 -1
  2. package/communities/community-details/community-details.d.ts +11 -1
  3. package/communities/index.d.ts +1 -0
  4. package/communities/join-button/join-button.d.ts +3 -1
  5. package/communities/members-list/index.d.ts +1 -0
  6. package/communities/members-list/members-list.d.ts +23 -0
  7. package/discussion/discussion.mock.d.ts +6 -33
  8. package/discussion/index.d.ts +2 -0
  9. package/discussion/likes/likes.d.ts +16 -6
  10. package/discussion/likes/likes.helpers.d.ts +2 -0
  11. package/discussion/post/post.d.ts +12 -1
  12. package/discussion/post/post.mock.d.ts +18 -0
  13. package/discussion/responses-heading/index.d.ts +1 -0
  14. package/discussion/responses-heading/responses-heading.d.ts +10 -0
  15. package/discussion/thread/index.d.ts +1 -0
  16. package/discussion/thread/thread.d.ts +11 -0
  17. package/general/buttons/button-wrapper/button-wrapper.d.ts +1 -0
  18. package/general/divider/divider.d.ts +6 -0
  19. package/general/divider/index.d.ts +1 -0
  20. package/general/index.d.ts +2 -0
  21. package/general/link/link.d.ts +2 -2
  22. package/general/tooltip/index.d.ts +1 -0
  23. package/general/tooltip/tooltip.d.ts +11 -0
  24. package/helpers/index.d.ts +1 -0
  25. package/helpers/numbers.d.ts +1 -0
  26. package/hooks/index.d.ts +1 -0
  27. package/hooks/use-scroll-to-hash.d.ts +2 -0
  28. package/index.js +48 -52
  29. package/index.mjs +8102 -7663
  30. package/layout/page-layout/page-layout.d.ts +1 -1
  31. package/modals/index.d.ts +1 -0
  32. package/modals/modal/modal.d.ts +19 -2
  33. package/modals/overlay/index.d.ts +2 -0
  34. package/modals/overlay/overlay.d.ts +36 -0
  35. package/modals/overlay/overlay.helpers.d.ts +5 -0
  36. package/navigation/breadcrumbs/breadcrumbs.d.ts +16 -0
  37. package/navigation/breadcrumbs/index.d.ts +1 -0
  38. package/navigation/index.d.ts +2 -0
  39. package/navigation/load-more/index.d.ts +1 -0
  40. package/navigation/load-more/load-more.d.ts +7 -5
  41. package/navigation/more-menu/index.d.ts +2 -0
  42. package/navigation/more-menu/more-menu.d.ts +37 -0
  43. package/package.json +1 -1
  44. package/style.css +1 -1
  45. package/styles/base/_links.scss +4 -1
  46. package/styles/base/_overlays.scss +41 -7
  47. package/styles/base/_titles.scss +16 -0
  48. package/styles/base/buttons/_buttons.scss +58 -5
  49. package/styles/base/buttons/_icons.scss +8 -1
  50. package/styles/base/buttons/_sizes.scss +1 -0
  51. package/styles/variables/colors/_theme.scss +45 -10
  52. package/text/empty-state-box/empty-state-box.d.ts +3 -1
  53. package/text/helper-text-box/helper-text-box.d.ts +1 -1
  54. package/text/index.d.ts +1 -1
  55. package/text/pill/pill.d.ts +5 -1
  56. package/text/status-banner/index.d.ts +1 -0
  57. package/text/{alert/alert.d.ts → status-banner/status-banner.d.ts} +2 -2
  58. package/user/contributors/contributors.d.ts +5 -2
  59. package/user/contributors/contributors.mock.d.ts +8 -5
  60. package/user/member/index.d.ts +1 -1
  61. package/user/member/member.d.ts +15 -3
  62. package/text/alert/index.d.ts +0 -1
@@ -1,8 +1,11 @@
1
1
  @use 'sass:map';
2
- @import './../variables';
2
+ @import './../mixins',
3
+ './../variables';
3
4
 
4
5
  @layer base {
5
6
  a {
7
+ @include transition(color);
8
+
6
9
  color: map.get($theme, 'link');
7
10
  text-decoration: underline;
8
11
  font-weight: 900;
@@ -1,8 +1,13 @@
1
1
  @use 'sass:map';
2
- @import './../mixins',
2
+ @import './../functions',
3
+ './../mixins',
3
4
  './../variables';
4
5
 
6
+ $overlay: ('padding': 48);
7
+
5
8
  @layer base {
9
+ body.has-overlay { overflow: hidden; }
10
+
6
11
  .overlay {
7
12
  @include transition(opacity, 0.1s, ease);
8
13
 
@@ -14,13 +19,42 @@
14
19
  left: 0;
15
20
  opacity: 0;
16
21
  z-index: -1;
22
+ box-sizing: border-box;
23
+ display: flex;
24
+ flex-flow: column;
25
+ align-items: center;
26
+ overflow: hidden;
17
27
 
18
- &.open {
19
- width: 100vw;
20
- height: 100vh;
21
- opacity: 1;
22
- z-index: 998;
23
- }
28
+ &.open {
29
+ width: 100vw;
30
+ height: 100vh;
31
+ opacity: 1;
32
+ z-index: 998;
33
+ }
34
+
35
+ > div, > section {
36
+ width: 100vw;
37
+ height: 100vh;
38
+ margin-top: auto;
39
+ margin-bottom: auto;
40
+ overflow-x: hidden;
41
+ overflow-y: auto;
42
+ }
24
43
 
25
44
  }
45
+
46
+ @include breakpoint('min-width', 'sm') {
47
+ .overlay {
48
+ &.open {
49
+ padding: px-to-rem(map.get($overlay, 'padding'));
50
+ overflow-y: auto;
51
+ }
52
+
53
+ > div, > section {
54
+ width: auto;
55
+ height: auto;
56
+ overflow: unset;
57
+ }
58
+ }
59
+ }
26
60
  }
@@ -12,6 +12,7 @@ $h4: ('font-size': 18, 'font-size_md': 20, 'line-height': 24, 'line-height_md':
12
12
  $h5: ('font-size': 12, 'font-size_md': 14, 'line-height': 16, 'margin-top': 16, 'margin-bottom': 16);
13
13
  $h6: ('font-size': 12, 'font-size_md': 11, 'line-height': 16);
14
14
  $subtitle: ('font-size': 20, 'font-size_md': 24, 'line-height': 28, 'line-height_md': 32, 'margin-bottom': 20);
15
+ $count-icon: ('width': 15, 'margin-horizontal': 8, 'offset': 1);
15
16
 
16
17
  @mixin pre-title {
17
18
  margin-bottom: px-to-rem(map.get($pre-title, 'margin-bottom'));
@@ -173,4 +174,19 @@ $subtitle: ('font-size': 20, 'font-size_md': 24, 'line-height': 28, 'line-height
173
174
  .subtitle {
174
175
  @include subtitle;
175
176
  }
177
+
178
+ .count {
179
+ &::before {
180
+ @include image('icons/middot.svg', true);
181
+
182
+ content: '';
183
+ width: px-to-rem(map.get($count-icon, 'width'));
184
+ height: px-to-rem(map.get($count-icon, 'width'));
185
+ background: currentcolor;
186
+ position: relative;
187
+ top: px-to-rem(map.get($count-icon, 'offset'));
188
+ margin: 0 px-to-rem(map.get($count-icon, 'margin-horizontal'));
189
+ display: inline-block;
190
+ }
191
+ }
176
192
  }
@@ -27,7 +27,7 @@
27
27
  background: map.get($theme, 'button_primary_bg_hover');
28
28
  }
29
29
 
30
- &:active {
30
+ &:active, &.active {
31
31
  background: map.get($theme, 'button_primary_bg_active');
32
32
  }
33
33
 
@@ -71,6 +71,8 @@
71
71
  }
72
72
 
73
73
  &.secondary {
74
+ @include transition(background color border-color);
75
+
74
76
  background: map.get($theme, 'button_secondary_bg');
75
77
  border: px-to-rem(map.get($secondary, 'border')) solid map.get($theme, 'button_secondary_border');
76
78
 
@@ -96,14 +98,24 @@
96
98
  &.muted {
97
99
  border-color: map.get($theme, 'button_secondary_border_muted');
98
100
 
99
- &, &:hover, &:active, &:focus, &:focus-visible {
101
+ &, &:active {
100
102
  background: map.get($theme, 'button_secondary_bg_muted');
101
103
  color: map.get($theme, 'button_secondary_muted');
102
104
  }
103
105
 
104
- &:hover, &:focus, &:focus-visible {
105
- color: map.get($theme, 'button_secondary_muted_hover');
106
- }
106
+ &:hover, &:focus, &:focus-visible {
107
+ background: map.get($theme, 'button_secondary_bg_muted_hover');
108
+ color: map.get($theme, 'button_secondary_muted_hover');
109
+ border-color: map.get($theme, 'button_secondary_border_muted_hover');
110
+ }
111
+ }
112
+
113
+ &.destructive {
114
+ &, &:hover, &:active, &:focus, &:focus-visible {
115
+ background: map.get($theme, 'button_secondary_bg_destructive');
116
+ color: map.get($theme, 'button_secondary_destructive');
117
+ border-color: map.get($theme, 'button_secondary_border_destructive');
118
+ }
107
119
  }
108
120
 
109
121
  &.disabled {
@@ -245,6 +257,47 @@
245
257
  opacity: 0.3;
246
258
  }
247
259
 
260
+ &[data-hover-text] {
261
+ position: relative;
262
+
263
+ &::before, .text {
264
+ @include transition(opacity);
265
+
266
+ opacity: 1;
267
+ }
268
+
269
+ &::after {
270
+ @include transition(width height opacity right, 0s 0s 0.2s 0.2s, ease-in-out, 0s 0s 0.1s 0.1s);
271
+
272
+ content: '';
273
+ width: 0;
274
+ height: 0;
275
+ position: absolute;
276
+ top: px-to-rem(map.get($secondary-destruction, 'offset'));
277
+ right: map.get($secondary-destruction, 'right');
278
+ display: flex;
279
+ align-items: center;
280
+ justify-content: center;
281
+ opacity: 0;
282
+ }
283
+
284
+ &:hover, &:focus {
285
+ &::before, .text {
286
+ opacity: 0;
287
+ }
288
+
289
+ &::after {
290
+ content: attr(data-hover-text);
291
+ width: 100%;
292
+ height: 100%;
293
+ right: 0;
294
+ opacity: 1;
295
+ }
296
+
297
+ }
298
+
299
+ }
300
+
248
301
  }
249
302
  }
250
303
 
@@ -14,11 +14,18 @@ $icons: ('arrow_left', (d, d, 3, 8), (d, d, 3, 8), (d, d, 4, 7)),
14
14
  ('arrow-down', (d, d, 4, 10), (d, d, 3, 8), (d, d, 4, d)),
15
15
  ('chevron_left', (16, 16, 4, 8), (14, 14, 3, 8), (14, 14, d, d)),
16
16
  ('chevron_right', (16, 16, 4, 8), (14, 14, 3, 8), (14, 14, d, d)),
17
+ ('close', (48, 48, 0, 0), (32, 32, 0, 0), (24, 24, 0, 0)),
18
+ ('ellipsis', (48, 48, 0, 0), (32, 32, 0, 0), (16, 16, 0, 0)),
19
+ ('flag', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
17
20
  ('heart', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
18
21
  ('heart_empty', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
19
22
  ('navigation_arrow', (d, d, 4, 10), (d, d, d, d), (14, 14, d, 10)),
20
23
  ('pencil', (d, d, d, d), (d, d, d, 11), (d, d, 3, 9)),
24
+ ('pencil-paper', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
25
+ ('plus', (d, d, 4, d), (d, d, 2, d), (11, 11, 3, d)),
26
+ ('share', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
21
27
  ('speech-bubble_square_thick', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10)),
22
28
  ('star', (16, 16, 0, 0), (d, d, 0, 0), (16, 16, 0, 0)),
23
29
  ('star_empty', (16, 16, 0, 0), (d, d, 0, 0), (16, 16, 0, 0)),
24
- ('tick', (14, 11, 8, 10), (14, 11, 5, 8), (9, 7, 6, 6));
30
+ ('tick', (14, 11, 8, 10), (14, 11, 5, 8), (9, 7, 6, 6)),
31
+ ('trash', (22, 22, 0, 10), (18, 18, 1, d), (d, d, 3, 10));
@@ -4,6 +4,7 @@ $medium: ('font-size': 16, 'padding-top': 10, 'padding-horizontal': 24, 'padding
4
4
  $small: ('font-size': 14, 'padding-top': 8, 'padding-horizontal': 16, 'padding-bottom': 10, 'icon-width': 12, 'icon-offset': 2, 'icon-gutter': 8);
5
5
  $sizes: ('large', $large), ('small', $small);
6
6
  $secondary: ('border': 1);
7
+ $secondary-destruction: ('right': -5%, 'offset': -1);
7
8
 
8
9
  // The tertiary styling has its own padding; regardless of size, we add a tiny amount of padding to accommodate
9
10
  // the focus outline and to ensure any icons are centered
@@ -33,18 +33,23 @@ $theme: (
33
33
  button_secondary: map.get($c, 'b700'),
34
34
  button_secondary_focus: map.get($c, 'white'),
35
35
  button_secondary_muted: map.get($c, 'n600'),
36
- button_secondary_muted_hover: map.get($c, 'b700'),
36
+ button_secondary_muted_hover: map.get($c, 'n700'),
37
+ button_secondary_destructive: map.get($c, 'error600'),
37
38
  button_secondary_disabled: map.get($c, 'b700'),
38
39
  button_secondary_bg: map.get($c, 'white'),
39
40
  button_secondary_bg_hover: map.get($c, 'b200'),
40
41
  button_secondary_bg_focus: map.get($c, 'b600'),
41
42
  button_secondary_bg_active: map.get($c, 'b800'),
42
43
  button_secondary_bg_muted: map.get($c, 'white'),
44
+ button_secondary_bg_muted_hover: map.get($c, 'n200'),
43
45
  button_secondary_bg_disabled: map.get($c, 'white'),
46
+ button_secondary_bg_destructive: map.get($c, 'error50'),
44
47
  button_secondary_border: map.get($c, 'b700'),
45
48
  button_secondary_border_focus: transparent,
46
49
  button_secondary_border_muted: map.get($c, 'n200'),
50
+ button_secondary_border_muted_hover: map.get($c, 'n500'),
47
51
  button_secondary_border_disabled: map.get($c, 'b700'),
52
+ button_secondary_border_destructive: map.get($c, 'error600'),
48
53
 
49
54
  button_tertiary: map.get($c, 'b700'),
50
55
  button_tertiary_hover: map.get($c, 'b500'),
@@ -102,15 +107,25 @@ $theme: (
102
107
  marketing-block_secondary_bg_2: map.get($c, 'g100'),
103
108
  marketing-block_tertiary_bg_2: map.get($c, 'p600'),
104
109
 
110
+ // Communities
111
+ community-details_link_hover: map.get($c, 'b500'),
112
+
105
113
  // Discussion
114
+ discussion-actions: map.get($c, 'n600'),
115
+ discussion-actions_hover_bg: map.get($c, 'b100'),
116
+ discussion-actions_likes_liked: map.get($c, 'p500'),
117
+ discussion-actions_likes_liked_bg: map.get($c, 'p500'),
118
+
106
119
  discussion-form_bg: map.get($c, 'b50'),
107
120
  discussion-form_placeholder: map.get($c, 'n500'),
108
121
  discussion-form_small: map.get($c, 'n700'),
109
122
 
110
- discussion-likes: map.get($c, 'n600'),
111
- discussion-likes_hover_bg: map.get($c, 'b100'),
112
- discussion-likes_liked: map.get($c, 'p500'),
113
- discussion-likes_liked_bg: map.get($c, 'p500'),
123
+ discussion-question_bg: map.get($c, 'sand'),
124
+
125
+ discussion-responses-heading_p: map.get($c, 'n600'),
126
+ discussion-responses-heading_icon: map.get($c, 'n700'),
127
+
128
+ discussion-thread_border: map.get($c, 'n200'),
114
129
 
115
130
  // Form
116
131
  password-rules: map.get($c, 'error600'),
@@ -127,6 +142,10 @@ $theme: (
127
142
  search_search-button_bg: map.get($c, 'n600'),
128
143
  search_search-button_active_bg: map.get($c, 'white'),
129
144
 
145
+ // General
146
+ tooltip: map.get($c, 'white'),
147
+ tooltip_bg: rgb(21 25 33 / 90%),
148
+
130
149
  // Layout
131
150
  cookie-banner_bg: map.get($c, 'n50'),
132
151
  cookie-banner_shadow: rgb(107 91 82 / 40%),
@@ -186,8 +205,13 @@ $theme: (
186
205
  // Modals
187
206
  modal_bg: map.get($c, 'white'),
188
207
  modal_shadow: rgba(42 49 65 / 30%),
208
+ modal_close: map.get($c, 'n700'),
209
+ modal_close_hover_bg: map.get($c, 'b100'),
189
210
 
190
211
  // Navigation
212
+ breadcrumbs: map.get($c, 'n600'),
213
+ breadcrumbs_hover: map.get($c, 'b500'),
214
+
191
215
  filters: map.get($c, 'n700'),
192
216
  filters_selected: map.get($c, 'g700'),
193
217
  filters_active: map.get($c, 'n700'),
@@ -198,14 +222,16 @@ $theme: (
198
222
  filters_outline: map.get($c, 'n200'),
199
223
  filters_selected_outline: map.get($c, 'g200'),
200
224
 
225
+ more-menu: map.get($c, 'n700'),
226
+ more-menu_hover_button_bg: map.get($c, 'b100'),
227
+ more-menu_menu_bg: map.get($c, 'white'),
228
+ more-menu_menu_shadow: rgba(0 0 0 / 10%),
229
+
201
230
  tags: map.get($c, 'b700'),
202
231
  tags_light: map.get($c, 'p500'),
203
232
 
204
233
 
205
234
  // Text
206
- alert_success: map.get($c, 'success600'),
207
- alert_error: map.get($c, 'error600'),
208
-
209
235
  collapsible-section_bg: map.get($c, 'white'),
210
236
  collapsible-section_border: map.get($c, 'n500'),
211
237
  collapsible-section_icon: map.get($c, 'n900'),
@@ -231,12 +257,21 @@ $theme: (
231
257
 
232
258
  highlighted-text-box_subtle_border: map.get($c, 'n100'),
233
259
 
234
- pill: map.get($c, 'n700'),
235
- pill_bg: map.get($c, 'y300'),
260
+ pill: map.get($c, 'n900'),
261
+ pill_highlighted: map.get($c, 'n700'),
262
+ pill_bg: map.get($c, 'n200'),
263
+ pill_highlighted_bg: map.get($c, 'y300'),
264
+
265
+ status-banner_bg: map.get($c, 'y50'),
266
+ status-banner_success_bg: map.get($c, 'success50'),
267
+ status-banner_success_icon: map.get($c, 'success600'),
268
+ status-banner_error_bg: map.get($c, 'error50'),
269
+ status-banner_error_icon: map.get($c, 'error600'),
236
270
 
237
271
  // User
238
272
  contributor: map.get($c, 'n700'),
239
273
  contributor_bg: map.get($c, 'white'),
274
+ contributor_medium_bg: map.get($c, 'n200'),
240
275
  contributor_border: map.get($c, 'white'),
241
276
  contributor_inner-border: map.get($c, 'n200'),
242
277
  contributor_label: map.get($c, 'n600'),
@@ -1,9 +1,11 @@
1
+ import React from 'react';
1
2
  import { ButtonPropsType } from '../../general';
2
3
  interface ButtonType extends ButtonPropsType {
3
- text: string;
4
+ text?: string;
4
5
  breakpoints?: {
5
6
  [key: string]: boolean;
6
7
  };
8
+ component?: React.ReactNode;
7
9
  }
8
10
  interface Props {
9
11
  /** Box styling */
@@ -8,7 +8,7 @@ interface Props {
8
8
  /** The heading to display at the top of the box */
9
9
  heading?: string | false;
10
10
  /** The content to display in the box */
11
- children: React.ReactNode;
11
+ children: React.ReactNode | JSX.Element | string;
12
12
  }
13
13
  declare const HelperTextBox: ({ type, className, heading, children }: Props) => import("react/jsx-runtime").JSX.Element;
14
14
  export default HelperTextBox;
package/text/index.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- export * from './alert';
2
1
  export * from './collapsible-section';
3
2
  export * from './empty-state-box';
4
3
  export * from './helper-text-box';
@@ -6,3 +5,4 @@ export * from './hide-show-text-box';
6
5
  export * from './highlighted-text-box';
7
6
  export * from './markdown-text';
8
7
  export * from './pill';
8
+ export * from './status-banner';
@@ -1,9 +1,13 @@
1
1
  import React from 'react';
2
2
  interface Props {
3
+ /** The size of the pill */
4
+ size?: 'medium' | 'large';
5
+ /** The style of the pill */
6
+ variant?: 'default' | 'highlighted';
3
7
  /** Additional classes to add to the pill */
4
8
  className?: 'margin-left' | 'margin-right' | '';
5
9
  /** The pill text */
6
10
  children: React.ReactNode;
7
11
  }
8
- declare const Pill: ({ className, children }: Props) => import("react/jsx-runtime").JSX.Element;
12
+ declare const Pill: ({ size, variant, className, children }: Props) => import("react/jsx-runtime").JSX.Element;
9
13
  export default Pill;
@@ -0,0 +1 @@
1
+ export { default as StatusBanner } from './status-banner';
@@ -11,7 +11,7 @@ interface Props {
11
11
  /** Test ID for Jest tests */
12
12
  'data-testid'?: string;
13
13
  }
14
- declare const Alert: ({ element, children, className, ...props }: Props) => React.DetailedReactHTMLElement<{
14
+ declare const StatusBanner: ({ element, children, className, ...props }: Props) => React.DetailedReactHTMLElement<{
15
15
  className: string;
16
16
  'aria-live': "assertive";
17
17
  /** Optional ID, for errors */
@@ -19,4 +19,4 @@ declare const Alert: ({ element, children, className, ...props }: Props) => Reac
19
19
  /** Test ID for Jest tests */
20
20
  'data-testid'?: string | undefined;
21
21
  }, HTMLElement>;
22
- export default Alert;
22
+ export default StatusBanner;
@@ -4,7 +4,10 @@ interface Props {
4
4
  /** The element that will render around the content */
5
5
  element?: 'div' | 'section' | 'aside' | 'li';
6
6
  /** Information about the contributors */
7
- contributors: Array<MemberProps>;
7
+ contributors: {
8
+ total?: number;
9
+ data: Array<MemberProps>;
10
+ };
8
11
  /** Information on the style of the component */
9
12
  styling?: {
10
13
  /** The size of the images */
@@ -23,7 +26,7 @@ interface Props {
23
26
  /** The language to use */
24
27
  locale?: string;
25
28
  }
26
- declare const Contributors: ({ element, contributors, styling: { showText, size, showGap, showPlaceholders }, cutoff, className }: Props) => React.DetailedReactHTMLElement<{
29
+ declare const Contributors: ({ element, contributors: { total, data: contributors }, styling: { showText, size, showGap, showPlaceholders }, cutoff, className }: Props) => React.DetailedReactHTMLElement<{
27
30
  className: string;
28
31
  children: import("react/jsx-runtime").JSX.Element;
29
32
  }, HTMLElement> | null;
@@ -1,11 +1,14 @@
1
1
  declare const _default: {
2
2
  element: string;
3
3
  contributors: {
4
- name: string;
5
- image: {
6
- thumbnail: string;
7
- };
8
- }[];
4
+ total: number;
5
+ data: {
6
+ name: string;
7
+ image: {
8
+ thumbnail: string;
9
+ };
10
+ }[];
11
+ };
9
12
  styling: {
10
13
  showText: string;
11
14
  };
@@ -1,3 +1,3 @@
1
- export type { MemberProps } from './member';
1
+ export type { MemberProps, MemberDetailsProps } from './member';
2
2
  export { default as Member } from './member';
3
3
  export { getMember } from './member.helpers';
@@ -1,17 +1,26 @@
1
- export type MemberProps = 'apolitical' | 'community' | {
1
+ import React from 'react';
2
+ export type MemberDetailsProps = {
3
+ /** The user's unique ID */
2
4
  id?: string;
3
- slug?: string;
5
+ /** The user's name */
4
6
  name?: string;
7
+ /** The user's job title */
5
8
  jobTitle?: string;
9
+ /** The organisation the user works for */
6
10
  organization?: string;
11
+ /** The user's location */
7
12
  location?: {
8
13
  country?: string;
9
14
  };
15
+ /** The user's profile picture */
10
16
  image?: {
11
17
  thumbnail?: string;
12
18
  };
13
19
  };
20
+ export type MemberProps = 'apolitical' | 'community' | MemberDetailsProps;
14
21
  interface Props {
22
+ /** The element to render around the content */
23
+ element?: 'li' | 'div';
15
24
  /** Details about the Apolitical member */
16
25
  member?: MemberProps;
17
26
  /** Additional content to show with the member details */
@@ -28,5 +37,8 @@ interface Props {
28
37
  /** The language to use for the text */
29
38
  locale?: string;
30
39
  }
31
- declare const Member: ({ member: memberDetails, additionalContent, gtmContext, gtmType, className, }: Props) => import("react/jsx-runtime").JSX.Element;
40
+ declare const Member: ({ element, member: memberDetails, additionalContent, gtmContext, gtmType, className, }: Props) => React.DetailedReactHTMLElement<{
41
+ className: string;
42
+ children: import("react/jsx-runtime").JSX.Element;
43
+ }, HTMLElement>;
32
44
  export default Member;
@@ -1 +0,0 @@
1
- export { default as Alert } from './alert';