@ctlyst.id/internal-ui 2.0.21 → 2.0.23
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/dist/components/checkbox/components/checkbox.d.ts +3 -9
- package/dist/internal-ui.cjs.development.js +10 -7
- package/dist/internal-ui.cjs.development.js.map +1 -1
- package/dist/internal-ui.cjs.production.min.js +1 -1
- package/dist/internal-ui.cjs.production.min.js.map +1 -1
- package/dist/internal-ui.esm.js +10 -7
- package/dist/internal-ui.esm.js.map +1 -1
- package/package.json +3 -3
package/dist/internal-ui.esm.js
CHANGED
@@ -384,19 +384,21 @@ CardCustom.defaultProps = {
|
|
384
384
|
isRounded: true
|
385
385
|
};
|
386
386
|
|
387
|
-
|
387
|
+
const CheckboxComponent = /*#__PURE__*/forwardRef$1(({
|
388
388
|
isError = false,
|
389
389
|
helpText = '',
|
390
390
|
errorText = '',
|
391
|
+
boxProps,
|
391
392
|
children,
|
392
393
|
isDisabled,
|
393
394
|
...rest
|
394
|
-
}) {
|
395
|
+
}, ref) => {
|
395
396
|
const variant = isError ? 'errors' : 'unstyled';
|
396
|
-
return /*#__PURE__*/React__default.createElement(Box,
|
397
|
+
return /*#__PURE__*/React__default.createElement(Box, Object.assign({}, boxProps), /*#__PURE__*/React__default.createElement(Box, {
|
397
398
|
display: "flex"
|
398
399
|
}, /*#__PURE__*/React__default.createElement(Checkbox$1, Object.assign({
|
399
|
-
variant: variant
|
400
|
+
variant: variant,
|
401
|
+
ref: ref
|
400
402
|
}, rest, {
|
401
403
|
isDisabled: isDisabled
|
402
404
|
}), children && /*#__PURE__*/React__default.createElement(Text, {
|
@@ -404,7 +406,7 @@ function CheckboxComponent({
|
|
404
406
|
display: "block",
|
405
407
|
textStyle: "text.sm",
|
406
408
|
color: isDisabled ? 'black.medium' : 'black.high'
|
407
|
-
}, children))), /*#__PURE__*/React__default.createElement(Box, {
|
409
|
+
}, children))), (isError || helpText) && /*#__PURE__*/React__default.createElement(Box, {
|
408
410
|
mt: "5px",
|
409
411
|
ml: "24px"
|
410
412
|
}, isError ? /*#__PURE__*/React__default.createElement(Text, {
|
@@ -418,11 +420,12 @@ function CheckboxComponent({
|
|
418
420
|
textStyle: "text.xs",
|
419
421
|
color: "black.medium"
|
420
422
|
}, helpText)));
|
421
|
-
}
|
423
|
+
});
|
422
424
|
CheckboxComponent.defaultProps = {
|
423
425
|
isError: false,
|
424
426
|
helpText: '',
|
425
|
-
errorText: ''
|
427
|
+
errorText: '',
|
428
|
+
boxProps: {}
|
426
429
|
};
|
427
430
|
|
428
431
|
const Field = props => {
|