@abgov/react-components 6.11.0 → 7.0.0-dev.1
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.d.ts +5 -0
- package/index.js +3084 -1074
- package/index.js.map +1 -1
- package/index.mjs +3680 -1670
- package/index.mjs.map +1 -1
- package/lib/app-header/app-header.d.ts +5 -2
- package/lib/app-header-menu/app-header-menu.d.ts +8 -7
- package/lib/badge/badge.d.ts +23 -18
- package/lib/button/button.d.ts +23 -0
- package/lib/calendar/calendar.d.ts +17 -0
- package/lib/callout/callout.d.ts +21 -2
- package/lib/checkbox/checkbox.d.ts +30 -2
- package/lib/checkbox-list/checkbox-list.d.ts +11 -8
- package/lib/date-picker/date-picker.d.ts +22 -0
- package/lib/drawer/drawer.d.ts +16 -0
- package/lib/dropdown/dropdown-item.d.ts +15 -0
- package/lib/dropdown/dropdown.d.ts +34 -2
- package/lib/file-upload-card/file-upload-card.d.ts +18 -0
- package/lib/file-upload-input/file-upload-input.d.ts +16 -0
- package/lib/filter-chip/filter-chip.d.ts +21 -1
- package/lib/footer/footer.d.ts +13 -1
- package/lib/footer-meta-section/footer-meta-section.d.ts +10 -0
- package/lib/footer-nav-section/footer-nav-section.d.ts +12 -0
- package/lib/form-item/form-item.d.ts +24 -2
- package/lib/input/input.d.ts +43 -2
- package/lib/link/link.d.ts +22 -3
- package/lib/menu-button/menu-button.d.ts +9 -52
- package/lib/modal/modal.d.ts +24 -1
- package/lib/notification/notification.d.ts +21 -2
- package/lib/pagination/pagination.d.ts +16 -0
- package/lib/push-drawer/push-drawer.d.ts +7 -6
- package/lib/radio-group/radio-group.d.ts +24 -2
- package/lib/radio-group/radio.d.ts +24 -1
- package/lib/side-menu/side-menu.d.ts +12 -1
- package/lib/side-menu-group/side-menu-group.d.ts +14 -1
- package/lib/side-menu-heading/side-menu-heading.d.ts +13 -1
- package/lib/table/table-sort-header.d.ts +15 -2
- package/lib/table/table.d.ts +22 -2
- package/lib/tabs/tabs.d.ts +22 -2
- package/lib/textarea/textarea.d.ts +29 -1
- package/{experimental → lib}/work-side-menu/work-side-menu.d.ts +3 -2
- package/{experimental → lib}/work-side-menu-group/work-side-menu-group.d.ts +6 -4
- package/{experimental → lib}/work-side-menu-item/work-side-menu-item.d.ts +5 -4
- package/lib/work-side-notification-item/work-side-notification-item.d.ts +31 -0
- package/lib/work-side-notification-panel/work-side-notification-panel.d.ts +25 -0
- package/package.json +1 -6
- package/experimental/badge/badge.d.ts +0 -33
- package/experimental/button/button.d.ts +0 -43
- package/experimental/calendar/calendar.d.ts +0 -30
- package/experimental/callout/callout.d.ts +0 -33
- package/experimental/checkbox/checkbox.d.ts +0 -52
- package/experimental/date-picker/date-picker.d.ts +0 -43
- package/experimental/drawer/drawer.d.ts +0 -31
- package/experimental/dropdown/dropdown-item.d.ts +0 -26
- package/experimental/dropdown/dropdown.d.ts +0 -62
- package/experimental/file-upload-card/file-upload-card.d.ts +0 -32
- package/experimental/file-upload-input/file-upload-input.d.ts +0 -27
- package/experimental/filter-chip/filter-chip.d.ts +0 -31
- package/experimental/footer/footer.d.ts +0 -24
- package/experimental/footer-meta-section/footer-meta-section.d.ts +0 -18
- package/experimental/footer-nav-section/footer-nav-section.d.ts +0 -22
- package/experimental/form-hook.d.ts +0 -8
- package/experimental/form-item/form-item.d.ts +0 -46
- package/experimental/index.d.ts +0 -32
- package/experimental/input/input.d.ts +0 -124
- package/experimental/link/link.d.ts +0 -32
- package/experimental/modal/modal.d.ts +0 -44
- package/experimental/notification/notification.d.ts +0 -31
- package/experimental/pagination/pagination.d.ts +0 -29
- package/experimental/radio-group/radio-group.d.ts +0 -40
- package/experimental/radio-group/radio.d.ts +0 -42
- package/experimental/side-menu/side-menu.d.ts +0 -19
- package/experimental/side-menu-group/side-menu-group.d.ts +0 -24
- package/experimental/side-menu-heading/side-menu-heading.d.ts +0 -23
- package/experimental/table/table-sort-header.d.ts +0 -20
- package/experimental/table/table.d.ts +0 -30
- package/experimental/tabs/tabs.d.ts +0 -27
- package/experimental/textarea/textarea.d.ts +0 -53
- package/experimental.js +0 -1245
- package/experimental.js.map +0 -1
- package/experimental.mjs +0 -1245
- package/experimental.mjs.map +0 -1
- package/parseISO-BHUUf1QW.mjs +0 -1693
- package/parseISO-BHUUf1QW.mjs.map +0 -1
- package/parseISO-Dj57mwuH.js +0 -1692
- package/parseISO-Dj57mwuH.js.map +0 -1
package/lib/link/link.d.ts
CHANGED
|
@@ -1,13 +1,32 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { GoabIconType, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
3
|
-
interface
|
|
2
|
+
import { GoabIconType, GoabLinkColor, GoabLinkSize, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
3
|
+
interface WCProps extends Margins {
|
|
4
|
+
leadingicon?: GoabIconType;
|
|
5
|
+
trailingicon?: GoabIconType;
|
|
6
|
+
action?: string;
|
|
7
|
+
actionArgs?: string;
|
|
8
|
+
actionArg?: string;
|
|
9
|
+
testid?: string;
|
|
10
|
+
color?: GoabLinkColor;
|
|
11
|
+
size?: GoabLinkSize;
|
|
12
|
+
}
|
|
13
|
+
declare module "react" {
|
|
14
|
+
namespace JSX {
|
|
15
|
+
interface IntrinsicElements {
|
|
16
|
+
"goa-link": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
export interface GoabLinkProps extends Margins, DataAttributes {
|
|
4
21
|
leadingIcon?: GoabIconType;
|
|
5
22
|
trailingIcon?: GoabIconType;
|
|
6
23
|
action?: string;
|
|
7
24
|
actionArgs?: Record<string, unknown>;
|
|
8
25
|
actionArg?: string;
|
|
26
|
+
color?: GoabLinkColor;
|
|
27
|
+
size?: GoabLinkSize;
|
|
9
28
|
testId?: string;
|
|
10
29
|
children: ReactNode;
|
|
11
30
|
}
|
|
12
|
-
export declare function GoabLink({ actionArgs, actionArg, children, ...rest }: GoabLinkProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare function GoabLink({ actionArgs, actionArg, color, size, children, ...rest }: GoabLinkProps): import("react/jsx-runtime").JSX.Element;
|
|
13
32
|
export default GoabLink;
|
|
@@ -1,27 +1,16 @@
|
|
|
1
|
-
import { DataAttributes, GoabButtonType, GoabIconType, GoabMenuButtonOnActionDetail } from '@abgov/ui-components-common';
|
|
1
|
+
import { DataAttributes, GoabButtonSize, GoabButtonType, GoabButtonVariant, GoabIconType, GoabMenuButtonOnActionDetail } from '@abgov/ui-components-common';
|
|
2
2
|
import { ReactNode, JSX } from 'react';
|
|
3
|
-
/**
|
|
4
|
-
* Props definition for the `goab-menu-button` Web Component.
|
|
5
|
-
* @typedef {Object} WCProps
|
|
6
|
-
*
|
|
7
|
-
* @property {string} text - The text label to be displayed on the button.
|
|
8
|
-
* @property {GoabButtonType} type - The button type, e.g., "primary", "secondary", etc.
|
|
9
|
-
* @property {GoaIconType} leadingIcon - Optional leading icon appearing within the button.
|
|
10
|
-
* @property {string} [testid] - A test identifier for automated testing purposes.
|
|
11
|
-
* @property {React.RefObject<HTMLElement | null>} ref - A reference object pointing to the Web Component's DOM element.
|
|
12
|
-
*/
|
|
13
3
|
interface WCProps {
|
|
14
|
-
text
|
|
4
|
+
text?: string;
|
|
15
5
|
type: GoabButtonType;
|
|
6
|
+
size?: GoabButtonSize;
|
|
7
|
+
variant?: GoabButtonVariant;
|
|
16
8
|
"max-width"?: string;
|
|
17
9
|
"leading-icon"?: GoabIconType;
|
|
10
|
+
"aria-label"?: string;
|
|
18
11
|
testid?: string;
|
|
19
12
|
ref: React.RefObject<HTMLElement | null>;
|
|
20
13
|
}
|
|
21
|
-
/**
|
|
22
|
-
* Extends React's `JSX` namespace to include the custom `goa-menu-button` Web Component.
|
|
23
|
-
* The `goa-menu-button` supports additional React-specific props.
|
|
24
|
-
*/
|
|
25
14
|
declare module "react" {
|
|
26
15
|
namespace JSX {
|
|
27
16
|
interface IntrinsicElements {
|
|
@@ -29,49 +18,17 @@ declare module "react" {
|
|
|
29
18
|
}
|
|
30
19
|
}
|
|
31
20
|
}
|
|
32
|
-
/**
|
|
33
|
-
* Props for the `GoabMenuButton` React component.
|
|
34
|
-
*
|
|
35
|
-
* @typedef {Object} GoabMenuButtonProps
|
|
36
|
-
*
|
|
37
|
-
* @property {string} text - The text label to display on the button.
|
|
38
|
-
* @property {GoabButtonType} [type="primary"] - The button type, e.g., "primary", "secondary". Defaults to "primary".
|
|
39
|
-
* @property {GoaIconType} leadingIcon - Optional leading icon appearing within the button.
|
|
40
|
-
* @property {string} [testId] - A test identifier for automated testing purposes.
|
|
41
|
-
* @property {Function} [onAction] - Callback function invoked when an action event is emitted by the component.
|
|
42
|
-
* @property {ReactNode} [children] - Optional child elements to be rendered inside the button.
|
|
43
|
-
*/
|
|
44
21
|
export interface GoabMenuButtonProps extends DataAttributes {
|
|
45
|
-
text
|
|
22
|
+
text?: string;
|
|
46
23
|
type?: GoabButtonType;
|
|
24
|
+
size?: GoabButtonSize;
|
|
25
|
+
variant?: GoabButtonVariant;
|
|
47
26
|
maxWidth?: string;
|
|
48
27
|
leadingIcon?: GoabIconType;
|
|
28
|
+
ariaLabel?: string;
|
|
49
29
|
testId?: string;
|
|
50
30
|
onAction?: (detail: GoabMenuButtonOnActionDetail) => void;
|
|
51
31
|
children?: ReactNode;
|
|
52
32
|
}
|
|
53
|
-
/**
|
|
54
|
-
* A React wrapper component for the `goa-menu-button` Web Component.
|
|
55
|
-
*
|
|
56
|
-
* This component provides seamless integration of the Web Component into a React application, including React-specific props and event handling.
|
|
57
|
-
*
|
|
58
|
-
* @function GoabMenuButton
|
|
59
|
-
* @param {GoabMenuButtonProps} props - The props for the component.
|
|
60
|
-
*
|
|
61
|
-
* @returns {JSX.Element} A JSX element wrapping the `goa-menu-button` Web Component.
|
|
62
|
-
*
|
|
63
|
-
* @example
|
|
64
|
-
* ```tsx
|
|
65
|
-
* <GoabMenuButton
|
|
66
|
-
* text="Example Button"
|
|
67
|
-
* type="secondary"
|
|
68
|
-
* onAction={(action) => console.log(`Action: ${action}`)}
|
|
69
|
-
* >
|
|
70
|
-
* <GoabMenuAction text="Option 1" action="option1" />
|
|
71
|
-
* <GoabMenuAction text="Option 2" action="option2" />
|
|
72
|
-
* <GoabMenuAction text="Option 3" action="option3" />
|
|
73
|
-
* </GoabMenuButton>
|
|
74
|
-
* ```
|
|
75
|
-
*/
|
|
76
33
|
export declare function GoabMenuButton({ type, testId, onAction, children, ...rest }: GoabMenuButtonProps): JSX.Element;
|
|
77
34
|
export default GoabMenuButton;
|
package/lib/modal/modal.d.ts
CHANGED
|
@@ -1,5 +1,28 @@
|
|
|
1
1
|
import { GoabModalCalloutVariant, GoabModalRole, GoabModalTransition } from '@abgov/ui-components-common';
|
|
2
|
-
import { ReactElement, ReactNode, JSX } from 'react';
|
|
2
|
+
import { ReactElement, ReactNode, RefObject, JSX } from 'react';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
ref: RefObject<HTMLElement | null>;
|
|
5
|
+
heading?: ReactNode;
|
|
6
|
+
open?: string;
|
|
7
|
+
maxwidth?: string;
|
|
8
|
+
closable: string;
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated The role property is deprecated and will be removed in a future version.
|
|
11
|
+
* The modal will always use role="dialog".
|
|
12
|
+
*/
|
|
13
|
+
role?: GoabModalRole;
|
|
14
|
+
transition?: GoabModalTransition;
|
|
15
|
+
calloutvariant?: GoabModalCalloutVariant;
|
|
16
|
+
testid?: string;
|
|
17
|
+
version?: string;
|
|
18
|
+
}
|
|
19
|
+
declare module "react" {
|
|
20
|
+
namespace JSX {
|
|
21
|
+
interface IntrinsicElements {
|
|
22
|
+
"goa-modal": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
3
26
|
export interface GoabModalProps {
|
|
4
27
|
heading?: ReactNode;
|
|
5
28
|
maxWidth?: string;
|
|
@@ -1,11 +1,30 @@
|
|
|
1
|
-
import { GoabAriaLiveType, GoabNotificationType } from '@abgov/ui-components-common';
|
|
1
|
+
import { GoabAriaLiveType, GoabNotificationEmphasis, GoabNotificationType } from '@abgov/ui-components-common';
|
|
2
|
+
interface WCProps {
|
|
3
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
4
|
+
type: GoabNotificationType;
|
|
5
|
+
maxcontentwidth?: string;
|
|
6
|
+
arialive?: GoabAriaLiveType;
|
|
7
|
+
testid?: string;
|
|
8
|
+
emphasis?: GoabNotificationEmphasis;
|
|
9
|
+
compact?: string;
|
|
10
|
+
version?: string;
|
|
11
|
+
}
|
|
12
|
+
declare module "react" {
|
|
13
|
+
namespace JSX {
|
|
14
|
+
interface IntrinsicElements {
|
|
15
|
+
"goa-notification": WCProps & React.HTMLAttributes<HTMLButtonElement>;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
2
19
|
export interface GoabNotificationProps {
|
|
3
20
|
type?: GoabNotificationType;
|
|
4
21
|
ariaLive?: GoabAriaLiveType;
|
|
5
22
|
maxContentWidth?: string;
|
|
23
|
+
emphasis?: GoabNotificationEmphasis;
|
|
24
|
+
compact?: boolean;
|
|
6
25
|
children?: React.ReactNode;
|
|
7
26
|
onDismiss?: () => void;
|
|
8
27
|
testId?: string;
|
|
9
28
|
}
|
|
10
|
-
export declare const GoabNotification: ({ type, ariaLive, maxContentWidth, children, testId, onDismiss, }: GoabNotificationProps) => import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export declare const GoabNotification: ({ type, emphasis, compact, ariaLive, maxContentWidth, children, testId, onDismiss, }: GoabNotificationProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
30
|
export default GoabNotification;
|
|
@@ -1,4 +1,20 @@
|
|
|
1
1
|
import { GoabPaginationOnChangeDetail, Margins } from '@abgov/ui-components-common';
|
|
2
|
+
interface WCProps extends Margins {
|
|
3
|
+
ref?: React.RefObject<HTMLElement | null>;
|
|
4
|
+
itemcount: number;
|
|
5
|
+
perpagecount?: number;
|
|
6
|
+
pagenumber: number;
|
|
7
|
+
variant?: "all" | "links-only";
|
|
8
|
+
testid?: string;
|
|
9
|
+
version?: string;
|
|
10
|
+
}
|
|
11
|
+
declare module "react" {
|
|
12
|
+
namespace JSX {
|
|
13
|
+
interface IntrinsicElements {
|
|
14
|
+
"goa-pagination": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
}
|
|
2
18
|
export interface GoabPaginationProps extends Margins {
|
|
3
19
|
itemCount: number;
|
|
4
20
|
perPageCount?: number;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
1
|
+
import { ReactNode, JSX } from 'react';
|
|
2
2
|
interface WCProps {
|
|
3
3
|
open?: boolean;
|
|
4
|
-
testid?: string;
|
|
5
4
|
heading?: string;
|
|
6
5
|
width?: string;
|
|
6
|
+
testid?: string;
|
|
7
|
+
version?: string;
|
|
7
8
|
ref: React.RefObject<HTMLElement | null>;
|
|
8
9
|
}
|
|
9
10
|
declare module "react" {
|
|
@@ -14,13 +15,13 @@ declare module "react" {
|
|
|
14
15
|
}
|
|
15
16
|
}
|
|
16
17
|
export interface GoabPushDrawerProps {
|
|
17
|
-
testid?: string;
|
|
18
18
|
open?: boolean;
|
|
19
|
-
heading?: string;
|
|
19
|
+
heading?: string | ReactNode;
|
|
20
20
|
width?: string;
|
|
21
|
-
|
|
21
|
+
testId?: string;
|
|
22
|
+
actions?: ReactNode;
|
|
22
23
|
children: ReactNode;
|
|
23
24
|
onClose: () => void;
|
|
24
25
|
}
|
|
25
|
-
export declare function GoabPushDrawer({
|
|
26
|
+
export declare function GoabPushDrawer({ open, heading, width, testId, actions, children, onClose, }: GoabPushDrawerProps): JSX.Element;
|
|
26
27
|
export default GoabPushDrawer;
|
|
@@ -1,17 +1,39 @@
|
|
|
1
1
|
import { JSX } from 'react';
|
|
2
|
-
import { GoabRadioGroupOnChangeDetail, GoabRadioGroupOrientation, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
2
|
+
import { GoabRadioGroupOnChangeDetail, GoabRadioGroupOrientation, GoabRadioGroupSize, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
3
3
|
export * from './radio';
|
|
4
|
+
interface WCProps extends Margins {
|
|
5
|
+
name: string;
|
|
6
|
+
value?: string;
|
|
7
|
+
id?: string;
|
|
8
|
+
orientation?: GoabRadioGroupOrientation;
|
|
9
|
+
disabled?: string;
|
|
10
|
+
error?: string;
|
|
11
|
+
arialabel?: string;
|
|
12
|
+
testid?: string;
|
|
13
|
+
size?: GoabRadioGroupSize;
|
|
14
|
+
version?: string;
|
|
15
|
+
}
|
|
16
|
+
declare module "react" {
|
|
17
|
+
namespace JSX {
|
|
18
|
+
interface IntrinsicElements {
|
|
19
|
+
"goa-radio-group": WCProps & React.HTMLAttributes<HTMLElement> & {
|
|
20
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
4
25
|
export interface GoabRadioGroupProps extends Margins, DataAttributes {
|
|
5
26
|
name: string;
|
|
6
27
|
value?: string;
|
|
7
28
|
id?: string;
|
|
8
29
|
disabled?: boolean;
|
|
9
30
|
orientation?: GoabRadioGroupOrientation;
|
|
31
|
+
size?: GoabRadioGroupSize;
|
|
10
32
|
testId?: string;
|
|
11
33
|
error?: boolean;
|
|
12
34
|
ariaLabel?: string;
|
|
13
35
|
children?: React.ReactNode;
|
|
14
36
|
onChange?: (detail: GoabRadioGroupOnChangeDetail) => void;
|
|
15
37
|
}
|
|
16
|
-
export declare function GoabRadioGroup({ disabled, error, onChange, name, children, ...rest }: GoabRadioGroupProps): JSX.Element;
|
|
38
|
+
export declare function GoabRadioGroup({ disabled, error, onChange, name, children, size, ...rest }: GoabRadioGroupProps): JSX.Element;
|
|
17
39
|
export default GoabRadioGroup;
|
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
import { Margins } from '@abgov/ui-components-common';
|
|
2
2
|
import { JSX } from 'react';
|
|
3
|
+
interface WCProps extends Margins {
|
|
4
|
+
name?: string;
|
|
5
|
+
value?: string;
|
|
6
|
+
description?: string | React.ReactNode;
|
|
7
|
+
reveal?: React.ReactNode;
|
|
8
|
+
revealarialabel?: string;
|
|
9
|
+
label?: string;
|
|
10
|
+
maxwidth?: string;
|
|
11
|
+
disabled?: string;
|
|
12
|
+
checked?: string;
|
|
13
|
+
error?: string;
|
|
14
|
+
arialabel?: string;
|
|
15
|
+
compact?: string;
|
|
16
|
+
version?: string;
|
|
17
|
+
}
|
|
18
|
+
declare module "react" {
|
|
19
|
+
namespace JSX {
|
|
20
|
+
interface IntrinsicElements {
|
|
21
|
+
"goa-radio-item": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
3
25
|
export interface GoabRadioItemProps extends Margins {
|
|
4
26
|
value?: string;
|
|
5
27
|
label?: string;
|
|
@@ -11,8 +33,9 @@ export interface GoabRadioItemProps extends Margins {
|
|
|
11
33
|
disabled?: boolean;
|
|
12
34
|
checked?: boolean;
|
|
13
35
|
error?: boolean;
|
|
36
|
+
compact?: boolean;
|
|
14
37
|
children?: React.ReactNode;
|
|
15
38
|
ariaLabel?: string;
|
|
16
39
|
}
|
|
17
|
-
export declare function GoabRadioItem({ name, label, value, description, reveal, revealAriaLabel, maxWidth, disabled, checked, error, ariaLabel, children, mt, mr, mb, ml, }: GoabRadioItemProps): JSX.Element;
|
|
40
|
+
export declare function GoabRadioItem({ name, label, value, description, reveal, revealAriaLabel, maxWidth, disabled, checked, error, compact, ariaLabel, children, mt, mr, mb, ml, }: GoabRadioItemProps): JSX.Element;
|
|
18
41
|
export default GoabRadioItem;
|
|
@@ -1,7 +1,18 @@
|
|
|
1
1
|
import { ReactNode, JSX } from 'react';
|
|
2
|
+
interface WCProps {
|
|
3
|
+
testid?: string;
|
|
4
|
+
version?: string;
|
|
5
|
+
}
|
|
6
|
+
declare module "react" {
|
|
7
|
+
namespace JSX {
|
|
8
|
+
interface IntrinsicElements {
|
|
9
|
+
"goa-side-menu": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
|
2
13
|
export interface GoabSideMenuProps {
|
|
3
14
|
testId?: string;
|
|
4
15
|
children: ReactNode;
|
|
5
16
|
}
|
|
6
|
-
export declare function GoabSideMenu(
|
|
17
|
+
export declare function GoabSideMenu({ testId, children }: GoabSideMenuProps): JSX.Element;
|
|
7
18
|
export default GoabSideMenu;
|
|
@@ -1,10 +1,23 @@
|
|
|
1
1
|
import { ReactNode, JSX } from 'react';
|
|
2
2
|
import { GoabIconType, Margins } from '@abgov/ui-components-common';
|
|
3
|
+
interface WCProps extends Margins {
|
|
4
|
+
heading: string;
|
|
5
|
+
icon?: GoabIconType;
|
|
6
|
+
testid?: string;
|
|
7
|
+
version?: string;
|
|
8
|
+
}
|
|
9
|
+
declare module "react" {
|
|
10
|
+
namespace JSX {
|
|
11
|
+
interface IntrinsicElements {
|
|
12
|
+
"goa-side-menu-group": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
3
16
|
export interface GoabSideMenuGroupProps extends Margins {
|
|
4
17
|
heading: string;
|
|
5
18
|
icon?: GoabIconType;
|
|
6
19
|
testId?: string;
|
|
7
20
|
children?: ReactNode;
|
|
8
21
|
}
|
|
9
|
-
export declare function GoabSideMenuGroup(
|
|
22
|
+
export declare function GoabSideMenuGroup({ heading, icon, testId, children, mt, mr, mb, ml, }: GoabSideMenuGroupProps): JSX.Element;
|
|
10
23
|
export default GoabSideMenuGroup;
|
|
@@ -1,10 +1,22 @@
|
|
|
1
1
|
import { GoabIconType } from '@abgov/ui-components-common';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
testid?: string;
|
|
5
|
+
icon?: GoabIconType;
|
|
6
|
+
version?: string;
|
|
7
|
+
}
|
|
8
|
+
declare module "react" {
|
|
9
|
+
namespace JSX {
|
|
10
|
+
interface IntrinsicElements {
|
|
11
|
+
"goa-side-menu-heading": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
3
15
|
export interface GoabSideMenuHeadingProps {
|
|
4
16
|
meta?: ReactNode;
|
|
5
17
|
testId?: string;
|
|
6
18
|
icon?: GoabIconType;
|
|
7
19
|
children?: ReactNode;
|
|
8
20
|
}
|
|
9
|
-
export declare function GoabSideMenuHeading(
|
|
21
|
+
export declare function GoabSideMenuHeading({ meta, testId, icon, children }: GoabSideMenuHeadingProps): import("react/jsx-runtime").JSX.Element;
|
|
10
22
|
export default GoabSideMenuHeading;
|
|
@@ -1,9 +1,22 @@
|
|
|
1
|
-
import { DataAttributes, GoabTableSortDirection } from '@abgov/ui-components-common';
|
|
1
|
+
import { DataAttributes, GoabTableSortDirection, GoabTableSortOrder } from '@abgov/ui-components-common';
|
|
2
2
|
import { JSX } from 'react';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
name?: string;
|
|
5
|
+
direction?: GoabTableSortDirection;
|
|
6
|
+
"sort-order"?: GoabTableSortOrder;
|
|
7
|
+
}
|
|
8
|
+
declare module "react" {
|
|
9
|
+
namespace JSX {
|
|
10
|
+
interface IntrinsicElements {
|
|
11
|
+
"goa-table-sort-header": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
3
15
|
export interface GoabTableSortProps extends DataAttributes {
|
|
4
16
|
name?: string;
|
|
5
17
|
direction?: GoabTableSortDirection;
|
|
18
|
+
sortOrder?: GoabTableSortOrder;
|
|
6
19
|
children?: React.ReactNode;
|
|
7
20
|
}
|
|
8
|
-
export declare function GoabTableSortHeader({ children, ...rest }: GoabTableSortProps): JSX.Element;
|
|
21
|
+
export declare function GoabTableSortHeader({ name, direction, sortOrder, children, ...rest }: GoabTableSortProps): JSX.Element;
|
|
9
22
|
export default GoabTableSortHeader;
|
package/lib/table/table.d.ts
CHANGED
|
@@ -1,12 +1,32 @@
|
|
|
1
|
-
import { GoabTableOnSortDetail, GoabTableVariant, Margins } from '@abgov/ui-components-common';
|
|
1
|
+
import { GoabTableOnSortDetail, GoabTableOnMultiSortDetail, GoabTableSortMode, GoabTableVariant, Margins } from '@abgov/ui-components-common';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
+
interface WCProps extends Margins {
|
|
4
|
+
ref?: React.RefObject<HTMLElement | null>;
|
|
5
|
+
width?: string;
|
|
6
|
+
stickyheader?: string;
|
|
7
|
+
variant?: GoabTableVariant;
|
|
8
|
+
"sort-mode"?: GoabTableSortMode;
|
|
9
|
+
testid?: string;
|
|
10
|
+
striped?: string;
|
|
11
|
+
version?: string;
|
|
12
|
+
}
|
|
13
|
+
declare module "react" {
|
|
14
|
+
namespace JSX {
|
|
15
|
+
interface IntrinsicElements {
|
|
16
|
+
"goa-table": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
3
20
|
export interface GoabTableProps extends Margins {
|
|
4
21
|
width?: string;
|
|
5
22
|
onSort?: (detail: GoabTableOnSortDetail) => void;
|
|
23
|
+
onMultiSort?: (detail: GoabTableOnMultiSortDetail) => void;
|
|
24
|
+
sortMode?: GoabTableSortMode;
|
|
6
25
|
variant?: GoabTableVariant;
|
|
26
|
+
striped?: boolean;
|
|
7
27
|
testId?: string;
|
|
8
28
|
children?: ReactNode;
|
|
9
29
|
}
|
|
10
30
|
export type TableProps = GoabTableProps;
|
|
11
|
-
export declare function GoabTable({ onSort, ...props }: GoabTableProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare function GoabTable({ onSort, onMultiSort, sortMode, ...props }: GoabTableProps): import("react/jsx-runtime").JSX.Element;
|
|
12
32
|
export default GoabTable;
|
package/lib/tabs/tabs.d.ts
CHANGED
|
@@ -1,11 +1,31 @@
|
|
|
1
1
|
import { default as React, JSX } from 'react';
|
|
2
|
-
import { GoabTabsOnChangeDetail, GoabTabsVariant } from '@abgov/ui-components-common';
|
|
2
|
+
import { GoabTabsOnChangeDetail, GoabTabsOrientation, GoabTabsVariant, GoabTabsNavigation } from '@abgov/ui-components-common';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
initialtab?: number;
|
|
5
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
6
|
+
onChange?: (tab: number) => void;
|
|
7
|
+
testid?: string;
|
|
8
|
+
variant?: GoabTabsVariant;
|
|
9
|
+
navigation?: GoabTabsNavigation;
|
|
10
|
+
version?: string;
|
|
11
|
+
orientation?: string;
|
|
12
|
+
}
|
|
13
|
+
declare module "react" {
|
|
14
|
+
namespace JSX {
|
|
15
|
+
interface IntrinsicElements {
|
|
16
|
+
"goa-tabs": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
3
20
|
export interface GoabTabsProps {
|
|
4
21
|
initialTab?: number;
|
|
5
22
|
children?: React.ReactNode;
|
|
6
23
|
testId?: string;
|
|
7
24
|
variant?: GoabTabsVariant;
|
|
25
|
+
/** Tab layout orientation. "auto" stacks vertically on mobile (default), "horizontal" keeps horizontal on all screen sizes. */
|
|
26
|
+
orientation?: GoabTabsOrientation;
|
|
27
|
+
navigation?: GoabTabsNavigation;
|
|
8
28
|
onChange?: (detail: GoabTabsOnChangeDetail) => void;
|
|
9
29
|
}
|
|
10
|
-
export declare function GoabTabs({ initialTab, children, testId, variant,
|
|
30
|
+
export declare function GoabTabs({ initialTab, children, testId, onChange, variant, orientation, navigation, }: GoabTabsProps): JSX.Element;
|
|
11
31
|
export default GoabTabs;
|
|
@@ -1,5 +1,32 @@
|
|
|
1
|
-
import { GoabTextAreaCountBy, GoabTextAreaOnChangeDetail, GoabTextAreaOnKeyPressDetail, GoabTextAreaOnBlurDetail, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
1
|
+
import { GoabTextAreaCountBy, GoabTextAreaOnChangeDetail, GoabTextAreaOnKeyPressDetail, GoabTextAreaOnBlurDetail, GoabTextAreaSize, Margins, DataAttributes } from '@abgov/ui-components-common';
|
|
2
2
|
import { JSX } from 'react';
|
|
3
|
+
interface WCProps extends Margins {
|
|
4
|
+
name: string;
|
|
5
|
+
value?: string;
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
rows?: number;
|
|
8
|
+
error?: string;
|
|
9
|
+
readOnly?: string;
|
|
10
|
+
disabled?: string;
|
|
11
|
+
width?: string;
|
|
12
|
+
maxwidth?: string;
|
|
13
|
+
arialabel?: string;
|
|
14
|
+
countby?: GoabTextAreaCountBy;
|
|
15
|
+
maxcount?: number;
|
|
16
|
+
autocomplete?: string;
|
|
17
|
+
testid?: string;
|
|
18
|
+
size?: GoabTextAreaSize;
|
|
19
|
+
version?: string;
|
|
20
|
+
}
|
|
21
|
+
declare module "react" {
|
|
22
|
+
namespace JSX {
|
|
23
|
+
interface IntrinsicElements {
|
|
24
|
+
"goa-textarea": WCProps & React.HTMLAttributes<HTMLElement> & {
|
|
25
|
+
ref: React.Ref<HTMLTextAreaElement>;
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
3
30
|
export interface GoabTextAreaProps extends Margins, DataAttributes {
|
|
4
31
|
name: string;
|
|
5
32
|
value?: string;
|
|
@@ -16,6 +43,7 @@ export interface GoabTextAreaProps extends Margins, DataAttributes {
|
|
|
16
43
|
countBy?: GoabTextAreaCountBy;
|
|
17
44
|
maxCount?: number;
|
|
18
45
|
autoComplete?: string;
|
|
46
|
+
size?: GoabTextAreaSize;
|
|
19
47
|
onChange?: (event: GoabTextAreaOnChangeDetail) => void;
|
|
20
48
|
onKeyPress?: (event: GoabTextAreaOnKeyPressDetail) => void;
|
|
21
49
|
onBlur?: (event: GoabTextAreaOnBlurDetail) => void;
|
|
@@ -29,6 +29,7 @@ export interface GoabWorkSideMenuProps {
|
|
|
29
29
|
accountContent?: ReactNode;
|
|
30
30
|
open?: boolean;
|
|
31
31
|
onToggle?: () => void;
|
|
32
|
+
onNavigate?: (path: string) => void;
|
|
32
33
|
}
|
|
33
|
-
export declare function
|
|
34
|
-
export default
|
|
34
|
+
export declare function GoabWorkSideMenu({ heading, url, userName, userSecondaryText, testId, primaryContent, secondaryContent, accountContent, open, onToggle, onNavigate, }: GoabWorkSideMenuProps): JSX.Element;
|
|
35
|
+
export default GoabWorkSideMenu;
|
|
@@ -2,8 +2,9 @@ import { JSX } from 'react';
|
|
|
2
2
|
import { GoabIconType } from '@abgov/ui-components-common';
|
|
3
3
|
interface WCProps {
|
|
4
4
|
heading: string;
|
|
5
|
-
icon
|
|
5
|
+
icon?: GoabIconType;
|
|
6
6
|
testid?: string;
|
|
7
|
+
open?: boolean;
|
|
7
8
|
}
|
|
8
9
|
declare module "react" {
|
|
9
10
|
namespace JSX {
|
|
@@ -14,9 +15,10 @@ declare module "react" {
|
|
|
14
15
|
}
|
|
15
16
|
export interface GoabWorkSideMenuGroupProps {
|
|
16
17
|
heading: string;
|
|
17
|
-
icon
|
|
18
|
+
icon?: GoabIconType;
|
|
19
|
+
open?: boolean;
|
|
18
20
|
testId?: string;
|
|
19
21
|
children?: React.ReactNode;
|
|
20
22
|
}
|
|
21
|
-
export declare function
|
|
22
|
-
export default
|
|
23
|
+
export declare function GoabWorkSideMenuGroup(props: GoabWorkSideMenuGroupProps): JSX.Element;
|
|
24
|
+
export default GoabWorkSideMenuGroup;
|
|
@@ -2,7 +2,7 @@ import { JSX } from 'react';
|
|
|
2
2
|
import { GoabWorkSideMenuItemType } from '@abgov/ui-components-common';
|
|
3
3
|
interface WCProps {
|
|
4
4
|
label: string;
|
|
5
|
-
url
|
|
5
|
+
url?: string;
|
|
6
6
|
badge?: string;
|
|
7
7
|
current?: string;
|
|
8
8
|
divider?: string;
|
|
@@ -19,7 +19,7 @@ declare module "react" {
|
|
|
19
19
|
}
|
|
20
20
|
export interface GoabWorkSideMenuItemProps {
|
|
21
21
|
label: string;
|
|
22
|
-
url
|
|
22
|
+
url?: string;
|
|
23
23
|
badge?: string;
|
|
24
24
|
current?: boolean;
|
|
25
25
|
divider?: boolean;
|
|
@@ -27,6 +27,7 @@ export interface GoabWorkSideMenuItemProps {
|
|
|
27
27
|
testId?: string;
|
|
28
28
|
type?: GoabWorkSideMenuItemType;
|
|
29
29
|
children?: React.ReactNode;
|
|
30
|
+
popoverContent?: React.ReactNode;
|
|
30
31
|
}
|
|
31
|
-
export declare function
|
|
32
|
-
export default
|
|
32
|
+
export declare function GoabWorkSideMenuItem(props: GoabWorkSideMenuItemProps): JSX.Element;
|
|
33
|
+
export default GoabWorkSideMenuItem;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { JSX } from 'react';
|
|
2
|
+
import { GoabWorkSideNotificationItemType, GoabWorkSideNotificationReadStatus, GoabWorkSideNotificationPriority } from '@abgov/ui-components-common';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
type?: GoabWorkSideNotificationItemType;
|
|
5
|
+
timestamp?: string;
|
|
6
|
+
title?: string;
|
|
7
|
+
description: string;
|
|
8
|
+
"read-status"?: GoabWorkSideNotificationReadStatus;
|
|
9
|
+
priority?: GoabWorkSideNotificationPriority;
|
|
10
|
+
testid?: string;
|
|
11
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
12
|
+
}
|
|
13
|
+
declare module "react" {
|
|
14
|
+
namespace JSX {
|
|
15
|
+
interface IntrinsicElements {
|
|
16
|
+
"goa-work-side-notification-item": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
export interface GoabWorkSideNotificationItemProps {
|
|
21
|
+
type?: GoabWorkSideNotificationItemType;
|
|
22
|
+
timestamp?: string;
|
|
23
|
+
title?: string;
|
|
24
|
+
description: string;
|
|
25
|
+
readStatus?: GoabWorkSideNotificationReadStatus;
|
|
26
|
+
priority?: GoabWorkSideNotificationPriority;
|
|
27
|
+
testId?: string;
|
|
28
|
+
onClick?: () => void;
|
|
29
|
+
}
|
|
30
|
+
export declare function GoabWorkSideNotificationItem({ type, timestamp, title, description, readStatus, priority, testId, onClick, }: GoabWorkSideNotificationItemProps): JSX.Element;
|
|
31
|
+
export default GoabWorkSideNotificationItem;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ReactNode, JSX } from 'react';
|
|
2
|
+
import { GoabWorkSideNotificationActiveTabType } from '@abgov/ui-components-common';
|
|
3
|
+
interface WCProps {
|
|
4
|
+
heading?: string;
|
|
5
|
+
"active-tab"?: GoabWorkSideNotificationActiveTabType;
|
|
6
|
+
testid?: string;
|
|
7
|
+
ref: React.RefObject<HTMLElement | null>;
|
|
8
|
+
}
|
|
9
|
+
declare module "react" {
|
|
10
|
+
namespace JSX {
|
|
11
|
+
interface IntrinsicElements {
|
|
12
|
+
"goa-work-side-notification-panel": WCProps & React.HTMLAttributes<HTMLElement>;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
export interface GoabWorkSideNotificationPanelProps {
|
|
17
|
+
heading?: string;
|
|
18
|
+
activeTab?: GoabWorkSideNotificationActiveTabType;
|
|
19
|
+
testId?: string;
|
|
20
|
+
children?: ReactNode;
|
|
21
|
+
onMarkAllRead?: () => void;
|
|
22
|
+
onViewAll?: () => void;
|
|
23
|
+
}
|
|
24
|
+
export declare function GoabWorkSideNotificationPanel({ heading, activeTab, testId, children, onMarkAllRead, onViewAll, }: GoabWorkSideNotificationPanelProps): JSX.Element;
|
|
25
|
+
export default GoabWorkSideNotificationPanel;
|