@abgov/react-components 3.4.0-alpha.30 → 3.4.0-alpha.33
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.
|
@@ -8,19 +8,19 @@ declare global {
|
|
|
8
8
|
}
|
|
9
9
|
interface CheckboxProps {
|
|
10
10
|
ref: React.RefObject<HTMLElement>;
|
|
11
|
+
id?: string;
|
|
11
12
|
name: string;
|
|
12
13
|
checked?: boolean;
|
|
13
14
|
disabled?: boolean;
|
|
14
|
-
indeterminate?: boolean;
|
|
15
15
|
error?: boolean;
|
|
16
16
|
text?: string;
|
|
17
17
|
value?: string | number | boolean;
|
|
18
18
|
}
|
|
19
19
|
export interface Props {
|
|
20
|
+
id?: string;
|
|
20
21
|
name: string;
|
|
21
22
|
checked?: boolean;
|
|
22
23
|
disabled?: boolean;
|
|
23
|
-
indeterminate?: boolean;
|
|
24
24
|
error?: boolean;
|
|
25
25
|
text?: string;
|
|
26
26
|
value?: string | number | boolean;
|
package/lib/modal/modal.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import React, { FC } from 'react';
|
|
2
2
|
interface WCProps {
|
|
3
3
|
ref: React.RefObject<HTMLElement>;
|
|
4
|
-
title
|
|
5
|
-
closable: boolean;
|
|
6
|
-
scrollable: boolean;
|
|
4
|
+
title?: string;
|
|
7
5
|
open?: boolean;
|
|
6
|
+
width?: string;
|
|
7
|
+
closable?: boolean;
|
|
8
|
+
scrollable?: boolean;
|
|
8
9
|
}
|
|
9
10
|
declare global {
|
|
10
11
|
namespace JSX {
|
|
@@ -14,10 +15,11 @@ declare global {
|
|
|
14
15
|
}
|
|
15
16
|
}
|
|
16
17
|
interface Props {
|
|
17
|
-
title
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
title?: string;
|
|
19
|
+
width?: string;
|
|
20
|
+
actions?: React.ReactElement;
|
|
20
21
|
onClose?: () => void;
|
|
22
|
+
open?: boolean;
|
|
21
23
|
}
|
|
22
24
|
export declare const GoAModal: FC<Props>;
|
|
23
25
|
export default GoAModal;
|
|
@@ -10,10 +10,12 @@ export declare type ServiceLevel = 'alpha' | 'beta' | 'live';
|
|
|
10
10
|
interface WebComponentProps {
|
|
11
11
|
level: ServiceLevel;
|
|
12
12
|
version?: string;
|
|
13
|
+
feedbackurl?: string;
|
|
13
14
|
}
|
|
14
15
|
export interface HeaderProps {
|
|
15
16
|
level: ServiceLevel;
|
|
16
17
|
version?: string;
|
|
18
|
+
feedbackUrl?: string;
|
|
17
19
|
}
|
|
18
20
|
export declare const GoAServiceLevelHeader: FC<HeaderProps>;
|
|
19
21
|
export default GoAServiceLevelHeader;
|
package/package.json
CHANGED
package/react-components.esm.js
CHANGED
|
@@ -169,13 +169,13 @@ const GoACallout = ({
|
|
|
169
169
|
};
|
|
170
170
|
|
|
171
171
|
const GoACheckbox = ({
|
|
172
|
+
id,
|
|
172
173
|
name,
|
|
173
174
|
testId,
|
|
174
175
|
error,
|
|
175
176
|
disabled,
|
|
176
177
|
checked,
|
|
177
|
-
|
|
178
|
-
value: _value = true,
|
|
178
|
+
value,
|
|
179
179
|
text,
|
|
180
180
|
children,
|
|
181
181
|
onChange
|
|
@@ -200,13 +200,13 @@ const GoACheckbox = ({
|
|
|
200
200
|
return jsx("goa-checkbox", Object.assign({
|
|
201
201
|
"data-testid": testId,
|
|
202
202
|
ref: el,
|
|
203
|
+
id: id,
|
|
203
204
|
name: name,
|
|
204
205
|
error: error,
|
|
205
206
|
checked: checked,
|
|
206
207
|
disabled: disabled,
|
|
207
|
-
indeterminate: indeterminate,
|
|
208
208
|
text: text,
|
|
209
|
-
value:
|
|
209
|
+
value: value
|
|
210
210
|
}, {
|
|
211
211
|
children: children
|
|
212
212
|
}), void 0);
|
|
@@ -575,7 +575,8 @@ const GoAModal = ({
|
|
|
575
575
|
title,
|
|
576
576
|
children,
|
|
577
577
|
open,
|
|
578
|
-
|
|
578
|
+
width,
|
|
579
|
+
actions,
|
|
579
580
|
onClose
|
|
580
581
|
}) => {
|
|
581
582
|
const el = useRef(null);
|
|
@@ -595,14 +596,19 @@ const GoAModal = ({
|
|
|
595
596
|
current.removeEventListener('_close', listener);
|
|
596
597
|
};
|
|
597
598
|
}, [el, onClose]);
|
|
598
|
-
return
|
|
599
|
+
return jsxs("goa-modal", Object.assign({
|
|
599
600
|
ref: el,
|
|
600
601
|
title: title,
|
|
601
602
|
open: open,
|
|
602
|
-
closable:
|
|
603
|
-
scrollable: true
|
|
603
|
+
closable: !!onClose,
|
|
604
|
+
scrollable: true,
|
|
605
|
+
width: width
|
|
604
606
|
}, {
|
|
605
|
-
children:
|
|
607
|
+
children: [actions && jsx("div", Object.assign({
|
|
608
|
+
slot: "actions"
|
|
609
|
+
}, {
|
|
610
|
+
children: actions
|
|
611
|
+
}), void 0), children]
|
|
606
612
|
}), void 0);
|
|
607
613
|
};
|
|
608
614
|
|
|
@@ -701,11 +707,13 @@ const GoARadioGroup = ({
|
|
|
701
707
|
|
|
702
708
|
const GoAServiceLevelHeader = ({
|
|
703
709
|
level,
|
|
704
|
-
version
|
|
710
|
+
version,
|
|
711
|
+
feedbackUrl
|
|
705
712
|
}) => {
|
|
706
713
|
return jsx("goa-service-level-header", {
|
|
707
714
|
level: level,
|
|
708
|
-
version: version
|
|
715
|
+
version: version,
|
|
716
|
+
feedbackurl: feedbackUrl
|
|
709
717
|
}, void 0);
|
|
710
718
|
};
|
|
711
719
|
|
package/react-components.umd.js
CHANGED
|
@@ -209,14 +209,13 @@
|
|
|
209
209
|
};
|
|
210
210
|
|
|
211
211
|
var GoACheckbox = function GoACheckbox(_a) {
|
|
212
|
-
var
|
|
212
|
+
var id = _a.id,
|
|
213
|
+
name = _a.name,
|
|
213
214
|
testId = _a.testId,
|
|
214
215
|
error = _a.error,
|
|
215
216
|
disabled = _a.disabled,
|
|
216
217
|
checked = _a.checked,
|
|
217
|
-
|
|
218
|
-
_b = _a.value,
|
|
219
|
-
value = _b === void 0 ? true : _b,
|
|
218
|
+
value = _a.value,
|
|
220
219
|
text = _a.text,
|
|
221
220
|
children = _a.children,
|
|
222
221
|
onChange = _a.onChange;
|
|
@@ -240,11 +239,11 @@
|
|
|
240
239
|
return jsxRuntime.jsx("goa-checkbox", __assign({
|
|
241
240
|
"data-testid": testId,
|
|
242
241
|
ref: el,
|
|
242
|
+
id: id,
|
|
243
243
|
name: name,
|
|
244
244
|
error: error,
|
|
245
245
|
checked: checked,
|
|
246
246
|
disabled: disabled,
|
|
247
|
-
indeterminate: indeterminate,
|
|
248
247
|
text: text,
|
|
249
248
|
value: value
|
|
250
249
|
}, {
|
|
@@ -587,7 +586,8 @@
|
|
|
587
586
|
var title = _a.title,
|
|
588
587
|
children = _a.children,
|
|
589
588
|
open = _a.open,
|
|
590
|
-
|
|
589
|
+
width = _a.width,
|
|
590
|
+
actions = _a.actions,
|
|
591
591
|
onClose = _a.onClose;
|
|
592
592
|
var el = React.useRef(null);
|
|
593
593
|
React.useEffect(function () {
|
|
@@ -606,14 +606,19 @@
|
|
|
606
606
|
current.removeEventListener('_close', listener);
|
|
607
607
|
};
|
|
608
608
|
}, [el, onClose]);
|
|
609
|
-
return jsxRuntime.
|
|
609
|
+
return jsxRuntime.jsxs("goa-modal", __assign({
|
|
610
610
|
ref: el,
|
|
611
611
|
title: title,
|
|
612
612
|
open: open,
|
|
613
|
-
closable:
|
|
614
|
-
scrollable: true
|
|
613
|
+
closable: !!onClose,
|
|
614
|
+
scrollable: true,
|
|
615
|
+
width: width
|
|
615
616
|
}, {
|
|
616
|
-
children:
|
|
617
|
+
children: [actions && jsxRuntime.jsx("div", __assign({
|
|
618
|
+
slot: "actions"
|
|
619
|
+
}, {
|
|
620
|
+
children: actions
|
|
621
|
+
}), void 0), children]
|
|
617
622
|
}), void 0);
|
|
618
623
|
};
|
|
619
624
|
|
|
@@ -709,10 +714,12 @@
|
|
|
709
714
|
|
|
710
715
|
var GoAServiceLevelHeader = function GoAServiceLevelHeader(_a) {
|
|
711
716
|
var level = _a.level,
|
|
712
|
-
version = _a.version
|
|
717
|
+
version = _a.version,
|
|
718
|
+
feedbackUrl = _a.feedbackUrl;
|
|
713
719
|
return jsxRuntime.jsx("goa-service-level-header", {
|
|
714
720
|
level: level,
|
|
715
|
-
version: version
|
|
721
|
+
version: version,
|
|
722
|
+
feedbackurl: feedbackUrl
|
|
716
723
|
}, void 0);
|
|
717
724
|
};
|
|
718
725
|
|