ctc-component-library 0.1.64 → 0.1.65
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/index.es.js
CHANGED
|
@@ -41138,38 +41138,41 @@ const rz = ({
|
|
|
41138
41138
|
disabled: t,
|
|
41139
41139
|
customStyles: n,
|
|
41140
41140
|
customClassName: r,
|
|
41141
|
-
|
|
41142
|
-
|
|
41143
|
-
|
|
41144
|
-
|
|
41145
|
-
|
|
41146
|
-
|
|
41147
|
-
|
|
41148
|
-
|
|
41141
|
+
labelClassName: o,
|
|
41142
|
+
checkboxClassName: a,
|
|
41143
|
+
inputClassName: i,
|
|
41144
|
+
labelPosition: l = "right",
|
|
41145
|
+
inputSize: c = "medium",
|
|
41146
|
+
dataTestId: u = "checkbox-input",
|
|
41147
|
+
borderRadius: d = "1px",
|
|
41148
|
+
backgroundColor: f = Zt.neutrals.Gray80,
|
|
41149
|
+
onChange: m,
|
|
41150
|
+
children: v,
|
|
41151
|
+
...p
|
|
41149
41152
|
}) => {
|
|
41150
|
-
const
|
|
41153
|
+
const h = () => /* @__PURE__ */ de.jsx(
|
|
41151
41154
|
"label",
|
|
41152
41155
|
{
|
|
41153
41156
|
htmlFor: e,
|
|
41154
|
-
className: `checkbox-label checkbox-label__${t ? "disabled" : "enabled"}`,
|
|
41155
|
-
"data-testid": `${
|
|
41156
|
-
children:
|
|
41157
|
+
className: `checkbox-label checkbox-label__${t ? "disabled" : "enabled"} ${o}`,
|
|
41158
|
+
"data-testid": `${u}-label`,
|
|
41159
|
+
children: v
|
|
41157
41160
|
}
|
|
41158
|
-
),
|
|
41161
|
+
), g = {
|
|
41159
41162
|
medium: "22px",
|
|
41160
41163
|
small: "16px"
|
|
41161
41164
|
};
|
|
41162
41165
|
return /* @__PURE__ */ de.jsxs("div", { className: `checkbox-container ${r}`, children: [
|
|
41163
|
-
|
|
41166
|
+
v && l === "left" && /* @__PURE__ */ de.jsx(h, {}),
|
|
41164
41167
|
/* @__PURE__ */ de.jsx(
|
|
41165
41168
|
"div",
|
|
41166
41169
|
{
|
|
41167
|
-
className: `checkbox-content checkbox-content__${a}`,
|
|
41170
|
+
className: `checkbox-content checkbox-content__${c} ${a}`,
|
|
41168
41171
|
style: {
|
|
41169
|
-
width:
|
|
41170
|
-
minWidth:
|
|
41171
|
-
height:
|
|
41172
|
-
minHeight:
|
|
41172
|
+
width: g[c],
|
|
41173
|
+
minWidth: g[c],
|
|
41174
|
+
height: g[c],
|
|
41175
|
+
minHeight: g[c]
|
|
41173
41176
|
},
|
|
41174
41177
|
children: /* @__PURE__ */ de.jsx(
|
|
41175
41178
|
"input",
|
|
@@ -41177,20 +41180,20 @@ const rz = ({
|
|
|
41177
41180
|
disabled: t,
|
|
41178
41181
|
type: "checkbox",
|
|
41179
41182
|
id: e,
|
|
41180
|
-
onChange:
|
|
41181
|
-
className: `checkbox-input checkbox-input__${t ? "disabled" : "enabled"}`,
|
|
41182
|
-
"data-testid":
|
|
41183
|
+
onChange: m,
|
|
41184
|
+
className: `checkbox-input checkbox-input__${t ? "disabled" : "enabled"} ${i}`,
|
|
41185
|
+
"data-testid": u,
|
|
41183
41186
|
style: {
|
|
41184
|
-
accentColor:
|
|
41185
|
-
borderRadius:
|
|
41187
|
+
accentColor: f,
|
|
41188
|
+
borderRadius: d,
|
|
41186
41189
|
...n
|
|
41187
41190
|
},
|
|
41188
|
-
...
|
|
41191
|
+
...p
|
|
41189
41192
|
}
|
|
41190
41193
|
)
|
|
41191
41194
|
}
|
|
41192
41195
|
),
|
|
41193
|
-
|
|
41196
|
+
v && l === "right" && /* @__PURE__ */ de.jsx(h, {})
|
|
41194
41197
|
] });
|
|
41195
41198
|
}, Qo = {
|
|
41196
41199
|
small: "small",
|
|
@@ -6,6 +6,9 @@ export interface CheckboxProps extends React.HTMLAttributes<HTMLInputElement> {
|
|
|
6
6
|
id: string;
|
|
7
7
|
dataTestId?: string;
|
|
8
8
|
customClassName?: string;
|
|
9
|
+
labelClassName?: string;
|
|
10
|
+
checkboxClassName?: string;
|
|
11
|
+
inputClassName?: string;
|
|
9
12
|
customStyles?: React.CSSProperties;
|
|
10
13
|
children?: React.ReactNode;
|
|
11
14
|
backgroundColor?: string;
|