contentoh-components-library 21.4.59 → 21.4.60

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.
@@ -16,15 +16,20 @@ var CheckBox = function CheckBox(_ref) {
16
16
  isFilter = _ref.isFilter,
17
17
  defaultChecked = _ref.defaultChecked,
18
18
  _ref$disabled = _ref.disabled,
19
- disabled = _ref$disabled === void 0 ? false : _ref$disabled;
19
+ disabled = _ref$disabled === void 0 ? false : _ref$disabled,
20
+ checked = _ref.checked,
21
+ _ref$className = _ref.className,
22
+ className = _ref$className === void 0 ? "" : _ref$className;
20
23
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
24
+ className: className,
21
25
  children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("input", {
22
26
  type: "checkbox",
23
27
  name: id,
24
28
  id: id,
25
29
  onChange: onChange,
26
30
  defaultChecked: defaultChecked,
27
- disabled: disabled
31
+ disabled: disabled,
32
+ checked: checked
28
33
  }), /*#__PURE__*/(0, _jsxRuntime.jsx)("label", {
29
34
  htmlFor: id,
30
35
  children: label && /*#__PURE__*/(0, _jsxRuntime.jsx)("p", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "contentoh-components-library",
3
- "version": "21.4.59",
3
+ "version": "21.4.60",
4
4
  "dependencies": {
5
5
  "@aws-amplify/auth": "^4.5.3",
6
6
  "@aws-amplify/datastore": "^3.11.0",
@@ -7,9 +7,11 @@ export const CheckBox = ({
7
7
  isFilter,
8
8
  defaultChecked,
9
9
  disabled = false,
10
+ checked,
11
+ className = "",
10
12
  }) => {
11
13
  return (
12
- <Container key={`check-${id}`}>
14
+ <Container key={`check-${id}`} className={className}>
13
15
  <input
14
16
  type="checkbox"
15
17
  name={id}
@@ -17,6 +19,7 @@ export const CheckBox = ({
17
19
  onChange={onChange}
18
20
  defaultChecked={defaultChecked}
19
21
  disabled={disabled}
22
+ checked={checked}
20
23
  />
21
24
  <label htmlFor={id}>
22
25
  {label && <p className={isFilter && "filter-text"}>{label}</p>}