hplx-react-elements-dev 1.0.58 → 1.0.59
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { DoubleInputProps } from "../types";
|
|
3
|
-
declare const DoubleInput: ({ input1value, input2value, errorMsg, prefix, start_icon, end_icon, hint_text_icon, hint_text, className, suffixClassName, dropdownClassName, suffixDropdownClassName, options, suffixOptions, handleValChange, handleSuffixValChange, onDropdownClick, onSuffixDropdownClick, onlyDropdownItemsAllowed, onlySuffixDropdownItemsAllowed, inputProps, suffixInputProps, }: DoubleInputProps) => JSX.Element;
|
|
3
|
+
declare const DoubleInput: ({ label, labelColor, labelSize, input1value, input2value, errorMsg, prefix, start_icon, end_icon, hint_text_icon, hint_text, className, suffixClassName, dropdownClassName, suffixDropdownClassName, options, suffixOptions, handleValChange, handleSuffixValChange, onDropdownClick, onSuffixDropdownClick, onlyDropdownItemsAllowed, onlySuffixDropdownItemsAllowed, inputProps, suffixInputProps, }: DoubleInputProps) => JSX.Element;
|
|
4
4
|
export default DoubleInput;
|
package/dist/esm/index.js
CHANGED
|
@@ -17290,7 +17290,10 @@ var DatePicker = function DatePicker(_a) {
|
|
|
17290
17290
|
};
|
|
17291
17291
|
|
|
17292
17292
|
var DoubleInput = function DoubleInput(_a) {
|
|
17293
|
-
var
|
|
17293
|
+
var label = _a.label,
|
|
17294
|
+
labelColor = _a.labelColor,
|
|
17295
|
+
labelSize = _a.labelSize,
|
|
17296
|
+
_b = _a.input1value,
|
|
17294
17297
|
input1value = _b === void 0 ? "" : _b,
|
|
17295
17298
|
_c = _a.input2value,
|
|
17296
17299
|
input2value = _c === void 0 ? "" : _c,
|
|
@@ -17378,6 +17381,7 @@ var DoubleInput = function DoubleInput(_a) {
|
|
|
17378
17381
|
var handleFocus = function handleFocus(event) {
|
|
17379
17382
|
setActive(true);
|
|
17380
17383
|
setShowDropdown(true);
|
|
17384
|
+
setDropdownArr(options);
|
|
17381
17385
|
onFocus && onFocus(event);
|
|
17382
17386
|
};
|
|
17383
17387
|
|
|
@@ -17409,11 +17413,9 @@ var DoubleInput = function DoubleInput(_a) {
|
|
|
17409
17413
|
return options.label.toLowerCase().includes(e.target.value.toLowerCase());
|
|
17410
17414
|
});
|
|
17411
17415
|
setDropdownArr(sug);
|
|
17412
|
-
}
|
|
17413
|
-
|
|
17414
|
-
|
|
17415
|
-
handleValChange && handleValChange(e.target.value); // }
|
|
17416
|
+
}
|
|
17416
17417
|
|
|
17418
|
+
handleValChange && handleValChange(e.target.value);
|
|
17417
17419
|
setValue(e.target.value);
|
|
17418
17420
|
};
|
|
17419
17421
|
|
|
@@ -17427,11 +17429,9 @@ var DoubleInput = function DoubleInput(_a) {
|
|
|
17427
17429
|
return suffixOption.label.toLowerCase().includes(e.target.value.toLowerCase());
|
|
17428
17430
|
});
|
|
17429
17431
|
setSuffixDropdownArr(sug);
|
|
17430
|
-
}
|
|
17431
|
-
|
|
17432
|
-
|
|
17433
|
-
handleSuffixValChange && handleSuffixValChange(e.target.value); // }
|
|
17432
|
+
}
|
|
17434
17433
|
|
|
17434
|
+
handleSuffixValChange && handleSuffixValChange(e.target.value);
|
|
17435
17435
|
setSuffixValue(e.target.value);
|
|
17436
17436
|
};
|
|
17437
17437
|
|
|
@@ -17468,9 +17468,18 @@ var DoubleInput = function DoubleInput(_a) {
|
|
|
17468
17468
|
variant: "Regular",
|
|
17469
17469
|
type: "Text md"
|
|
17470
17470
|
}, {
|
|
17471
|
-
children: [jsxRuntime.exports.
|
|
17471
|
+
children: [Boolean(label) && jsxRuntime.exports.jsx("div", __assign({
|
|
17472
|
+
className: "".concat(labelColor ? labelColor : "hplxt-text-Gray-700", " hplxt-mb-1")
|
|
17473
|
+
}, {
|
|
17474
|
+
children: jsxRuntime.exports.jsx(Typography, __assign({
|
|
17475
|
+
type: "".concat(labelSize ? labelSize : "Text sm"),
|
|
17476
|
+
variant: "Medium"
|
|
17477
|
+
}, {
|
|
17478
|
+
children: label
|
|
17479
|
+
}))
|
|
17480
|
+
})), jsxRuntime.exports.jsxs("div", __assign({
|
|
17472
17481
|
"data-setid": "error-msg",
|
|
17473
|
-
className: "hplxt-flex hplxt-shadow-xs hplxt-border-1 hplxt-border-Blue_gray-100 hplxt-rounded-lg hover:hplxt-border-Primary-300 hover:hplxt-shadow-xs-primary\n hplxt-overflow-hidden placeholder:hplxt-text-Gray-500 hplxt-bg-White hplxt-h-10\n ".concat(errorMsg ? "hplxt-border-Error-300" :
|
|
17482
|
+
className: "hplxt-flex hplxt-shadow-xs hplxt-border-1 hplxt-border-Blue_gray-100 hplxt-rounded-lg hover:hplxt-border-Primary-300 hover:hplxt-shadow-xs-primary\n hplxt-overflow-hidden placeholder:hplxt-text-Gray-500 hplxt-bg-White hplxt-h-10\n ".concat(errorMsg ? "hplxt-border-Error-300" : "", " \n ").concat(disabled ? "hplxt-bg-Gray-50" : "".concat("hplxt-bg-White", " \n ").concat(errorMsg ? "hover:hplxt-shadow-xs-error" : "hover:hplxt-border-Primary-300 hover:hplxt-shadow-xs-primary "))
|
|
17474
17483
|
}, {
|
|
17475
17484
|
children: [Boolean(prefix) && jsxRuntime.exports.jsx("div", __assign({
|
|
17476
17485
|
"data-testid": "input-prefix",
|
|
@@ -17508,6 +17517,7 @@ var DoubleInput = function DoubleInput(_a) {
|
|
|
17508
17517
|
onFocus: function onFocus() {
|
|
17509
17518
|
setSuffixActive(true);
|
|
17510
17519
|
setShowSuffixDropdown(true);
|
|
17520
|
+
setSuffixDropdownArr(suffixOptions);
|
|
17511
17521
|
},
|
|
17512
17522
|
onBlur: function onBlur() {
|
|
17513
17523
|
setSuffixActive(false);
|
|
@@ -17696,6 +17706,7 @@ var InputTag = function InputTag(_a) {
|
|
|
17696
17706
|
};
|
|
17697
17707
|
|
|
17698
17708
|
var handleBlur = function handleBlur(event) {
|
|
17709
|
+
setTagInputValue("");
|
|
17699
17710
|
setShowDropdown(false);
|
|
17700
17711
|
setActive(false);
|
|
17701
17712
|
onBlur && onBlur(event);
|
package/dist/esm/types.d.ts
CHANGED
|
@@ -394,6 +394,9 @@ export interface AddSuggestionProps {
|
|
|
394
394
|
isborderRequired?: boolean;
|
|
395
395
|
}
|
|
396
396
|
export interface DoubleInputProps {
|
|
397
|
+
label?: string;
|
|
398
|
+
labelSize?: typographyTextType;
|
|
399
|
+
labelColor?: string;
|
|
397
400
|
prefix?: ReactNode;
|
|
398
401
|
start_icon?: string;
|
|
399
402
|
end_icon?: string;
|