@abgov/react-components 7.1.0 → 7.2.0-dev.2
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/index.js +28 -11
- package/index.js.map +1 -1
- package/index.mjs +28 -11
- package/index.mjs.map +1 -1
- package/lib/chip/chip.d.ts +7 -7
- package/lib/container/container.d.ts +2 -2
- package/lib/dropdown/dropdown.d.ts +1 -1
- package/lib/hero-banner/hero-banner.d.ts +3 -1
- package/lib/input/input.d.ts +1 -0
- package/lib/microsite-header/microsite-header.d.ts +1 -1
- package/lib/radio-group/radio.d.ts +1 -1
- package/lib/tab/tab.d.ts +2 -2
- package/lib/table/table.d.ts +0 -1
- package/lib/tooltip/tooltip.d.ts +1 -1
- package/package.json +1 -1
package/lib/chip/chip.d.ts
CHANGED
|
@@ -18,19 +18,19 @@ declare module "react" {
|
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
export interface GoabChipProps extends Margins, DataAttributes {
|
|
21
|
-
/** @required @deprecated Use
|
|
21
|
+
/** @required @deprecated Use GoabFilterChip instead. The text content displayed in the chip. */
|
|
22
22
|
content: string;
|
|
23
|
-
/** @deprecated Use
|
|
23
|
+
/** @deprecated Use GoabFilterChip instead. When true, shows a delete icon and makes chip clickable. */
|
|
24
24
|
deletable?: boolean;
|
|
25
|
-
/** @deprecated Use
|
|
25
|
+
/** @deprecated Use GoabFilterChip instead. Icon displayed at the start of the chip. */
|
|
26
26
|
leadingIcon?: string;
|
|
27
|
-
/** @deprecated Use
|
|
27
|
+
/** @deprecated Use GoabFilterChip instead. The icon theme - outline or filled. */
|
|
28
28
|
iconTheme?: GoabChipTheme;
|
|
29
|
-
/** @deprecated Use
|
|
29
|
+
/** @deprecated Use GoabFilterChip instead. Shows an error state on the chip. */
|
|
30
30
|
error?: boolean;
|
|
31
|
-
/** @deprecated Use
|
|
31
|
+
/** @deprecated Use GoabFilterChip instead. The chip variant style. */
|
|
32
32
|
variant?: GoabChipVariant;
|
|
33
|
-
/** @deprecated Use
|
|
33
|
+
/** @deprecated Use GoabFilterChip instead. Sets a data-testid attribute for automated testing. */
|
|
34
34
|
testId?: string;
|
|
35
35
|
/** Callback fired when the chip is clicked or deleted. */
|
|
36
36
|
onClick?: () => void;
|
|
@@ -34,9 +34,9 @@ export interface GoabContainerProps extends Margins, DataAttributes {
|
|
|
34
34
|
maxHeight?: string;
|
|
35
35
|
/** Sets a data-testid attribute for automated testing. */
|
|
36
36
|
testId?: string;
|
|
37
|
-
/**
|
|
37
|
+
/** @deprecated Use title instead. Alias for the title prop. */
|
|
38
38
|
heading?: ReactNode;
|
|
39
|
-
/**
|
|
39
|
+
/** Content rendered in the container's title/heading area. */
|
|
40
40
|
title?: ReactNode;
|
|
41
41
|
/** Content rendered in the container's actions area, typically buttons or controls. */
|
|
42
42
|
actions?: ReactNode;
|
|
@@ -56,7 +56,7 @@ export interface GoabDropdownProps extends Margins, DataAttributes {
|
|
|
56
56
|
leadingIcon?: GoabIconType;
|
|
57
57
|
/** Maximum height of the dropdown menu. Non-native only. @default "276px" */
|
|
58
58
|
maxHeight?: string;
|
|
59
|
-
/** When true, allows multiple items to be selected. */
|
|
59
|
+
/** When true, allows multiple items to be selected. @internal */
|
|
60
60
|
multiselect?: boolean;
|
|
61
61
|
/** When true, renders the native select HTML element. */
|
|
62
62
|
native?: boolean;
|
|
@@ -26,6 +26,8 @@ export interface GoabHeroBannerProps {
|
|
|
26
26
|
testId?: string;
|
|
27
27
|
/** Content rendered inside the hero banner body. */
|
|
28
28
|
children?: React.ReactNode;
|
|
29
|
+
/** Content rendered in the actions slot. */
|
|
30
|
+
actions?: React.ReactNode;
|
|
29
31
|
/** Maximum width of the content area. @default "100%" */
|
|
30
32
|
maxContentWidth?: string;
|
|
31
33
|
/** Hero Banner background color when no background image is provided. @default "#f8f8f8" */
|
|
@@ -34,5 +36,5 @@ export interface GoabHeroBannerProps {
|
|
|
34
36
|
textColor?: string;
|
|
35
37
|
}
|
|
36
38
|
/** A visual band of text, including an image and a call to action. */
|
|
37
|
-
export declare function GoabHeroBanner({ heading, backgroundUrl, minHeight, maxContentWidth, backgroundColor, textColor, children, testId, }: GoabHeroBannerProps): JSX.Element;
|
|
39
|
+
export declare function GoabHeroBanner({ heading, backgroundUrl, minHeight, maxContentWidth, backgroundColor, textColor, children, actions, testId, }: GoabHeroBannerProps): JSX.Element;
|
|
38
40
|
export default GoabHeroBanner;
|
package/lib/input/input.d.ts
CHANGED
|
@@ -136,6 +136,7 @@ interface GoabDateInputProps extends BaseProps {
|
|
|
136
136
|
}
|
|
137
137
|
/** A single-line field where users can input and edit text. */
|
|
138
138
|
export declare function GoabInput({ variant, textAlign, size, focused, disabled, readonly, error, leadingContent, trailingContent, onTrailingIconClick, onChange, onFocus, onBlur, onKeyPress, ...rest }: GoabInputProps & {
|
|
139
|
+
/** Sets the type of the input field. @default "text" */
|
|
139
140
|
type?: GoabInputType;
|
|
140
141
|
}): JSX.Element;
|
|
141
142
|
/** A single-line field where users can input and edit text. */
|
|
@@ -21,7 +21,7 @@ interface WCProps {
|
|
|
21
21
|
export interface GoabHeaderProps {
|
|
22
22
|
/** @required The service type which determines the badge style. "live" shows official government site text, "alpha" and "beta" show development stage badges. */
|
|
23
23
|
type: GoabServiceLevel;
|
|
24
|
-
/** App or service version displayed on the right side of the header.
|
|
24
|
+
/** App or service version displayed on the right side of the header. */
|
|
25
25
|
version?: string | React.ReactNode;
|
|
26
26
|
/** URL to a feedback page displayed when provided. */
|
|
27
27
|
feedbackUrl?: string;
|
|
@@ -39,7 +39,7 @@ export interface GoabRadioItemProps extends Margins {
|
|
|
39
39
|
maxWidth?: string;
|
|
40
40
|
/** Disables this radio option. Also disabled if the parent RadioGroup is disabled. */
|
|
41
41
|
disabled?: boolean;
|
|
42
|
-
/** Sets this radio option as checked/selected. */
|
|
42
|
+
/** @internal Sets this radio option as checked/selected. */
|
|
43
43
|
checked?: boolean;
|
|
44
44
|
/** Shows an error state on this radio option. */
|
|
45
45
|
error?: boolean;
|
package/lib/tab/tab.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
2
|
interface WCProps {
|
|
3
|
-
heading?: React.ReactNode;
|
|
3
|
+
heading?: string | React.ReactNode;
|
|
4
4
|
disabled?: string;
|
|
5
5
|
slug?: string;
|
|
6
6
|
}
|
|
@@ -13,7 +13,7 @@ declare module "react" {
|
|
|
13
13
|
}
|
|
14
14
|
export interface GoabTabItemProps {
|
|
15
15
|
/** The text label for this tab. Can also pass React nodes for custom heading content. */
|
|
16
|
-
heading?: React.ReactNode;
|
|
16
|
+
heading?: string | React.ReactNode;
|
|
17
17
|
/** When true, disables the tab so it cannot be selected. */
|
|
18
18
|
disabled?: boolean;
|
|
19
19
|
/** Content rendered inside the tab panel. */
|
package/lib/table/table.d.ts
CHANGED
package/lib/tooltip/tooltip.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ declare module "react" {
|
|
|
17
17
|
export interface GoabTooltipProps extends Margins, DataAttributes {
|
|
18
18
|
/** Position of the tooltip with respect to the child element. @default "top" */
|
|
19
19
|
position?: GoabTooltipPosition;
|
|
20
|
-
/** The content of the tooltip. Accepts
|
|
20
|
+
/** The content of the tooltip. Accepts plain text or rich content. */
|
|
21
21
|
content?: string | ReactNode;
|
|
22
22
|
/** Horizontal alignment of the tooltip relative to the child element. @default "center" */
|
|
23
23
|
hAlign?: GoabTooltipHorizontalAlignment;
|