@apexcura/ui-components 0.0.14-Beta270 → 0.0.14-Beta272
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 +3 -14
- package/dist/index.mjs +3 -14
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -166,6 +166,8 @@ var TextareaElement = (props) => {
|
|
|
166
166
|
props.onChange(e.target.value);
|
|
167
167
|
}
|
|
168
168
|
};
|
|
169
|
+
const defaultMinRows = 2;
|
|
170
|
+
const defaultMaxRows = 6;
|
|
169
171
|
return /* @__PURE__ */ import_react4.default.createElement("div", { className: props.containerClassName }, props.label && /* @__PURE__ */ import_react4.default.createElement("label", { htmlFor: props.name, className: props.labelClassName }, props.label), /* @__PURE__ */ import_react4.default.createElement(
|
|
170
172
|
TextArea,
|
|
171
173
|
{
|
|
@@ -174,12 +176,10 @@ var TextareaElement = (props) => {
|
|
|
174
176
|
defaultValue: props.defaultValue,
|
|
175
177
|
disabled: props.disabled,
|
|
176
178
|
id: props.name,
|
|
177
|
-
|
|
179
|
+
autoSize: { minRows: props.minRows ? props.minRows : defaultMinRows, maxRows: props.maxRows ? props.maxRows : defaultMaxRows },
|
|
178
180
|
className: props.className,
|
|
179
|
-
variant: props.variant,
|
|
180
181
|
name: props.name,
|
|
181
182
|
showCount: true,
|
|
182
|
-
maxLength: props.maxLength,
|
|
183
183
|
onChange: (e) => {
|
|
184
184
|
handleChange(e);
|
|
185
185
|
}
|
|
@@ -195,7 +195,6 @@ var filterOptions = (input, option) => {
|
|
|
195
195
|
};
|
|
196
196
|
var SelectElement = (props) => {
|
|
197
197
|
const handleChange = (value) => {
|
|
198
|
-
console.log("++=====", typeof value);
|
|
199
198
|
if (props.onChange) {
|
|
200
199
|
if (typeof value === "string") {
|
|
201
200
|
const filterOption2 = props.options && props.options.find((eachOption) => eachOption.value === value);
|
|
@@ -232,7 +231,6 @@ var RadioElement = (props) => {
|
|
|
232
231
|
const [selectedValue, setSelectedValue] = (0, import_react6.useState)(props.value);
|
|
233
232
|
const optionType = props.optionType === "button" ? "button" : void 0;
|
|
234
233
|
const handleChange = (option) => {
|
|
235
|
-
console.log(option);
|
|
236
234
|
setSelectedValue(option);
|
|
237
235
|
setIsDisabled(true);
|
|
238
236
|
if (props.onChange) {
|
|
@@ -324,7 +322,6 @@ var CkEditor = (props) => {
|
|
|
324
322
|
var import_react9 = __toESM(require("react"));
|
|
325
323
|
var import_antd8 = require("antd");
|
|
326
324
|
var onSearch = (value) => {
|
|
327
|
-
console.log("search:", value);
|
|
328
325
|
};
|
|
329
326
|
var filterOption = (input, option) => (option?.label ?? "").toLowerCase().includes(input.toLowerCase());
|
|
330
327
|
var SingleSelectElement = (props) => {
|
|
@@ -605,7 +602,6 @@ var AddMoreTable = (props) => {
|
|
|
605
602
|
});
|
|
606
603
|
};
|
|
607
604
|
(0, import_react13.useEffect)(() => {
|
|
608
|
-
console.log(rows);
|
|
609
605
|
}, [rows]);
|
|
610
606
|
const renderInputElement = (element, value) => {
|
|
611
607
|
if (!element) return null;
|
|
@@ -808,11 +804,6 @@ var TableElement = (props) => {
|
|
|
808
804
|
};
|
|
809
805
|
const rowSelectionConfig = props.rowSelection ? {
|
|
810
806
|
onChange: (selectedRowKeys, selectedRows) => {
|
|
811
|
-
console.log(
|
|
812
|
-
`selectedRowKeys: ${selectedRowKeys}`,
|
|
813
|
-
"selectedRows: ",
|
|
814
|
-
selectedRows
|
|
815
|
-
);
|
|
816
807
|
if (props.onChange) {
|
|
817
808
|
props.onChange(selectedRows);
|
|
818
809
|
}
|
|
@@ -1053,7 +1044,6 @@ var TabsElement = (props) => {
|
|
|
1053
1044
|
var import_react27 = __toESM(require("react"));
|
|
1054
1045
|
var import_antd20 = require("antd");
|
|
1055
1046
|
var onChange = (checked) => {
|
|
1056
|
-
console.log(`switch to ${checked}`);
|
|
1057
1047
|
};
|
|
1058
1048
|
var SwitchElement = () => /* @__PURE__ */ import_react27.default.createElement(import_antd20.Switch, { defaultChecked: true, onChange });
|
|
1059
1049
|
|
|
@@ -1069,7 +1059,6 @@ var Upload2 = (props) => {
|
|
|
1069
1059
|
};
|
|
1070
1060
|
const handleUpload = async () => {
|
|
1071
1061
|
if (!file) {
|
|
1072
|
-
console.error("No file selected");
|
|
1073
1062
|
return;
|
|
1074
1063
|
}
|
|
1075
1064
|
};
|
package/dist/index.mjs
CHANGED
|
@@ -99,6 +99,8 @@ var TextareaElement = (props) => {
|
|
|
99
99
|
props.onChange(e.target.value);
|
|
100
100
|
}
|
|
101
101
|
};
|
|
102
|
+
const defaultMinRows = 2;
|
|
103
|
+
const defaultMaxRows = 6;
|
|
102
104
|
return /* @__PURE__ */ React4.createElement("div", { className: props.containerClassName }, props.label && /* @__PURE__ */ React4.createElement("label", { htmlFor: props.name, className: props.labelClassName }, props.label), /* @__PURE__ */ React4.createElement(
|
|
103
105
|
TextArea,
|
|
104
106
|
{
|
|
@@ -107,12 +109,10 @@ var TextareaElement = (props) => {
|
|
|
107
109
|
defaultValue: props.defaultValue,
|
|
108
110
|
disabled: props.disabled,
|
|
109
111
|
id: props.name,
|
|
110
|
-
|
|
112
|
+
autoSize: { minRows: props.minRows ? props.minRows : defaultMinRows, maxRows: props.maxRows ? props.maxRows : defaultMaxRows },
|
|
111
113
|
className: props.className,
|
|
112
|
-
variant: props.variant,
|
|
113
114
|
name: props.name,
|
|
114
115
|
showCount: true,
|
|
115
|
-
maxLength: props.maxLength,
|
|
116
116
|
onChange: (e) => {
|
|
117
117
|
handleChange(e);
|
|
118
118
|
}
|
|
@@ -128,7 +128,6 @@ var filterOptions = (input, option) => {
|
|
|
128
128
|
};
|
|
129
129
|
var SelectElement = (props) => {
|
|
130
130
|
const handleChange = (value) => {
|
|
131
|
-
console.log("++=====", typeof value);
|
|
132
131
|
if (props.onChange) {
|
|
133
132
|
if (typeof value === "string") {
|
|
134
133
|
const filterOption2 = props.options && props.options.find((eachOption) => eachOption.value === value);
|
|
@@ -165,7 +164,6 @@ var RadioElement = (props) => {
|
|
|
165
164
|
const [selectedValue, setSelectedValue] = useState2(props.value);
|
|
166
165
|
const optionType = props.optionType === "button" ? "button" : void 0;
|
|
167
166
|
const handleChange = (option) => {
|
|
168
|
-
console.log(option);
|
|
169
167
|
setSelectedValue(option);
|
|
170
168
|
setIsDisabled(true);
|
|
171
169
|
if (props.onChange) {
|
|
@@ -257,7 +255,6 @@ var CkEditor = (props) => {
|
|
|
257
255
|
import React9 from "react";
|
|
258
256
|
import { Select as Select2 } from "antd";
|
|
259
257
|
var onSearch = (value) => {
|
|
260
|
-
console.log("search:", value);
|
|
261
258
|
};
|
|
262
259
|
var filterOption = (input, option) => (option?.label ?? "").toLowerCase().includes(input.toLowerCase());
|
|
263
260
|
var SingleSelectElement = (props) => {
|
|
@@ -538,7 +535,6 @@ var AddMoreTable = (props) => {
|
|
|
538
535
|
});
|
|
539
536
|
};
|
|
540
537
|
useEffect(() => {
|
|
541
|
-
console.log(rows);
|
|
542
538
|
}, [rows]);
|
|
543
539
|
const renderInputElement = (element, value) => {
|
|
544
540
|
if (!element) return null;
|
|
@@ -741,11 +737,6 @@ var TableElement = (props) => {
|
|
|
741
737
|
};
|
|
742
738
|
const rowSelectionConfig = props.rowSelection ? {
|
|
743
739
|
onChange: (selectedRowKeys, selectedRows) => {
|
|
744
|
-
console.log(
|
|
745
|
-
`selectedRowKeys: ${selectedRowKeys}`,
|
|
746
|
-
"selectedRows: ",
|
|
747
|
-
selectedRows
|
|
748
|
-
);
|
|
749
740
|
if (props.onChange) {
|
|
750
741
|
props.onChange(selectedRows);
|
|
751
742
|
}
|
|
@@ -986,7 +977,6 @@ var TabsElement = (props) => {
|
|
|
986
977
|
import React27 from "react";
|
|
987
978
|
import { Switch } from "antd";
|
|
988
979
|
var onChange = (checked) => {
|
|
989
|
-
console.log(`switch to ${checked}`);
|
|
990
980
|
};
|
|
991
981
|
var SwitchElement = () => /* @__PURE__ */ React27.createElement(Switch, { defaultChecked: true, onChange });
|
|
992
982
|
|
|
@@ -1002,7 +992,6 @@ var Upload2 = (props) => {
|
|
|
1002
992
|
};
|
|
1003
993
|
const handleUpload = async () => {
|
|
1004
994
|
if (!file) {
|
|
1005
|
-
console.error("No file selected");
|
|
1006
995
|
return;
|
|
1007
996
|
}
|
|
1008
997
|
};
|