@apexcura/ui-components 0.0.14-Beta5 → 0.0.14-Beta6
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.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +16 -9
- package/dist/index.mjs +16 -9
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -464,9 +464,9 @@ var AddMoreTable = (props) => {
|
|
|
464
464
|
if (!element) return null;
|
|
465
465
|
const { element: type, label } = element;
|
|
466
466
|
if (type === "single-select") {
|
|
467
|
-
return /* @__PURE__ */ import_react12.default.createElement(SingleSelectElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false });
|
|
467
|
+
return /* @__PURE__ */ import_react12.default.createElement(SingleSelectElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false, options1: [], options2: [] });
|
|
468
468
|
} else if (type === "textarea") {
|
|
469
|
-
return /* @__PURE__ */ import_react12.default.createElement(TextareaElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false });
|
|
469
|
+
return /* @__PURE__ */ import_react12.default.createElement(TextareaElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false, options1: [], options2: [] });
|
|
470
470
|
} else {
|
|
471
471
|
return null;
|
|
472
472
|
}
|
|
@@ -832,9 +832,14 @@ var SingleCheckbox = (props) => {
|
|
|
832
832
|
var import_react25 = __toESM(require("react"));
|
|
833
833
|
var import_antd18 = require("antd");
|
|
834
834
|
var DropDownGroup = (props) => {
|
|
835
|
-
const [selectedValue, setSelectedValue] = (0, import_react25.useState)({
|
|
835
|
+
const [selectedValue, setSelectedValue] = (0, import_react25.useState)({
|
|
836
|
+
firstValue: {},
|
|
837
|
+
secondValue: {}
|
|
838
|
+
});
|
|
836
839
|
const handleFirstChange = (value) => {
|
|
837
|
-
const filterOption2 = props.options?.find(
|
|
840
|
+
const filterOption2 = props.options?.find(
|
|
841
|
+
(eachOption) => eachOption.value === value
|
|
842
|
+
);
|
|
838
843
|
setSelectedValue((prev) => {
|
|
839
844
|
const newValue = { ...prev, firstValue: filterOption2 };
|
|
840
845
|
if (newValue.firstValue) {
|
|
@@ -844,7 +849,9 @@ var DropDownGroup = (props) => {
|
|
|
844
849
|
});
|
|
845
850
|
};
|
|
846
851
|
const handleSecondChange = (value) => {
|
|
847
|
-
const filterOption2 = props.options?.find(
|
|
852
|
+
const filterOption2 = props.options?.find(
|
|
853
|
+
(eachOption) => eachOption.value === value
|
|
854
|
+
);
|
|
848
855
|
setSelectedValue((prev) => {
|
|
849
856
|
const newValue = { ...prev, secondValue: filterOption2 };
|
|
850
857
|
if (newValue.secondValue) {
|
|
@@ -853,12 +860,12 @@ var DropDownGroup = (props) => {
|
|
|
853
860
|
return selectedValue;
|
|
854
861
|
});
|
|
855
862
|
};
|
|
856
|
-
return /* @__PURE__ */ import_react25.default.createElement("div", { className: props.containerClassName }, /* @__PURE__ */ import_react25.default.createElement(
|
|
863
|
+
return /* @__PURE__ */ import_react25.default.createElement("div", { className: props.containerClassName }, props.label && /* @__PURE__ */ import_react25.default.createElement("label", { htmlFor: props.name, className: props.labelClassName }, props.label), /* @__PURE__ */ import_react25.default.createElement("div", { className: props.subContainerClassName }, /* @__PURE__ */ import_react25.default.createElement(
|
|
857
864
|
import_antd18.Select,
|
|
858
865
|
{
|
|
859
866
|
onChange: handleFirstChange,
|
|
860
867
|
variant: props.variant,
|
|
861
|
-
options: props.
|
|
868
|
+
options: props.options1,
|
|
862
869
|
className: props.className
|
|
863
870
|
}
|
|
864
871
|
), /* @__PURE__ */ import_react25.default.createElement("div", { style: { borderLeft: "1px solid gray", height: "33px" } }), /* @__PURE__ */ import_react25.default.createElement(
|
|
@@ -866,10 +873,10 @@ var DropDownGroup = (props) => {
|
|
|
866
873
|
{
|
|
867
874
|
onChange: handleSecondChange,
|
|
868
875
|
variant: props.variant,
|
|
869
|
-
options: props.
|
|
876
|
+
options: props.options2,
|
|
870
877
|
className: props.className
|
|
871
878
|
}
|
|
872
|
-
));
|
|
879
|
+
)));
|
|
873
880
|
};
|
|
874
881
|
|
|
875
882
|
// src/Components/FilesUpload.tsx
|
package/dist/index.mjs
CHANGED
|
@@ -407,9 +407,9 @@ var AddMoreTable = (props) => {
|
|
|
407
407
|
if (!element) return null;
|
|
408
408
|
const { element: type, label } = element;
|
|
409
409
|
if (type === "single-select") {
|
|
410
|
-
return /* @__PURE__ */ React12.createElement(SingleSelectElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false });
|
|
410
|
+
return /* @__PURE__ */ React12.createElement(SingleSelectElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false, options1: [], options2: [] });
|
|
411
411
|
} else if (type === "textarea") {
|
|
412
|
-
return /* @__PURE__ */ React12.createElement(TextareaElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false });
|
|
412
|
+
return /* @__PURE__ */ React12.createElement(TextareaElement, { onChange: (value2) => console.log(label, value2), optionType: "", className: void 0, selectedStyle: false, style: false, options1: [], options2: [] });
|
|
413
413
|
} else {
|
|
414
414
|
return null;
|
|
415
415
|
}
|
|
@@ -775,9 +775,14 @@ var SingleCheckbox = (props) => {
|
|
|
775
775
|
import React25, { useState as useState7 } from "react";
|
|
776
776
|
import { Select as Select4 } from "antd";
|
|
777
777
|
var DropDownGroup = (props) => {
|
|
778
|
-
const [selectedValue, setSelectedValue] = useState7({
|
|
778
|
+
const [selectedValue, setSelectedValue] = useState7({
|
|
779
|
+
firstValue: {},
|
|
780
|
+
secondValue: {}
|
|
781
|
+
});
|
|
779
782
|
const handleFirstChange = (value) => {
|
|
780
|
-
const filterOption2 = props.options?.find(
|
|
783
|
+
const filterOption2 = props.options?.find(
|
|
784
|
+
(eachOption) => eachOption.value === value
|
|
785
|
+
);
|
|
781
786
|
setSelectedValue((prev) => {
|
|
782
787
|
const newValue = { ...prev, firstValue: filterOption2 };
|
|
783
788
|
if (newValue.firstValue) {
|
|
@@ -787,7 +792,9 @@ var DropDownGroup = (props) => {
|
|
|
787
792
|
});
|
|
788
793
|
};
|
|
789
794
|
const handleSecondChange = (value) => {
|
|
790
|
-
const filterOption2 = props.options?.find(
|
|
795
|
+
const filterOption2 = props.options?.find(
|
|
796
|
+
(eachOption) => eachOption.value === value
|
|
797
|
+
);
|
|
791
798
|
setSelectedValue((prev) => {
|
|
792
799
|
const newValue = { ...prev, secondValue: filterOption2 };
|
|
793
800
|
if (newValue.secondValue) {
|
|
@@ -796,12 +803,12 @@ var DropDownGroup = (props) => {
|
|
|
796
803
|
return selectedValue;
|
|
797
804
|
});
|
|
798
805
|
};
|
|
799
|
-
return /* @__PURE__ */ React25.createElement("div", { className: props.containerClassName }, /* @__PURE__ */ React25.createElement(
|
|
806
|
+
return /* @__PURE__ */ React25.createElement("div", { className: props.containerClassName }, props.label && /* @__PURE__ */ React25.createElement("label", { htmlFor: props.name, className: props.labelClassName }, props.label), /* @__PURE__ */ React25.createElement("div", { className: props.subContainerClassName }, /* @__PURE__ */ React25.createElement(
|
|
800
807
|
Select4,
|
|
801
808
|
{
|
|
802
809
|
onChange: handleFirstChange,
|
|
803
810
|
variant: props.variant,
|
|
804
|
-
options: props.
|
|
811
|
+
options: props.options1,
|
|
805
812
|
className: props.className
|
|
806
813
|
}
|
|
807
814
|
), /* @__PURE__ */ React25.createElement("div", { style: { borderLeft: "1px solid gray", height: "33px" } }), /* @__PURE__ */ React25.createElement(
|
|
@@ -809,10 +816,10 @@ var DropDownGroup = (props) => {
|
|
|
809
816
|
{
|
|
810
817
|
onChange: handleSecondChange,
|
|
811
818
|
variant: props.variant,
|
|
812
|
-
options: props.
|
|
819
|
+
options: props.options2,
|
|
813
820
|
className: props.className
|
|
814
821
|
}
|
|
815
|
-
));
|
|
822
|
+
)));
|
|
816
823
|
};
|
|
817
824
|
|
|
818
825
|
// src/Components/FilesUpload.tsx
|