hplx-react-elements-dev 1.1.4 → 1.1.6
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/esm/datePicker/DatePicker.d.ts +1 -1
- package/dist/esm/index.js +30 -11
- package/dist/esm/types.d.ts +1 -0
- package/package.json +1 -1
|
@@ -3,5 +3,5 @@ import "react-date-range/dist/styles.css";
|
|
|
3
3
|
import "react-date-range/dist/theme/default.css";
|
|
4
4
|
import "../datePicker/DatePickerCSS.css";
|
|
5
5
|
import { DatePickerProps } from "../types";
|
|
6
|
-
declare const DatePicker: ({ disabledDates, selectDate, dateVar, minDate, maxDate, label, width, labelColor, labelSize, placeholder, height, start_icon, end_icon, hint_text_icon, prefix, suffixButton, suffix, hint_text, showPlaceHolderOnly, char_count, errorMsg, suffixInputProps, suffixDropdown, isSuffixEditable, suffixPlaceholder, fieldColor, isborderRequired, }: DatePickerProps) => JSX.Element;
|
|
6
|
+
declare const DatePicker: ({ disabledDates, selectDate, dateVar, minDate, maxDate, label, width, labelColor, labelSize, placeholder, height, start_icon, end_icon, hint_text_icon, prefix, suffixButton, suffix, hint_text, showPlaceHolderOnly, char_count, errorMsg, disable, suffixInputProps, suffixDropdown, isSuffixEditable, suffixPlaceholder, fieldColor, isborderRequired, }: DatePickerProps) => JSX.Element;
|
|
7
7
|
export default DatePicker;
|
package/dist/esm/index.js
CHANGED
|
@@ -17354,23 +17354,25 @@ var DatePicker = function DatePicker(_a) {
|
|
|
17354
17354
|
char_count = _a.char_count,
|
|
17355
17355
|
_h = _a.errorMsg,
|
|
17356
17356
|
errorMsg = _h === void 0 ? "" : _h,
|
|
17357
|
+
_j = _a.disable,
|
|
17358
|
+
disable = _j === void 0 ? false : _j,
|
|
17357
17359
|
// inputProps,
|
|
17358
17360
|
suffixInputProps = _a.suffixInputProps,
|
|
17359
17361
|
suffixDropdown = _a.suffixDropdown,
|
|
17360
|
-
|
|
17361
|
-
isSuffixEditable =
|
|
17362
|
+
_k = _a.isSuffixEditable,
|
|
17363
|
+
isSuffixEditable = _k === void 0 ? false : _k,
|
|
17362
17364
|
suffixPlaceholder = _a.suffixPlaceholder,
|
|
17363
17365
|
fieldColor = _a.fieldColor,
|
|
17364
|
-
|
|
17365
|
-
isborderRequired =
|
|
17366
|
+
_l = _a.isborderRequired,
|
|
17367
|
+
isborderRequired = _l === void 0 ? true : _l;
|
|
17366
17368
|
|
|
17367
|
-
var
|
|
17368
|
-
date =
|
|
17369
|
-
setDate =
|
|
17369
|
+
var _m = useState(),
|
|
17370
|
+
date = _m[0],
|
|
17371
|
+
setDate = _m[1];
|
|
17370
17372
|
|
|
17371
|
-
var
|
|
17372
|
-
clicked =
|
|
17373
|
-
setClicked =
|
|
17373
|
+
var _o = useState(false),
|
|
17374
|
+
clicked = _o[0],
|
|
17375
|
+
setClicked = _o[1];
|
|
17374
17376
|
|
|
17375
17377
|
var handleSelect = function handleSelect(date) {
|
|
17376
17378
|
setDate(date);
|
|
@@ -17433,6 +17435,7 @@ var DatePicker = function DatePicker(_a) {
|
|
|
17433
17435
|
isborderRequired: isborderRequired,
|
|
17434
17436
|
start_icon: start_icon,
|
|
17435
17437
|
inputProps: {
|
|
17438
|
+
disabled: disable,
|
|
17436
17439
|
placeholder: placeholder ? placeholder : "select date",
|
|
17437
17440
|
onClick: inputClick,
|
|
17438
17441
|
onFocus: inputFocus,
|
|
@@ -20530,17 +20533,24 @@ var ImageCarousel = function ImageCarousel(_a) {
|
|
|
20530
20533
|
current = _h[0],
|
|
20531
20534
|
setCurrent = _h[1];
|
|
20532
20535
|
|
|
20536
|
+
var _j = useState(autoPlay),
|
|
20537
|
+
isAutoPlay = _j[0],
|
|
20538
|
+
setIsAutoPlay = _j[1];
|
|
20539
|
+
|
|
20533
20540
|
var length = imageList.length;
|
|
20534
20541
|
|
|
20535
20542
|
var nextSlide = function nextSlide() {
|
|
20536
20543
|
setCurrent(current === length - 1 ? 0 : current + 1);
|
|
20544
|
+
setIsAutoPlay(false);
|
|
20537
20545
|
};
|
|
20538
20546
|
|
|
20539
20547
|
var prevSlide = function prevSlide() {
|
|
20548
|
+
setIsAutoPlay(false);
|
|
20540
20549
|
setCurrent(current === 0 ? length - 1 : current - 1);
|
|
20541
20550
|
};
|
|
20542
20551
|
|
|
20543
20552
|
var goToSlide = function goToSlide(slideNumber) {
|
|
20553
|
+
setIsAutoPlay(false);
|
|
20544
20554
|
setCurrent(slideNumber);
|
|
20545
20555
|
};
|
|
20546
20556
|
|
|
@@ -20557,9 +20567,18 @@ var ImageCarousel = function ImageCarousel(_a) {
|
|
|
20557
20567
|
autoPlay = false;
|
|
20558
20568
|
}
|
|
20559
20569
|
|
|
20560
|
-
if (timeInterval > 0 &&
|
|
20570
|
+
if (timeInterval > 0 && isAutoPlay) {
|
|
20561
20571
|
setTimeout(function () {
|
|
20562
20572
|
nextSlide();
|
|
20573
|
+
setIsAutoPlay(autoPlay);
|
|
20574
|
+
}, timeInterval);
|
|
20575
|
+
}
|
|
20576
|
+
|
|
20577
|
+
if (timeInterval > 0 && isAutoPlay && !isAutoPlay) {
|
|
20578
|
+
setTimeout(function () {
|
|
20579
|
+
if (autoPlay) {
|
|
20580
|
+
setIsAutoPlay(autoPlay);
|
|
20581
|
+
}
|
|
20563
20582
|
}, timeInterval);
|
|
20564
20583
|
}
|
|
20565
20584
|
|
package/dist/esm/types.d.ts
CHANGED