@ctlyst.id/internal-ui 4.1.5 → 4.1.7

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.d.mts CHANGED
@@ -165,6 +165,7 @@ interface CheckboxComponentProps extends CheckboxProps, PropsWithChildren {
165
165
  declare const CheckboxComponent: _chakra_ui_react.ComponentWithAs<"input", CheckboxComponentProps>;
166
166
 
167
167
  interface Props {
168
+ id?: string;
168
169
  label?: string | ReactNode;
169
170
  isError?: boolean;
170
171
  isSuccess?: boolean;
package/dist/index.d.ts CHANGED
@@ -165,6 +165,7 @@ interface CheckboxComponentProps extends CheckboxProps, PropsWithChildren {
165
165
  declare const CheckboxComponent: _chakra_ui_react.ComponentWithAs<"input", CheckboxComponentProps>;
166
166
 
167
167
  interface Props {
168
+ id?: string;
168
169
  label?: string | ReactNode;
169
170
  isError?: boolean;
170
171
  isSuccess?: boolean;
package/dist/index.js CHANGED
@@ -877,6 +877,7 @@ var import_react14 = require("@chakra-ui/react");
877
877
  var import_jsx_runtime17 = require("react/jsx-runtime");
878
878
  var Field = (props) => {
879
879
  const {
880
+ id: id2,
880
881
  label,
881
882
  isError,
882
883
  errorMessage,
@@ -899,7 +900,7 @@ var Field = (props) => {
899
900
  };
900
901
  const helperColor = getHelperColor();
901
902
  const justifyHelper = getJustifyContentHelper();
902
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_react14.FormControl, { isInvalid: isError, ...boxProps, children: [
903
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_react14.FormControl, { isInvalid: isError, id: id2, ...boxProps, children: [
903
904
  label && (typeof label === "string" ? /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(import_react14.FormLabel, { mb: 1, fontSize: "text.sm", requiredIndicator: void 0, children: [
904
905
  isRequired && /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_react14.Box, { as: "span", color: "danger.500", ml: 0, mr: 1, children: "*" }),
905
906
  label
@@ -1060,6 +1061,7 @@ var InputField = import_react22.default.forwardRef((props, ref) => {
1060
1061
  return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
1061
1062
  field_default,
1062
1063
  {
1064
+ id: props.id || props.name,
1063
1065
  label,
1064
1066
  isSuccess,
1065
1067
  isError,
@@ -1093,6 +1095,7 @@ var InputField = import_react22.default.forwardRef((props, ref) => {
1093
1095
  ref,
1094
1096
  type: inputType,
1095
1097
  value,
1098
+ "data-test-id": `CT_Component_InputField${props.name ? `_${props.name}` : ""}`,
1096
1099
  isDisabled,
1097
1100
  isSuccess,
1098
1101
  ...inputProps,
@@ -5611,9 +5614,9 @@ var TimeInput2 = (0, import_react85.forwardRef)(
5611
5614
  gap: 3,
5612
5615
  children: [
5613
5616
  /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(import_react85.Flex, { gap: "1px", width: "100%", alignItems: "center", pl: 2, children: [
5614
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(InputTimeArea, { ...hoursProps }),
5617
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(InputTimeArea, { "data-test-id": "start-time", ...hoursProps }),
5615
5618
  /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: ":" }),
5616
- /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(InputTimeArea, { ...getInputProps("minutes") }),
5619
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(InputTimeArea, { "data-test-id": "end-time", ...getInputProps("minutes") }),
5617
5620
  seconds && /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(import_jsx_runtime63.Fragment, { children: [
5618
5621
  /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: ":" }),
5619
5622
  /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(InputTimeArea, { ...getInputProps("seconds") })