@apexcura/ui-components 0.0.14-Beta25 → 0.0.14-Beta26
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.js +15 -10
- package/dist/index.mjs +15 -10
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -744,11 +744,9 @@ var DatePickerElement = (props) => {
|
|
|
744
744
|
const [dateState, setDateState] = (0, import_react21.useState)("");
|
|
745
745
|
const dateFormat = "DD/MM/YYYY";
|
|
746
746
|
const handleChange = (date, dateString) => {
|
|
747
|
-
console.log("date==========", date);
|
|
748
747
|
if (date) {
|
|
749
|
-
console.log("date==", date);
|
|
750
748
|
const formattedDate = date.format(dateFormat);
|
|
751
|
-
setDateState(
|
|
749
|
+
setDateState(formattedDate);
|
|
752
750
|
if (props.onChange) {
|
|
753
751
|
props.onChange(formattedDate);
|
|
754
752
|
}
|
|
@@ -814,26 +812,34 @@ var SingleCheckbox = (props) => {
|
|
|
814
812
|
var import_react25 = __toESM(require("react"));
|
|
815
813
|
var import_antd18 = require("antd");
|
|
816
814
|
var DropDownGroup = (props) => {
|
|
817
|
-
const [selectedValue, setSelectedValue] = (0, import_react25.useState)({
|
|
818
|
-
|
|
815
|
+
const [selectedValue, setSelectedValue] = (0, import_react25.useState)({
|
|
816
|
+
firstValue: {},
|
|
817
|
+
secondValue: {}
|
|
818
|
+
});
|
|
819
819
|
const handleFirstChange = (value) => {
|
|
820
|
-
const filterOption2 = props.firstOptions?.find(
|
|
820
|
+
const filterOption2 = props.firstOptions?.find(
|
|
821
|
+
(eachOption) => eachOption.value === value
|
|
822
|
+
);
|
|
821
823
|
setSelectedValue((prev) => {
|
|
822
824
|
const newValue = { ...prev, firstValue: filterOption2 };
|
|
823
825
|
if (newValue.firstValue) {
|
|
824
826
|
props.onChange?.(newValue);
|
|
825
827
|
}
|
|
826
|
-
|
|
828
|
+
console.log("selectedValue1=====", selectedValue);
|
|
829
|
+
return selectedValue;
|
|
827
830
|
});
|
|
828
831
|
};
|
|
829
832
|
const handleSecondChange = (value) => {
|
|
830
|
-
const filterOption2 = props.secondOptions?.find(
|
|
833
|
+
const filterOption2 = props.secondOptions?.find(
|
|
834
|
+
(eachOption) => eachOption.value === value
|
|
835
|
+
);
|
|
831
836
|
setSelectedValue((prev) => {
|
|
832
837
|
const newValue = { ...prev, secondValue: filterOption2 };
|
|
833
838
|
if (newValue.secondValue) {
|
|
834
839
|
props.onChange?.(newValue);
|
|
835
840
|
}
|
|
836
|
-
|
|
841
|
+
console.log("selectedValue2=====", selectedValue);
|
|
842
|
+
return selectedValue;
|
|
837
843
|
});
|
|
838
844
|
};
|
|
839
845
|
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(
|
|
@@ -863,7 +869,6 @@ var FileUpload = (props) => {
|
|
|
863
869
|
const { Dragger } = import_antd19.Upload;
|
|
864
870
|
const [files, setFiles] = (0, import_react26.useState)([]);
|
|
865
871
|
const handleChange = ({ fileList }) => {
|
|
866
|
-
console.log(fileList);
|
|
867
872
|
setFiles(fileList);
|
|
868
873
|
if (props.onChange) {
|
|
869
874
|
props.onChange({
|
package/dist/index.mjs
CHANGED
|
@@ -686,11 +686,9 @@ var DatePickerElement = (props) => {
|
|
|
686
686
|
const [dateState, setDateState] = useState6("");
|
|
687
687
|
const dateFormat = "DD/MM/YYYY";
|
|
688
688
|
const handleChange = (date, dateString) => {
|
|
689
|
-
console.log("date==========", date);
|
|
690
689
|
if (date) {
|
|
691
|
-
console.log("date==", date);
|
|
692
690
|
const formattedDate = date.format(dateFormat);
|
|
693
|
-
setDateState(
|
|
691
|
+
setDateState(formattedDate);
|
|
694
692
|
if (props.onChange) {
|
|
695
693
|
props.onChange(formattedDate);
|
|
696
694
|
}
|
|
@@ -756,26 +754,34 @@ var SingleCheckbox = (props) => {
|
|
|
756
754
|
import React25, { useState as useState7 } from "react";
|
|
757
755
|
import { Select as Select4 } from "antd";
|
|
758
756
|
var DropDownGroup = (props) => {
|
|
759
|
-
const [selectedValue, setSelectedValue] = useState7({
|
|
760
|
-
|
|
757
|
+
const [selectedValue, setSelectedValue] = useState7({
|
|
758
|
+
firstValue: {},
|
|
759
|
+
secondValue: {}
|
|
760
|
+
});
|
|
761
761
|
const handleFirstChange = (value) => {
|
|
762
|
-
const filterOption2 = props.firstOptions?.find(
|
|
762
|
+
const filterOption2 = props.firstOptions?.find(
|
|
763
|
+
(eachOption) => eachOption.value === value
|
|
764
|
+
);
|
|
763
765
|
setSelectedValue((prev) => {
|
|
764
766
|
const newValue = { ...prev, firstValue: filterOption2 };
|
|
765
767
|
if (newValue.firstValue) {
|
|
766
768
|
props.onChange?.(newValue);
|
|
767
769
|
}
|
|
768
|
-
|
|
770
|
+
console.log("selectedValue1=====", selectedValue);
|
|
771
|
+
return selectedValue;
|
|
769
772
|
});
|
|
770
773
|
};
|
|
771
774
|
const handleSecondChange = (value) => {
|
|
772
|
-
const filterOption2 = props.secondOptions?.find(
|
|
775
|
+
const filterOption2 = props.secondOptions?.find(
|
|
776
|
+
(eachOption) => eachOption.value === value
|
|
777
|
+
);
|
|
773
778
|
setSelectedValue((prev) => {
|
|
774
779
|
const newValue = { ...prev, secondValue: filterOption2 };
|
|
775
780
|
if (newValue.secondValue) {
|
|
776
781
|
props.onChange?.(newValue);
|
|
777
782
|
}
|
|
778
|
-
|
|
783
|
+
console.log("selectedValue2=====", selectedValue);
|
|
784
|
+
return selectedValue;
|
|
779
785
|
});
|
|
780
786
|
};
|
|
781
787
|
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(
|
|
@@ -805,7 +811,6 @@ var FileUpload = (props) => {
|
|
|
805
811
|
const { Dragger } = Upload;
|
|
806
812
|
const [files, setFiles] = useState8([]);
|
|
807
813
|
const handleChange = ({ fileList }) => {
|
|
808
|
-
console.log(fileList);
|
|
809
814
|
setFiles(fileList);
|
|
810
815
|
if (props.onChange) {
|
|
811
816
|
props.onChange({
|