@apolitical/component-library 1.3.1 → 1.3.3

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.
@@ -2,13 +2,18 @@ import React from 'react';
2
2
  import { ResponsiveImageType } from '../../general';
3
3
  declare const allowedElements: string[];
4
4
  interface ContentPropObject {
5
+ /** The text to display */
5
6
  text: string;
7
+ /** The element to wrap the text in */
6
8
  element?: typeof allowedElements[number];
7
9
  }
8
10
  type ContentPropType = false | string | ContentPropObject;
9
11
  interface ContentType {
12
+ /** Eyebrow text, above the title */
10
13
  eyebrow?: ContentPropType;
14
+ /** The title */
11
15
  title?: ContentPropType;
16
+ /** The main text */
12
17
  text?: ContentPropType;
13
18
  }
14
19
  export interface BannerSectionType {
@@ -18,6 +23,8 @@ export interface BannerSectionType {
18
23
  image?: ResponsiveImageType;
19
24
  /** The colour variant (when there's no image) */
20
25
  variant?: 'default' | 'light';
26
+ /** How to handle spacing on the banner */
27
+ spacing?: 'normal' | 'compact';
21
28
  /** The CTA to display */
22
29
  cta?: {
23
30
  text: string;
@@ -29,5 +36,5 @@ export interface BannerSectionType {
29
36
  /** Any additional children */
30
37
  children?: React.ReactNode;
31
38
  }
32
- declare const _default: React.MemoExoticComponent<({ content: contentProp, image, variant, cta, children }: BannerSectionType) => import("react/jsx-runtime").JSX.Element>;
39
+ declare const _default: React.MemoExoticComponent<({ content: contentProp, image, variant, spacing, cta, children }: BannerSectionType) => import("react/jsx-runtime").JSX.Element>;
33
40
  export default _default;
package/index.d.ts CHANGED
@@ -1,13 +1,15 @@
1
1
  export * from './accessibility';
2
2
  export * from './banners';
3
- export * from './general';
3
+ export * from './communities';
4
4
  export * from './constants';
5
5
  export * from './context';
6
6
  export * from './discussion';
7
7
  export * from './form';
8
+ export * from './general';
8
9
  export * from './hooks';
9
10
  export * from './layout';
10
11
  export * from './loaders';
12
+ export * from './modals';
11
13
  export * from './navigation';
12
14
  export * from './sections';
13
15
  export * from './text';