@xaypay/tui 0.0.67 → 0.0.68

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.es.js CHANGED
@@ -32,13 +32,15 @@ function styleInject(css, ref) {
32
32
  }
33
33
  }
34
34
 
35
- var css_248z$d = ".file-module_file-form__l13d5{align-items:center;background:#fbfbfb;border:2px dashed;border-radius:6px;cursor:pointer;display:flex;flex-direction:column;height:190px;justify-content:space-between;overflow:hidden;padding:4px 0;position:relative;width:100%}.file-module_file-form-wrap__qY--B:before{background:rgba(60,57,62,.4);border-radius:6px;content:\"\";height:100%;left:0;opacity:0;pointer-events:none;position:absolute;top:0;transition:opacity .24s;width:100%;z-index:1}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover:before{opacity:1;pointer-events:unset}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover .file-module_delete-upload-icon__PWN66{opacity:1}.file-module_file-form-inner-upload__tq3Dn{align-items:center;display:flex;flex-direction:column;justify-content:space-between;padding-bottom:16px;padding-top:48px}.file-module_file-form-inner-upload__tq3Dn>img{display:block;margin-bottom:14px}.file-module_upload-info__a8GFs{margin-bottom:40px;max-width:150px;text-align:center}.file-module_upload-info-txt__l11uN{color:#0da574}.file-module_file-form__l13d5.file-module_default__t7KU0{border-color:#d1d1d1}.file-module_file-form__l13d5.file-module_error__H-M4Z{border-color:#e00!important}.file-module_file-form__l13d5.file-module_accept__WTW6V{border-color:#00236a}.file-module_delete-upload-icon__PWN66{align-items:center;background:#fff;border-radius:6px;cursor:pointer;display:flex;height:26px;justify-content:center;opacity:0;position:absolute;right:10px;top:10px;transition:opacity .24s;width:26px;z-index:11}.file-module_delete-upload-icon__PWN66>i{color:#00236a;font-size:16px}.file-module_upload-file-content__QHMjn{align-items:center;display:flex;height:100%;justify-content:center;max-height:190px;overflow:hidden;position:relative;width:100%}.file-module_upload-file-content__QHMjn>img{display:block;height:auto;max-height:95%;object-fit:contain;width:27.8rem}.file-module_file-form-title__zWTSB{margin-bottom:10px;max-width:390px;word-break:break-all}.file-module_file-form-wrap__qY--B{position:relative;transform:translateZ(0)}";
35
+ var css_248z$d = ".file-module_file-form__l13d5{align-items:center;background:#fbfbfb;border:2px dashed;border-radius:6px;cursor:pointer;display:flex;flex-direction:column;height:190px;justify-content:space-between;overflow:hidden;padding:4px 0;position:relative;width:100%}.file-module_file-form-wrap__qY--B:before{background:rgba(60,57,62,.4);border-radius:6px;content:\"\";height:100%;left:0;opacity:0;pointer-events:none;position:absolute;top:0;transition:opacity .24s;width:100%;z-index:1}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover:before{opacity:1;pointer-events:unset}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover .file-module_delete-upload-icon__PWN66{opacity:1}.file-module_file-form-inner-upload__tq3Dn{align-items:center;display:flex;flex-direction:column;justify-content:space-between;padding-bottom:16px;padding-top:48px}.file-module_file-form-inner-upload__tq3Dn>img{display:block;margin-bottom:14px}.file-module_upload-info__a8GFs{margin-bottom:40px;max-width:150px;text-align:center}.file-module_upload-info-txt__l11uN{color:#0da574}.file-module_file-form__l13d5.file-module_default__t7KU0{border-color:#d1d1d1}.file-module_file-form__l13d5.file-module_error__H-M4Z{border-color:#e00!important}.file-module_file-form__l13d5.file-module_accept__WTW6V{border-color:#00236a}.file-module_delete-upload-icon__PWN66{align-items:center;background:#fff;border-radius:6px;cursor:pointer;display:flex;height:26px;justify-content:center;opacity:0;position:absolute;right:10px;top:10px;transition:opacity .24s;width:26px;z-index:11}.file-module_delete-upload-icon__PWN66>i{color:#00236a;font-size:16px}.file-module_upload-file-content__QHMjn{align-items:center;display:flex;height:100%;justify-content:center;max-height:190px;overflow:hidden;position:relative;width:100%}.file-module_upload-file-content__QHMjn>img{display:block;height:auto;max-height:95%;object-fit:contain;width:2.5rem}.file-module_file-form-title__zWTSB{margin-bottom:10px;max-width:390px;word-break:break-all}.file-module_file-form-wrap__qY--B{position:relative;transform:translateZ(0)}";
36
36
  var styles$c = {"file-form-wrap":"file-module_file-form-wrap__qY--B","file-form":"file-module_file-form__l13d5","active":"file-module_active__L1gPt","delete-upload-icon":"file-module_delete-upload-icon__PWN66","file-form-inner-upload":"file-module_file-form-inner-upload__tq3Dn","upload-info":"file-module_upload-info__a8GFs","upload-info-txt":"file-module_upload-info-txt__l11uN","default":"file-module_default__t7KU0","error":"file-module_error__H-M4Z","accept":"file-module_accept__WTW6V","upload-file-content":"file-module_upload-file-content__QHMjn","file-form-title":"file-module_file-form-title__zWTSB"};
37
37
  styleInject(css_248z$d);
38
38
 
39
39
  var css_248z$c = "";
40
40
  styleInject(css_248z$c);
41
41
 
42
+ var pdfImage = "<svg width=\"40\" height=\"52\" viewBox=\"0 0 40 52\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M39.1304 13.1106V36.2849V36.2853C39.394 36.4388 39.6133 36.6599 39.7659 36.9263C39.9189 37.1931 39.9992 37.4956 40 37.8037V47.5932C39.9984 48.7614 39.54 49.8816 38.7252 50.7079C37.91 51.5337 36.8048 51.9984 35.6522 52H4.34783C3.19523 51.9984 2.09005 51.5338 1.27483 50.7079C0.460015 49.8816 0.0015528 48.7614 0 47.5932V34.7817C0.000775155 34.4736 0.0815204 34.1714 0.234087 33.9051C0.386643 33.6383 0.605983 33.4176 0.869565 33.2641V3.52545C0.869565 2.5906 1.23602 1.69387 1.8882 1.03245C2.54072 0.371431 3.42547 0 4.34783 0H26.1953L39.1304 13.1106ZM13.872 45.3893C14.6037 45.4385 15.3293 45.2261 15.9225 44.7893C16.4303 44.3463 16.7036 43.6872 16.6605 43.0096C16.671 42.6272 16.598 42.2471 16.4478 41.8965C16.3154 41.6026 16.1136 41.3464 15.8597 41.1509C15.5976 40.9542 15.2991 40.8137 14.9816 40.7385C14.6225 40.6512 14.2541 40.6083 13.8849 40.6115H11.0258V48.4741H12.6849V45.3893H13.872ZM22.6954 47.4563C23.0149 47.1041 23.2498 46.6815 23.3814 46.2224C23.5347 45.6809 23.6084 45.1195 23.5999 44.5564C23.6065 44.008 23.5362 43.4614 23.3918 42.933C23.2672 42.477 23.0475 42.0532 22.7474 41.6904C22.4465 41.3379 22.0669 41.064 21.6398 40.8917C21.1305 40.6934 20.5882 40.5982 20.0432 40.6116H17.506V48.4821H20.0642C21.0475 48.5494 22.0103 48.1743 22.6954 47.4563ZM26.1252 42.05H29.4956L29.4956 40.6115H24.4661V48.4804L26.1287 48.4808V45.1068L28.6505 45.0962L28.64 43.6577H26.1252V42.05ZM18.3352 36.0407H37.3911L37.3908 14.3567H28.4428C27.5205 14.3567 26.6358 13.9852 25.9836 13.3238C25.331 12.6628 24.9646 11.7661 24.9646 10.8312V1.76186H4.34743C3.88625 1.76186 3.4437 1.94758 3.11762 2.27808C2.79153 2.60859 2.6083 3.05715 2.6083 3.52458V33.0185H14.9392C15.4408 33.0185 15.9179 33.238 16.2482 33.6205L18.3352 36.0407ZM6.08594 13.7151C6.08594 13.2283 6.48054 12.8337 6.9673 12.8337H20.6043C21.0911 12.8337 21.4857 13.2283 21.4857 13.7151C21.4857 14.2019 21.0911 14.5965 20.6043 14.5965H6.9673C6.48054 14.5965 6.08594 14.2019 6.08594 13.7151ZM18.5137 25.3369C18.5137 24.8502 18.9083 24.4556 19.395 24.4556H33.0321C33.5188 24.4556 33.9134 24.8502 33.9134 25.3369C33.9134 25.8237 33.5188 26.2183 33.0321 26.2183H19.395C18.9083 26.2183 18.5137 25.8237 18.5137 25.3369ZM6.9673 16.7056C6.48054 16.7056 6.08594 17.1002 6.08594 17.5869C6.08594 18.0737 6.48054 18.4683 6.9673 18.4683H33.0307C33.5174 18.4683 33.912 18.0737 33.912 17.5869C33.912 17.1002 33.5174 16.7056 33.0307 16.7056H6.9673ZM6.08594 21.4618C6.08594 20.975 6.48054 20.5804 6.9673 20.5804H33.0307C33.5174 20.5804 33.912 20.975 33.912 21.4618C33.912 21.9486 33.5174 22.3432 33.0307 22.3432H6.9673C6.48054 22.3432 6.08594 21.9486 6.08594 21.4618ZM21.4704 42.6691C21.1241 42.239 20.5919 42.0085 20.0457 42.0521H19.166V47.0441H20.0251C20.352 47.0567 20.6773 46.9886 20.9727 46.8469C21.213 46.7226 21.4156 46.5345 21.5589 46.3032C21.7076 46.0577 21.8089 45.7862 21.8582 45.5029C21.9164 45.1846 21.9455 44.8615 21.9451 44.5377C21.951 44.1698 21.9106 43.8023 21.8252 43.4446C21.758 43.1653 21.6373 42.9016 21.4704 42.6691ZM13.7445 42.0508C14.085 42.0213 14.4258 42.1008 14.7193 42.2782C14.8136 42.3518 14.8858 42.4501 14.9282 42.5627C14.9825 42.7134 15.0077 42.8731 15.0019 43.0333C15.0093 43.1969 14.9728 43.3594 14.8967 43.5039C14.8311 43.6211 14.7352 43.7175 14.6195 43.7832C14.4961 43.8525 14.361 43.8981 14.2212 43.9182C14.0636 43.9426 13.9041 43.9548 13.7445 43.9544H12.6855V42.0508H13.7445Z\" fill=\"#00236A\"/>\n</svg>";
43
+
42
44
  const File = ({
43
45
  name,
44
46
  label,
@@ -52,8 +54,7 @@ const File = ({
52
54
  fileExtensions,
53
55
  ...props
54
56
  }) => {
55
- const pdfImageName = 'https://play-lh.googleusercontent.com/kIwlXqs28otssKK_9AKwdkB6gouex_U2WmtLshTACnwIJuvOqVvJEzewpzuYBXwXQQ';
56
- const [image, setImage] = useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImageName : null);
57
+ const [image, setImage] = useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImage : null);
57
58
  const [error, setError] = useState('');
58
59
  const [fileName, setFileName] = useState('no selected file');
59
60
  const handleCheckFile = e => {
@@ -66,7 +67,7 @@ const File = ({
66
67
  onChange({
67
68
  file
68
69
  });
69
- setImage(pdfImageName);
70
+ setImage(pdfImage);
70
71
  } else {
71
72
  setError('');
72
73
  onChange({
@@ -636,18 +637,30 @@ const Input = ({
636
637
  `;
637
638
  const handleChange = event => {
638
639
  const currentValue = event.target.value;
640
+ setInnerValue(currentValue);
641
+ if (type === 'tel') {
642
+ if (currentValue.length > 8) {
643
+ setInnerValue(currentValue.substr(0, 8));
644
+ }
645
+ if (!phoneNumberRegex.test(currentValue) && telErrorMessage) {
646
+ setInnerErrorMessage(telErrorMessage);
647
+ } else {
648
+ setInnerErrorMessage('');
649
+ }
650
+ }
651
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
652
+ setInnerValue(currentValue.substr(0, maxLength));
653
+ }
654
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
655
+ !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
656
+ }
639
657
  if (onChange) {
640
658
  onChange(currentValue);
641
- } else {
642
- setInnerValue(currentValue);
643
- if (type === 'tel') {
644
- !phoneNumberRegex.test(parseInt(currentValue)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
645
- }
646
- if (maxLength) {
647
- currentValue.length > maxLength ? setInnerValue(currentValue.substr(0, maxLength)) : setInnerValue(currentValue);
659
+ if (type === 'tel' && currentValue.length > 8) {
660
+ onChange(currentValue.substr(0, 8));
648
661
  }
649
- if (regexp) {
650
- !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
662
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
663
+ onChange(currentValue.substr(0, maxLength));
651
664
  }
652
665
  }
653
666
  };
@@ -661,34 +674,28 @@ const Input = ({
661
674
  if (value !== undefined && value !== null) {
662
675
  setInnerValue(value);
663
676
  if (type === 'tel') {
664
- !phoneNumberRegex.test(parseInt(value)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
677
+ if (value.length > 8) {
678
+ setInnerValue(value.substr(0, 8));
679
+ }
680
+ if (!phoneNumberRegex.test(value) && telErrorMessage) {
681
+ setInnerErrorMessage(telErrorMessage);
682
+ } else {
683
+ setInnerErrorMessage('');
684
+ }
665
685
  }
666
- if (maxLength) {
667
- value.length > maxLength ? setInnerValue(value.substr(0, maxLength)) : setInnerValue(value);
686
+ if (maxLength && value.length > maxLength && type !== 'tel') {
687
+ setInnerValue(value.substr(0, maxLength));
668
688
  }
669
- if (regexp) {
689
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
670
690
  !regexp.test(value) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
671
691
  }
672
692
  }
673
- if (onChange && (value === undefined || value === null)) {
674
- alert('Please add value prop on input component');
675
- }
676
- }, [value, onChange]);
677
- useEffect(() => {
678
693
  if (errorMessage) {
679
694
  setInnerErrorMessage(errorMessage);
695
+ } else {
696
+ setInnerErrorMessage('');
680
697
  }
681
- }, [errorMessage]);
682
- useEffect(() => {
683
- if (type === 'tel' && !telErrorMessage) {
684
- alert('Please add telErrorMessage on input component');
685
- }
686
- }, [type]);
687
- useEffect(() => {
688
- if (regexp && !regexpErrorMessage) {
689
- alert('Please add regexpErrorMessage prop on input component');
690
- }
691
- }, [regexp]);
698
+ }, [type, value, regexp, maxLength, errorMessage, regexpErrorMessage]);
692
699
  return /*#__PURE__*/React__default.createElement("div", {
693
700
  className: `${styles$8["input-wrap"]}`
694
701
  }, label ? /*#__PURE__*/React__default.createElement("label", {
@@ -1953,7 +1960,7 @@ styleInject(css_248z$1);
1953
1960
 
1954
1961
  // import styles from "./pagination.module.scss";
1955
1962
 
1956
- const Dots = "...";
1963
+ const Dots$1 = "...";
1957
1964
  const range = (start, end) => {
1958
1965
  const length = end - start + 1;
1959
1966
  return Array.from({
@@ -1983,22 +1990,58 @@ const PaginationRange = ({
1983
1990
  if (!shouldShowLeftDots && shouldShowRightDots) {
1984
1991
  let leftItemCount = currentPageNumber === 4 && lastPageIndex > 7 ? 4 + siblingCountNumber : 3 + siblingCountNumber;
1985
1992
  let leftRange = range(1, leftItemCount);
1986
- return [...leftRange, Dots, totalPageCount];
1993
+ return [...leftRange, Dots$1, totalPageCount];
1987
1994
  }
1988
1995
  if (shouldShowLeftDots && !shouldShowRightDots) {
1989
1996
  let rightItemCount = 0;
1990
1997
  currentPageNumber === lastPageIndex - 3 && lastPageIndex > 7 ? rightItemCount = 4 + siblingCountNumber : rightItemCount = 3 + siblingCountNumber;
1991
1998
  let rightRange = range(totalPageCount - rightItemCount + 1, totalPageCount);
1992
- return [firstPageIndex, Dots, ...rightRange];
1999
+ return [firstPageIndex, Dots$1, ...rightRange];
1993
2000
  }
1994
2001
  if (shouldShowLeftDots && shouldShowRightDots) {
1995
2002
  let middleRange = range(leftSiblingIndex, rightSiblingIndex);
1996
- return [firstPageIndex, Dots, ...middleRange, Dots, lastPageIndex];
2003
+ return [firstPageIndex, Dots$1, ...middleRange, Dots$1, lastPageIndex];
1997
2004
  }
1998
2005
  }, [currentTotalCount, offset, siblingCountNumber, currentPageNumber]);
1999
2006
  return paginationRange;
2000
2007
  };
2001
2008
 
2009
+ const Dots = ({
2010
+ title,
2011
+ titleId,
2012
+ ...props
2013
+ }) => /*#__PURE__*/React.createElement("svg", _extends({
2014
+ width: "1em",
2015
+ height: "1em",
2016
+ viewBox: "0 0 11 3",
2017
+ fill: "none",
2018
+ xmlns: "http://www.w3.org/2000/svg",
2019
+ "aria-labelledby": titleId
2020
+ }, props), title ? /*#__PURE__*/React.createElement("title", {
2021
+ id: titleId
2022
+ }, title) : null, /*#__PURE__*/React.createElement("path", {
2023
+ d: "M0.230125 1.13624C0.230125 0.741577 0.326125 0.464244 0.518125 0.304244C0.710125 0.144244 0.939458 0.064244 1.20613 0.064244C1.48346 0.064244 1.71813 0.144244 1.91013 0.304244C2.11279 0.464244 2.21413 0.741577 2.21413 1.13624C2.21413 1.52024 2.11279 1.79758 1.91013 1.96824C1.71813 2.13891 1.48346 2.22424 1.20613 2.22424C0.939458 2.22424 0.710125 2.13891 0.518125 1.96824C0.326125 1.79758 0.230125 1.52024 0.230125 1.13624ZM4.51138 1.13624C4.51138 0.741577 4.60738 0.464244 4.79938 0.304244C4.99138 0.144244 5.22071 0.064244 5.48738 0.064244C5.76471 0.064244 5.99938 0.144244 6.19138 0.304244C6.39404 0.464244 6.49538 0.741577 6.49538 1.13624C6.49538 1.52024 6.39404 1.79758 6.19138 1.96824C5.99938 2.13891 5.76471 2.22424 5.48738 2.22424C5.22071 2.22424 4.99138 2.13891 4.79938 1.96824C4.60738 1.79758 4.51138 1.52024 4.51138 1.13624ZM8.79263 1.13624C8.79263 0.741577 8.88863 0.464244 9.08063 0.304244C9.27263 0.144244 9.50196 0.064244 9.76863 0.064244C10.046 0.064244 10.2806 0.144244 10.4726 0.304244C10.6753 0.464244 10.7766 0.741577 10.7766 1.13624C10.7766 1.52024 10.6753 1.79758 10.4726 1.96824C10.2806 2.13891 10.046 2.22424 9.76863 2.22424C9.50196 2.22424 9.27263 2.13891 9.08063 1.96824C8.88863 1.79758 8.79263 1.52024 8.79263 1.13624Z",
2024
+ fill: "#3C393E"
2025
+ }));
2026
+
2027
+ const SvgNextArrow = ({
2028
+ title,
2029
+ titleId,
2030
+ ...props
2031
+ }) => /*#__PURE__*/React.createElement("svg", _extends({
2032
+ width: "1em",
2033
+ height: "1em",
2034
+ viewBox: "0 0 6 12",
2035
+ fill: "none",
2036
+ xmlns: "http://www.w3.org/2000/svg",
2037
+ "aria-labelledby": titleId
2038
+ }, props), title ? /*#__PURE__*/React.createElement("title", {
2039
+ id: titleId
2040
+ }, title) : null, /*#__PURE__*/React.createElement("path", {
2041
+ d: "M0.851445 11.9985C0.652853 11.9988 0.460393 11.9292 0.307477 11.8017C0.221413 11.7299 0.150271 11.6418 0.0981246 11.5423C0.0459785 11.4428 0.0138536 11.3339 0.0035897 11.2219C-0.00667418 11.1098 0.00512483 10.9969 0.0383107 10.8895C0.0714965 10.7821 0.125416 10.6823 0.196984 10.5958L4.00476 6.01173L0.332976 1.41906C0.262375 1.33158 0.209651 1.23092 0.177836 1.12286C0.146021 1.01481 0.135741 0.901501 0.147589 0.789439C0.159437 0.677378 0.193177 0.568777 0.246871 0.469879C0.300566 0.370982 0.373156 0.283737 0.460468 0.213159C0.548409 0.135301 0.651394 0.0765731 0.76296 0.0406621C0.874526 0.00475112 0.992266 -0.00756759 1.10879 0.00447845C1.22531 0.0165245 1.3381 0.0526755 1.44008 0.110663C1.54206 0.16865 1.63102 0.247221 1.70139 0.341446L5.80665 5.47292C5.93166 5.62596 6 5.81791 6 6.01601C6 6.2141 5.93166 6.40606 5.80665 6.55909L1.5569 11.6906C1.47164 11.7941 1.36333 11.8759 1.24075 11.9294C1.11818 11.9829 0.984807 12.0065 0.851445 11.9985Z",
2042
+ fill: "#3C393E"
2043
+ }));
2044
+
2002
2045
  const Pagination = ({
2003
2046
  onChange,
2004
2047
  totalCount,
@@ -2053,13 +2096,14 @@ const Pagination = ({
2053
2096
  return /*#__PURE__*/React__default.createElement("ul", {
2054
2097
  className: classProps
2055
2098
  }, /*#__PURE__*/React__default.createElement("button", {
2099
+ style: {
2100
+ transform: 'rotate(180deg)'
2101
+ },
2056
2102
  className: `${styles$1["pagination-btn"]} pagination-btn-rem`,
2057
2103
  onClick: onPrevious,
2058
2104
  disabled: currentPage === 1 ? true : false
2059
- }, /*#__PURE__*/React__default.createElement("i", {
2060
- className: "icon-arrow-back"
2061
- })), paginationRange.map((pageNumber, id) => {
2062
- if (pageNumber === Dots) {
2105
+ }, /*#__PURE__*/React__default.createElement(SvgNextArrow, null)), paginationRange.map((pageNumber, id) => {
2106
+ if (pageNumber === Dots$1) {
2063
2107
  let currentPageIndex = paginationRange.indexOf(currentPageNumber);
2064
2108
  return /*#__PURE__*/React__default.createElement("li", {
2065
2109
  key: id,
@@ -2068,21 +2112,16 @@ const Pagination = ({
2068
2112
  disabled: currentPageIndex === 0 ? true : false
2069
2113
  }, id < currentPageIndex ? /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("span", {
2070
2114
  className: `${styles$1["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
2071
- }, /*#__PURE__*/React__default.createElement("i", {
2072
- className: "icon-text"
2073
- })), /*#__PURE__*/React__default.createElement("span", {
2074
- className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
2075
- }, /*#__PURE__*/React__default.createElement("i", {
2076
- className: "icon-arrow-jump-back"
2077
- }))) : /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("span", {
2115
+ }, /*#__PURE__*/React__default.createElement(Dots, null)), /*#__PURE__*/React__default.createElement("span", {
2116
+ className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`,
2117
+ style: {
2118
+ transform: 'rotate(180deg)'
2119
+ }
2120
+ }, /*#__PURE__*/React__default.createElement(SvgNextArrow, null))) : /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("span", {
2078
2121
  className: `${styles$1["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
2079
- }, /*#__PURE__*/React__default.createElement("i", {
2080
- className: "icon-text"
2081
- })), /*#__PURE__*/React__default.createElement("span", {
2122
+ }, /*#__PURE__*/React__default.createElement(Dots, null)), /*#__PURE__*/React__default.createElement("span", {
2082
2123
  className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
2083
- }, /*#__PURE__*/React__default.createElement("i", {
2084
- className: "icon-arrow-jump-next"
2085
- }))));
2124
+ }, /*#__PURE__*/React__default.createElement(SvgNextArrow, null))));
2086
2125
  }
2087
2126
  return /*#__PURE__*/React__default.createElement("li", {
2088
2127
  onClick: () => onPageChange(pageNumber),
@@ -2093,9 +2132,7 @@ const Pagination = ({
2093
2132
  onClick: onNext,
2094
2133
  className: `${styles$1["pagination-btn"]} pagination-btn-rem`,
2095
2134
  disabled: currentPageNumber === lastPage ? true : false
2096
- }, /*#__PURE__*/React__default.createElement("i", {
2097
- className: "icon-arrow"
2098
- })));
2135
+ }, /*#__PURE__*/React__default.createElement(SvgNextArrow, null)));
2099
2136
  };
2100
2137
  Pagination.propTypes = {
2101
2138
  offset: PropTypes.number,
package/dist/index.js CHANGED
@@ -62,13 +62,15 @@ function styleInject(css, ref) {
62
62
  }
63
63
  }
64
64
 
65
- var css_248z$d = ".file-module_file-form__l13d5{align-items:center;background:#fbfbfb;border:2px dashed;border-radius:6px;cursor:pointer;display:flex;flex-direction:column;height:190px;justify-content:space-between;overflow:hidden;padding:4px 0;position:relative;width:100%}.file-module_file-form-wrap__qY--B:before{background:rgba(60,57,62,.4);border-radius:6px;content:\"\";height:100%;left:0;opacity:0;pointer-events:none;position:absolute;top:0;transition:opacity .24s;width:100%;z-index:1}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover:before{opacity:1;pointer-events:unset}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover .file-module_delete-upload-icon__PWN66{opacity:1}.file-module_file-form-inner-upload__tq3Dn{align-items:center;display:flex;flex-direction:column;justify-content:space-between;padding-bottom:16px;padding-top:48px}.file-module_file-form-inner-upload__tq3Dn>img{display:block;margin-bottom:14px}.file-module_upload-info__a8GFs{margin-bottom:40px;max-width:150px;text-align:center}.file-module_upload-info-txt__l11uN{color:#0da574}.file-module_file-form__l13d5.file-module_default__t7KU0{border-color:#d1d1d1}.file-module_file-form__l13d5.file-module_error__H-M4Z{border-color:#e00!important}.file-module_file-form__l13d5.file-module_accept__WTW6V{border-color:#00236a}.file-module_delete-upload-icon__PWN66{align-items:center;background:#fff;border-radius:6px;cursor:pointer;display:flex;height:26px;justify-content:center;opacity:0;position:absolute;right:10px;top:10px;transition:opacity .24s;width:26px;z-index:11}.file-module_delete-upload-icon__PWN66>i{color:#00236a;font-size:16px}.file-module_upload-file-content__QHMjn{align-items:center;display:flex;height:100%;justify-content:center;max-height:190px;overflow:hidden;position:relative;width:100%}.file-module_upload-file-content__QHMjn>img{display:block;height:auto;max-height:95%;object-fit:contain;width:27.8rem}.file-module_file-form-title__zWTSB{margin-bottom:10px;max-width:390px;word-break:break-all}.file-module_file-form-wrap__qY--B{position:relative;transform:translateZ(0)}";
65
+ var css_248z$d = ".file-module_file-form__l13d5{align-items:center;background:#fbfbfb;border:2px dashed;border-radius:6px;cursor:pointer;display:flex;flex-direction:column;height:190px;justify-content:space-between;overflow:hidden;padding:4px 0;position:relative;width:100%}.file-module_file-form-wrap__qY--B:before{background:rgba(60,57,62,.4);border-radius:6px;content:\"\";height:100%;left:0;opacity:0;pointer-events:none;position:absolute;top:0;transition:opacity .24s;width:100%;z-index:1}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover:before{opacity:1;pointer-events:unset}.file-module_file-form-wrap__qY--B.file-module_active__L1gPt:hover .file-module_delete-upload-icon__PWN66{opacity:1}.file-module_file-form-inner-upload__tq3Dn{align-items:center;display:flex;flex-direction:column;justify-content:space-between;padding-bottom:16px;padding-top:48px}.file-module_file-form-inner-upload__tq3Dn>img{display:block;margin-bottom:14px}.file-module_upload-info__a8GFs{margin-bottom:40px;max-width:150px;text-align:center}.file-module_upload-info-txt__l11uN{color:#0da574}.file-module_file-form__l13d5.file-module_default__t7KU0{border-color:#d1d1d1}.file-module_file-form__l13d5.file-module_error__H-M4Z{border-color:#e00!important}.file-module_file-form__l13d5.file-module_accept__WTW6V{border-color:#00236a}.file-module_delete-upload-icon__PWN66{align-items:center;background:#fff;border-radius:6px;cursor:pointer;display:flex;height:26px;justify-content:center;opacity:0;position:absolute;right:10px;top:10px;transition:opacity .24s;width:26px;z-index:11}.file-module_delete-upload-icon__PWN66>i{color:#00236a;font-size:16px}.file-module_upload-file-content__QHMjn{align-items:center;display:flex;height:100%;justify-content:center;max-height:190px;overflow:hidden;position:relative;width:100%}.file-module_upload-file-content__QHMjn>img{display:block;height:auto;max-height:95%;object-fit:contain;width:2.5rem}.file-module_file-form-title__zWTSB{margin-bottom:10px;max-width:390px;word-break:break-all}.file-module_file-form-wrap__qY--B{position:relative;transform:translateZ(0)}";
66
66
  var styles$c = {"file-form-wrap":"file-module_file-form-wrap__qY--B","file-form":"file-module_file-form__l13d5","active":"file-module_active__L1gPt","delete-upload-icon":"file-module_delete-upload-icon__PWN66","file-form-inner-upload":"file-module_file-form-inner-upload__tq3Dn","upload-info":"file-module_upload-info__a8GFs","upload-info-txt":"file-module_upload-info-txt__l11uN","default":"file-module_default__t7KU0","error":"file-module_error__H-M4Z","accept":"file-module_accept__WTW6V","upload-file-content":"file-module_upload-file-content__QHMjn","file-form-title":"file-module_file-form-title__zWTSB"};
67
67
  styleInject(css_248z$d);
68
68
 
69
69
  var css_248z$c = "";
70
70
  styleInject(css_248z$c);
71
71
 
72
+ var pdfImage = "<svg width=\"40\" height=\"52\" viewBox=\"0 0 40 52\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M39.1304 13.1106V36.2849V36.2853C39.394 36.4388 39.6133 36.6599 39.7659 36.9263C39.9189 37.1931 39.9992 37.4956 40 37.8037V47.5932C39.9984 48.7614 39.54 49.8816 38.7252 50.7079C37.91 51.5337 36.8048 51.9984 35.6522 52H4.34783C3.19523 51.9984 2.09005 51.5338 1.27483 50.7079C0.460015 49.8816 0.0015528 48.7614 0 47.5932V34.7817C0.000775155 34.4736 0.0815204 34.1714 0.234087 33.9051C0.386643 33.6383 0.605983 33.4176 0.869565 33.2641V3.52545C0.869565 2.5906 1.23602 1.69387 1.8882 1.03245C2.54072 0.371431 3.42547 0 4.34783 0H26.1953L39.1304 13.1106ZM13.872 45.3893C14.6037 45.4385 15.3293 45.2261 15.9225 44.7893C16.4303 44.3463 16.7036 43.6872 16.6605 43.0096C16.671 42.6272 16.598 42.2471 16.4478 41.8965C16.3154 41.6026 16.1136 41.3464 15.8597 41.1509C15.5976 40.9542 15.2991 40.8137 14.9816 40.7385C14.6225 40.6512 14.2541 40.6083 13.8849 40.6115H11.0258V48.4741H12.6849V45.3893H13.872ZM22.6954 47.4563C23.0149 47.1041 23.2498 46.6815 23.3814 46.2224C23.5347 45.6809 23.6084 45.1195 23.5999 44.5564C23.6065 44.008 23.5362 43.4614 23.3918 42.933C23.2672 42.477 23.0475 42.0532 22.7474 41.6904C22.4465 41.3379 22.0669 41.064 21.6398 40.8917C21.1305 40.6934 20.5882 40.5982 20.0432 40.6116H17.506V48.4821H20.0642C21.0475 48.5494 22.0103 48.1743 22.6954 47.4563ZM26.1252 42.05H29.4956L29.4956 40.6115H24.4661V48.4804L26.1287 48.4808V45.1068L28.6505 45.0962L28.64 43.6577H26.1252V42.05ZM18.3352 36.0407H37.3911L37.3908 14.3567H28.4428C27.5205 14.3567 26.6358 13.9852 25.9836 13.3238C25.331 12.6628 24.9646 11.7661 24.9646 10.8312V1.76186H4.34743C3.88625 1.76186 3.4437 1.94758 3.11762 2.27808C2.79153 2.60859 2.6083 3.05715 2.6083 3.52458V33.0185H14.9392C15.4408 33.0185 15.9179 33.238 16.2482 33.6205L18.3352 36.0407ZM6.08594 13.7151C6.08594 13.2283 6.48054 12.8337 6.9673 12.8337H20.6043C21.0911 12.8337 21.4857 13.2283 21.4857 13.7151C21.4857 14.2019 21.0911 14.5965 20.6043 14.5965H6.9673C6.48054 14.5965 6.08594 14.2019 6.08594 13.7151ZM18.5137 25.3369C18.5137 24.8502 18.9083 24.4556 19.395 24.4556H33.0321C33.5188 24.4556 33.9134 24.8502 33.9134 25.3369C33.9134 25.8237 33.5188 26.2183 33.0321 26.2183H19.395C18.9083 26.2183 18.5137 25.8237 18.5137 25.3369ZM6.9673 16.7056C6.48054 16.7056 6.08594 17.1002 6.08594 17.5869C6.08594 18.0737 6.48054 18.4683 6.9673 18.4683H33.0307C33.5174 18.4683 33.912 18.0737 33.912 17.5869C33.912 17.1002 33.5174 16.7056 33.0307 16.7056H6.9673ZM6.08594 21.4618C6.08594 20.975 6.48054 20.5804 6.9673 20.5804H33.0307C33.5174 20.5804 33.912 20.975 33.912 21.4618C33.912 21.9486 33.5174 22.3432 33.0307 22.3432H6.9673C6.48054 22.3432 6.08594 21.9486 6.08594 21.4618ZM21.4704 42.6691C21.1241 42.239 20.5919 42.0085 20.0457 42.0521H19.166V47.0441H20.0251C20.352 47.0567 20.6773 46.9886 20.9727 46.8469C21.213 46.7226 21.4156 46.5345 21.5589 46.3032C21.7076 46.0577 21.8089 45.7862 21.8582 45.5029C21.9164 45.1846 21.9455 44.8615 21.9451 44.5377C21.951 44.1698 21.9106 43.8023 21.8252 43.4446C21.758 43.1653 21.6373 42.9016 21.4704 42.6691ZM13.7445 42.0508C14.085 42.0213 14.4258 42.1008 14.7193 42.2782C14.8136 42.3518 14.8858 42.4501 14.9282 42.5627C14.9825 42.7134 15.0077 42.8731 15.0019 43.0333C15.0093 43.1969 14.9728 43.3594 14.8967 43.5039C14.8311 43.6211 14.7352 43.7175 14.6195 43.7832C14.4961 43.8525 14.361 43.8981 14.2212 43.9182C14.0636 43.9426 13.9041 43.9548 13.7445 43.9544H12.6855V42.0508H13.7445Z\" fill=\"#00236A\"/>\n</svg>";
73
+
72
74
  const File = ({
73
75
  name,
74
76
  label,
@@ -82,8 +84,7 @@ const File = ({
82
84
  fileExtensions,
83
85
  ...props
84
86
  }) => {
85
- const pdfImageName = 'https://play-lh.googleusercontent.com/kIwlXqs28otssKK_9AKwdkB6gouex_U2WmtLshTACnwIJuvOqVvJEzewpzuYBXwXQQ';
86
- const [image, setImage] = React.useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImageName : null);
87
+ const [image, setImage] = React.useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImage : null);
87
88
  const [error, setError] = React.useState('');
88
89
  const [fileName, setFileName] = React.useState('no selected file');
89
90
  const handleCheckFile = e => {
@@ -96,7 +97,7 @@ const File = ({
96
97
  onChange({
97
98
  file
98
99
  });
99
- setImage(pdfImageName);
100
+ setImage(pdfImage);
100
101
  } else {
101
102
  setError('');
102
103
  onChange({
@@ -666,18 +667,30 @@ const Input = ({
666
667
  `;
667
668
  const handleChange = event => {
668
669
  const currentValue = event.target.value;
670
+ setInnerValue(currentValue);
671
+ if (type === 'tel') {
672
+ if (currentValue.length > 8) {
673
+ setInnerValue(currentValue.substr(0, 8));
674
+ }
675
+ if (!phoneNumberRegex.test(currentValue) && telErrorMessage) {
676
+ setInnerErrorMessage(telErrorMessage);
677
+ } else {
678
+ setInnerErrorMessage('');
679
+ }
680
+ }
681
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
682
+ setInnerValue(currentValue.substr(0, maxLength));
683
+ }
684
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
685
+ !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
686
+ }
669
687
  if (onChange) {
670
688
  onChange(currentValue);
671
- } else {
672
- setInnerValue(currentValue);
673
- if (type === 'tel') {
674
- !phoneNumberRegex.test(parseInt(currentValue)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
675
- }
676
- if (maxLength) {
677
- currentValue.length > maxLength ? setInnerValue(currentValue.substr(0, maxLength)) : setInnerValue(currentValue);
689
+ if (type === 'tel' && currentValue.length > 8) {
690
+ onChange(currentValue.substr(0, 8));
678
691
  }
679
- if (regexp) {
680
- !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
692
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
693
+ onChange(currentValue.substr(0, maxLength));
681
694
  }
682
695
  }
683
696
  };
@@ -691,34 +704,28 @@ const Input = ({
691
704
  if (value !== undefined && value !== null) {
692
705
  setInnerValue(value);
693
706
  if (type === 'tel') {
694
- !phoneNumberRegex.test(parseInt(value)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
707
+ if (value.length > 8) {
708
+ setInnerValue(value.substr(0, 8));
709
+ }
710
+ if (!phoneNumberRegex.test(value) && telErrorMessage) {
711
+ setInnerErrorMessage(telErrorMessage);
712
+ } else {
713
+ setInnerErrorMessage('');
714
+ }
695
715
  }
696
- if (maxLength) {
697
- value.length > maxLength ? setInnerValue(value.substr(0, maxLength)) : setInnerValue(value);
716
+ if (maxLength && value.length > maxLength && type !== 'tel') {
717
+ setInnerValue(value.substr(0, maxLength));
698
718
  }
699
- if (regexp) {
719
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
700
720
  !regexp.test(value) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
701
721
  }
702
722
  }
703
- if (onChange && (value === undefined || value === null)) {
704
- alert('Please add value prop on input component');
705
- }
706
- }, [value, onChange]);
707
- React.useEffect(() => {
708
723
  if (errorMessage) {
709
724
  setInnerErrorMessage(errorMessage);
725
+ } else {
726
+ setInnerErrorMessage('');
710
727
  }
711
- }, [errorMessage]);
712
- React.useEffect(() => {
713
- if (type === 'tel' && !telErrorMessage) {
714
- alert('Please add telErrorMessage on input component');
715
- }
716
- }, [type]);
717
- React.useEffect(() => {
718
- if (regexp && !regexpErrorMessage) {
719
- alert('Please add regexpErrorMessage prop on input component');
720
- }
721
- }, [regexp]);
728
+ }, [type, value, regexp, maxLength, errorMessage, regexpErrorMessage]);
722
729
  return /*#__PURE__*/React__default["default"].createElement("div", {
723
730
  className: `${styles$8["input-wrap"]}`
724
731
  }, label ? /*#__PURE__*/React__default["default"].createElement("label", {
@@ -1983,7 +1990,7 @@ styleInject(css_248z$1);
1983
1990
 
1984
1991
  // import styles from "./pagination.module.scss";
1985
1992
 
1986
- const Dots = "...";
1993
+ const Dots$1 = "...";
1987
1994
  const range = (start, end) => {
1988
1995
  const length = end - start + 1;
1989
1996
  return Array.from({
@@ -2013,22 +2020,58 @@ const PaginationRange = ({
2013
2020
  if (!shouldShowLeftDots && shouldShowRightDots) {
2014
2021
  let leftItemCount = currentPageNumber === 4 && lastPageIndex > 7 ? 4 + siblingCountNumber : 3 + siblingCountNumber;
2015
2022
  let leftRange = range(1, leftItemCount);
2016
- return [...leftRange, Dots, totalPageCount];
2023
+ return [...leftRange, Dots$1, totalPageCount];
2017
2024
  }
2018
2025
  if (shouldShowLeftDots && !shouldShowRightDots) {
2019
2026
  let rightItemCount = 0;
2020
2027
  currentPageNumber === lastPageIndex - 3 && lastPageIndex > 7 ? rightItemCount = 4 + siblingCountNumber : rightItemCount = 3 + siblingCountNumber;
2021
2028
  let rightRange = range(totalPageCount - rightItemCount + 1, totalPageCount);
2022
- return [firstPageIndex, Dots, ...rightRange];
2029
+ return [firstPageIndex, Dots$1, ...rightRange];
2023
2030
  }
2024
2031
  if (shouldShowLeftDots && shouldShowRightDots) {
2025
2032
  let middleRange = range(leftSiblingIndex, rightSiblingIndex);
2026
- return [firstPageIndex, Dots, ...middleRange, Dots, lastPageIndex];
2033
+ return [firstPageIndex, Dots$1, ...middleRange, Dots$1, lastPageIndex];
2027
2034
  }
2028
2035
  }, [currentTotalCount, offset, siblingCountNumber, currentPageNumber]);
2029
2036
  return paginationRange;
2030
2037
  };
2031
2038
 
2039
+ const Dots = ({
2040
+ title,
2041
+ titleId,
2042
+ ...props
2043
+ }) => /*#__PURE__*/React__namespace.createElement("svg", _extends({
2044
+ width: "1em",
2045
+ height: "1em",
2046
+ viewBox: "0 0 11 3",
2047
+ fill: "none",
2048
+ xmlns: "http://www.w3.org/2000/svg",
2049
+ "aria-labelledby": titleId
2050
+ }, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
2051
+ id: titleId
2052
+ }, title) : null, /*#__PURE__*/React__namespace.createElement("path", {
2053
+ d: "M0.230125 1.13624C0.230125 0.741577 0.326125 0.464244 0.518125 0.304244C0.710125 0.144244 0.939458 0.064244 1.20613 0.064244C1.48346 0.064244 1.71813 0.144244 1.91013 0.304244C2.11279 0.464244 2.21413 0.741577 2.21413 1.13624C2.21413 1.52024 2.11279 1.79758 1.91013 1.96824C1.71813 2.13891 1.48346 2.22424 1.20613 2.22424C0.939458 2.22424 0.710125 2.13891 0.518125 1.96824C0.326125 1.79758 0.230125 1.52024 0.230125 1.13624ZM4.51138 1.13624C4.51138 0.741577 4.60738 0.464244 4.79938 0.304244C4.99138 0.144244 5.22071 0.064244 5.48738 0.064244C5.76471 0.064244 5.99938 0.144244 6.19138 0.304244C6.39404 0.464244 6.49538 0.741577 6.49538 1.13624C6.49538 1.52024 6.39404 1.79758 6.19138 1.96824C5.99938 2.13891 5.76471 2.22424 5.48738 2.22424C5.22071 2.22424 4.99138 2.13891 4.79938 1.96824C4.60738 1.79758 4.51138 1.52024 4.51138 1.13624ZM8.79263 1.13624C8.79263 0.741577 8.88863 0.464244 9.08063 0.304244C9.27263 0.144244 9.50196 0.064244 9.76863 0.064244C10.046 0.064244 10.2806 0.144244 10.4726 0.304244C10.6753 0.464244 10.7766 0.741577 10.7766 1.13624C10.7766 1.52024 10.6753 1.79758 10.4726 1.96824C10.2806 2.13891 10.046 2.22424 9.76863 2.22424C9.50196 2.22424 9.27263 2.13891 9.08063 1.96824C8.88863 1.79758 8.79263 1.52024 8.79263 1.13624Z",
2054
+ fill: "#3C393E"
2055
+ }));
2056
+
2057
+ const SvgNextArrow = ({
2058
+ title,
2059
+ titleId,
2060
+ ...props
2061
+ }) => /*#__PURE__*/React__namespace.createElement("svg", _extends({
2062
+ width: "1em",
2063
+ height: "1em",
2064
+ viewBox: "0 0 6 12",
2065
+ fill: "none",
2066
+ xmlns: "http://www.w3.org/2000/svg",
2067
+ "aria-labelledby": titleId
2068
+ }, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
2069
+ id: titleId
2070
+ }, title) : null, /*#__PURE__*/React__namespace.createElement("path", {
2071
+ d: "M0.851445 11.9985C0.652853 11.9988 0.460393 11.9292 0.307477 11.8017C0.221413 11.7299 0.150271 11.6418 0.0981246 11.5423C0.0459785 11.4428 0.0138536 11.3339 0.0035897 11.2219C-0.00667418 11.1098 0.00512483 10.9969 0.0383107 10.8895C0.0714965 10.7821 0.125416 10.6823 0.196984 10.5958L4.00476 6.01173L0.332976 1.41906C0.262375 1.33158 0.209651 1.23092 0.177836 1.12286C0.146021 1.01481 0.135741 0.901501 0.147589 0.789439C0.159437 0.677378 0.193177 0.568777 0.246871 0.469879C0.300566 0.370982 0.373156 0.283737 0.460468 0.213159C0.548409 0.135301 0.651394 0.0765731 0.76296 0.0406621C0.874526 0.00475112 0.992266 -0.00756759 1.10879 0.00447845C1.22531 0.0165245 1.3381 0.0526755 1.44008 0.110663C1.54206 0.16865 1.63102 0.247221 1.70139 0.341446L5.80665 5.47292C5.93166 5.62596 6 5.81791 6 6.01601C6 6.2141 5.93166 6.40606 5.80665 6.55909L1.5569 11.6906C1.47164 11.7941 1.36333 11.8759 1.24075 11.9294C1.11818 11.9829 0.984807 12.0065 0.851445 11.9985Z",
2072
+ fill: "#3C393E"
2073
+ }));
2074
+
2032
2075
  const Pagination = ({
2033
2076
  onChange,
2034
2077
  totalCount,
@@ -2083,13 +2126,14 @@ const Pagination = ({
2083
2126
  return /*#__PURE__*/React__default["default"].createElement("ul", {
2084
2127
  className: classProps
2085
2128
  }, /*#__PURE__*/React__default["default"].createElement("button", {
2129
+ style: {
2130
+ transform: 'rotate(180deg)'
2131
+ },
2086
2132
  className: `${styles$1["pagination-btn"]} pagination-btn-rem`,
2087
2133
  onClick: onPrevious,
2088
2134
  disabled: currentPage === 1 ? true : false
2089
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2090
- className: "icon-arrow-back"
2091
- })), paginationRange.map((pageNumber, id) => {
2092
- if (pageNumber === Dots) {
2135
+ }, /*#__PURE__*/React__default["default"].createElement(SvgNextArrow, null)), paginationRange.map((pageNumber, id) => {
2136
+ if (pageNumber === Dots$1) {
2093
2137
  let currentPageIndex = paginationRange.indexOf(currentPageNumber);
2094
2138
  return /*#__PURE__*/React__default["default"].createElement("li", {
2095
2139
  key: id,
@@ -2098,21 +2142,16 @@ const Pagination = ({
2098
2142
  disabled: currentPageIndex === 0 ? true : false
2099
2143
  }, id < currentPageIndex ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("span", {
2100
2144
  className: `${styles$1["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
2101
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2102
- className: "icon-text"
2103
- })), /*#__PURE__*/React__default["default"].createElement("span", {
2104
- className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
2105
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2106
- className: "icon-arrow-jump-back"
2107
- }))) : /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("span", {
2145
+ }, /*#__PURE__*/React__default["default"].createElement(Dots, null)), /*#__PURE__*/React__default["default"].createElement("span", {
2146
+ className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`,
2147
+ style: {
2148
+ transform: 'rotate(180deg)'
2149
+ }
2150
+ }, /*#__PURE__*/React__default["default"].createElement(SvgNextArrow, null))) : /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("span", {
2108
2151
  className: `${styles$1["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
2109
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2110
- className: "icon-text"
2111
- })), /*#__PURE__*/React__default["default"].createElement("span", {
2152
+ }, /*#__PURE__*/React__default["default"].createElement(Dots, null)), /*#__PURE__*/React__default["default"].createElement("span", {
2112
2153
  className: `${styles$1["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
2113
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2114
- className: "icon-arrow-jump-next"
2115
- }))));
2154
+ }, /*#__PURE__*/React__default["default"].createElement(SvgNextArrow, null))));
2116
2155
  }
2117
2156
  return /*#__PURE__*/React__default["default"].createElement("li", {
2118
2157
  onClick: () => onPageChange(pageNumber),
@@ -2123,9 +2162,7 @@ const Pagination = ({
2123
2162
  onClick: onNext,
2124
2163
  className: `${styles$1["pagination-btn"]} pagination-btn-rem`,
2125
2164
  disabled: currentPageNumber === lastPage ? true : false
2126
- }, /*#__PURE__*/React__default["default"].createElement("i", {
2127
- className: "icon-arrow"
2128
- })));
2165
+ }, /*#__PURE__*/React__default["default"].createElement(SvgNextArrow, null)));
2129
2166
  };
2130
2167
  Pagination.propTypes = {
2131
2168
  offset: PropTypes__default["default"].number,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xaypay/tui",
3
- "version": "0.0.67",
3
+ "version": "0.0.68",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.es.js",
@@ -0,0 +1,3 @@
1
+ <svg width="11" height="3" viewBox="0 0 11 3" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M0.230125 1.13624C0.230125 0.741577 0.326125 0.464244 0.518125 0.304244C0.710125 0.144244 0.939458 0.064244 1.20613 0.064244C1.48346 0.064244 1.71813 0.144244 1.91013 0.304244C2.11279 0.464244 2.21413 0.741577 2.21413 1.13624C2.21413 1.52024 2.11279 1.79758 1.91013 1.96824C1.71813 2.13891 1.48346 2.22424 1.20613 2.22424C0.939458 2.22424 0.710125 2.13891 0.518125 1.96824C0.326125 1.79758 0.230125 1.52024 0.230125 1.13624ZM4.51138 1.13624C4.51138 0.741577 4.60738 0.464244 4.79938 0.304244C4.99138 0.144244 5.22071 0.064244 5.48738 0.064244C5.76471 0.064244 5.99938 0.144244 6.19138 0.304244C6.39404 0.464244 6.49538 0.741577 6.49538 1.13624C6.49538 1.52024 6.39404 1.79758 6.19138 1.96824C5.99938 2.13891 5.76471 2.22424 5.48738 2.22424C5.22071 2.22424 4.99138 2.13891 4.79938 1.96824C4.60738 1.79758 4.51138 1.52024 4.51138 1.13624ZM8.79263 1.13624C8.79263 0.741577 8.88863 0.464244 9.08063 0.304244C9.27263 0.144244 9.50196 0.064244 9.76863 0.064244C10.046 0.064244 10.2806 0.144244 10.4726 0.304244C10.6753 0.464244 10.7766 0.741577 10.7766 1.13624C10.7766 1.52024 10.6753 1.79758 10.4726 1.96824C10.2806 2.13891 10.046 2.22424 9.76863 2.22424C9.50196 2.22424 9.27263 2.13891 9.08063 1.96824C8.88863 1.79758 8.79263 1.52024 8.79263 1.13624Z" fill="#3C393E"/>
3
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="6" height="12" viewBox="0 0 6 12" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M0.851445 11.9985C0.652853 11.9988 0.460393 11.9292 0.307477 11.8017C0.221413 11.7299 0.150271 11.6418 0.0981246 11.5423C0.0459785 11.4428 0.0138536 11.3339 0.0035897 11.2219C-0.00667418 11.1098 0.00512483 10.9969 0.0383107 10.8895C0.0714965 10.7821 0.125416 10.6823 0.196984 10.5958L4.00476 6.01173L0.332976 1.41906C0.262375 1.33158 0.209651 1.23092 0.177836 1.12286C0.146021 1.01481 0.135741 0.901501 0.147589 0.789439C0.159437 0.677378 0.193177 0.568777 0.246871 0.469879C0.300566 0.370982 0.373156 0.283737 0.460468 0.213159C0.548409 0.135301 0.651394 0.0765731 0.76296 0.0406621C0.874526 0.00475112 0.992266 -0.00756759 1.10879 0.00447845C1.22531 0.0165245 1.3381 0.0526755 1.44008 0.110663C1.54206 0.16865 1.63102 0.247221 1.70139 0.341446L5.80665 5.47292C5.93166 5.62596 6 5.81791 6 6.01601C6 6.2141 5.93166 6.40606 5.80665 6.55909L1.5569 11.6906C1.47164 11.7941 1.36333 11.8759 1.24075 11.9294C1.11818 11.9829 0.984807 12.0065 0.851445 11.9985Z" fill="#3C393E"/>
3
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="40" height="52" viewBox="0 0 40 52" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M39.1304 13.1106V36.2849V36.2853C39.394 36.4388 39.6133 36.6599 39.7659 36.9263C39.9189 37.1931 39.9992 37.4956 40 37.8037V47.5932C39.9984 48.7614 39.54 49.8816 38.7252 50.7079C37.91 51.5337 36.8048 51.9984 35.6522 52H4.34783C3.19523 51.9984 2.09005 51.5338 1.27483 50.7079C0.460015 49.8816 0.0015528 48.7614 0 47.5932V34.7817C0.000775155 34.4736 0.0815204 34.1714 0.234087 33.9051C0.386643 33.6383 0.605983 33.4176 0.869565 33.2641V3.52545C0.869565 2.5906 1.23602 1.69387 1.8882 1.03245C2.54072 0.371431 3.42547 0 4.34783 0H26.1953L39.1304 13.1106ZM13.872 45.3893C14.6037 45.4385 15.3293 45.2261 15.9225 44.7893C16.4303 44.3463 16.7036 43.6872 16.6605 43.0096C16.671 42.6272 16.598 42.2471 16.4478 41.8965C16.3154 41.6026 16.1136 41.3464 15.8597 41.1509C15.5976 40.9542 15.2991 40.8137 14.9816 40.7385C14.6225 40.6512 14.2541 40.6083 13.8849 40.6115H11.0258V48.4741H12.6849V45.3893H13.872ZM22.6954 47.4563C23.0149 47.1041 23.2498 46.6815 23.3814 46.2224C23.5347 45.6809 23.6084 45.1195 23.5999 44.5564C23.6065 44.008 23.5362 43.4614 23.3918 42.933C23.2672 42.477 23.0475 42.0532 22.7474 41.6904C22.4465 41.3379 22.0669 41.064 21.6398 40.8917C21.1305 40.6934 20.5882 40.5982 20.0432 40.6116H17.506V48.4821H20.0642C21.0475 48.5494 22.0103 48.1743 22.6954 47.4563ZM26.1252 42.05H29.4956L29.4956 40.6115H24.4661V48.4804L26.1287 48.4808V45.1068L28.6505 45.0962L28.64 43.6577H26.1252V42.05ZM18.3352 36.0407H37.3911L37.3908 14.3567H28.4428C27.5205 14.3567 26.6358 13.9852 25.9836 13.3238C25.331 12.6628 24.9646 11.7661 24.9646 10.8312V1.76186H4.34743C3.88625 1.76186 3.4437 1.94758 3.11762 2.27808C2.79153 2.60859 2.6083 3.05715 2.6083 3.52458V33.0185H14.9392C15.4408 33.0185 15.9179 33.238 16.2482 33.6205L18.3352 36.0407ZM6.08594 13.7151C6.08594 13.2283 6.48054 12.8337 6.9673 12.8337H20.6043C21.0911 12.8337 21.4857 13.2283 21.4857 13.7151C21.4857 14.2019 21.0911 14.5965 20.6043 14.5965H6.9673C6.48054 14.5965 6.08594 14.2019 6.08594 13.7151ZM18.5137 25.3369C18.5137 24.8502 18.9083 24.4556 19.395 24.4556H33.0321C33.5188 24.4556 33.9134 24.8502 33.9134 25.3369C33.9134 25.8237 33.5188 26.2183 33.0321 26.2183H19.395C18.9083 26.2183 18.5137 25.8237 18.5137 25.3369ZM6.9673 16.7056C6.48054 16.7056 6.08594 17.1002 6.08594 17.5869C6.08594 18.0737 6.48054 18.4683 6.9673 18.4683H33.0307C33.5174 18.4683 33.912 18.0737 33.912 17.5869C33.912 17.1002 33.5174 16.7056 33.0307 16.7056H6.9673ZM6.08594 21.4618C6.08594 20.975 6.48054 20.5804 6.9673 20.5804H33.0307C33.5174 20.5804 33.912 20.975 33.912 21.4618C33.912 21.9486 33.5174 22.3432 33.0307 22.3432H6.9673C6.48054 22.3432 6.08594 21.9486 6.08594 21.4618ZM21.4704 42.6691C21.1241 42.239 20.5919 42.0085 20.0457 42.0521H19.166V47.0441H20.0251C20.352 47.0567 20.6773 46.9886 20.9727 46.8469C21.213 46.7226 21.4156 46.5345 21.5589 46.3032C21.7076 46.0577 21.8089 45.7862 21.8582 45.5029C21.9164 45.1846 21.9455 44.8615 21.9451 44.5377C21.951 44.1698 21.9106 43.8023 21.8252 43.4446C21.758 43.1653 21.6373 42.9016 21.4704 42.6691ZM13.7445 42.0508C14.085 42.0213 14.4258 42.1008 14.7193 42.2782C14.8136 42.3518 14.8858 42.4501 14.9282 42.5627C14.9825 42.7134 15.0077 42.8731 15.0019 43.0333C15.0093 43.1969 14.9728 43.3594 14.8967 43.5039C14.8311 43.6211 14.7352 43.7175 14.6195 43.7832C14.4961 43.8525 14.361 43.8981 14.2212 43.9182C14.0636 43.9426 13.9041 43.9548 13.7445 43.9544H12.6855V42.0508H13.7445Z" fill="#00236A"/>
3
+ </svg>
@@ -98,7 +98,7 @@
98
98
  }
99
99
  .upload-file-content > img {
100
100
  display: block;
101
- width: 27.8rem;
101
+ width: 2.5rem;
102
102
  height: auto;
103
103
  max-height: 95%;
104
104
  object-fit: contain;
@@ -2,7 +2,8 @@ import React, { useState } from "react";
2
2
  import PropTypes from "prop-types";
3
3
  import classnames from "classnames";
4
4
  import styles from "./file.module.css";
5
- import Icon from '../icon/Icon'
5
+ import Icon from '../icon/Icon';
6
+ import pdfImage from './../../assets/pdf.svg';
6
7
 
7
8
  export const File = ({
8
9
  name,
@@ -17,8 +18,7 @@ export const File = ({
17
18
  fileExtensions,
18
19
  ...props
19
20
  }) => {
20
- const pdfImageName = 'https://play-lh.googleusercontent.com/kIwlXqs28otssKK_9AKwdkB6gouex_U2WmtLshTACnwIJuvOqVvJEzewpzuYBXwXQQ'
21
- const [image, setImage] = useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImageName : null);
21
+ const [image, setImage] = useState(defaultData ? defaultData.type != 'application/pdf' ? defaultData.url : pdfImage : null);
22
22
  const [error, setError] = useState('');
23
23
  const [fileName, setFileName] = useState('no selected file');
24
24
 
@@ -31,7 +31,7 @@ export const File = ({
31
31
  if (file[0].type === 'application/pdf') {
32
32
  setError('');
33
33
  onChange({file});
34
- setImage(pdfImageName);
34
+ setImage(pdfImage);
35
35
  } else {
36
36
  setError('');
37
37
  onChange({file});
@@ -0,0 +1,19 @@
1
+ import * as React from "react";
2
+ const Dots = ({ title, titleId, ...props }) => (
3
+ <svg
4
+ width="1em"
5
+ height="1em"
6
+ viewBox="0 0 11 3"
7
+ fill="none"
8
+ xmlns="http://www.w3.org/2000/svg"
9
+ aria-labelledby={titleId}
10
+ {...props}
11
+ >
12
+ {title ? <title id={titleId}>{title}</title> : null}
13
+ <path
14
+ d="M0.230125 1.13624C0.230125 0.741577 0.326125 0.464244 0.518125 0.304244C0.710125 0.144244 0.939458 0.064244 1.20613 0.064244C1.48346 0.064244 1.71813 0.144244 1.91013 0.304244C2.11279 0.464244 2.21413 0.741577 2.21413 1.13624C2.21413 1.52024 2.11279 1.79758 1.91013 1.96824C1.71813 2.13891 1.48346 2.22424 1.20613 2.22424C0.939458 2.22424 0.710125 2.13891 0.518125 1.96824C0.326125 1.79758 0.230125 1.52024 0.230125 1.13624ZM4.51138 1.13624C4.51138 0.741577 4.60738 0.464244 4.79938 0.304244C4.99138 0.144244 5.22071 0.064244 5.48738 0.064244C5.76471 0.064244 5.99938 0.144244 6.19138 0.304244C6.39404 0.464244 6.49538 0.741577 6.49538 1.13624C6.49538 1.52024 6.39404 1.79758 6.19138 1.96824C5.99938 2.13891 5.76471 2.22424 5.48738 2.22424C5.22071 2.22424 4.99138 2.13891 4.79938 1.96824C4.60738 1.79758 4.51138 1.52024 4.51138 1.13624ZM8.79263 1.13624C8.79263 0.741577 8.88863 0.464244 9.08063 0.304244C9.27263 0.144244 9.50196 0.064244 9.76863 0.064244C10.046 0.064244 10.2806 0.144244 10.4726 0.304244C10.6753 0.464244 10.7766 0.741577 10.7766 1.13624C10.7766 1.52024 10.6753 1.79758 10.4726 1.96824C10.2806 2.13891 10.046 2.22424 9.76863 2.22424C9.50196 2.22424 9.27263 2.13891 9.08063 1.96824C8.88863 1.79758 8.79263 1.52024 8.79263 1.13624Z"
15
+ fill="#3C393E"
16
+ />
17
+ </svg>
18
+ );
19
+ export default Dots;
@@ -0,0 +1,19 @@
1
+ import * as React from "react";
2
+ const SvgNextArrow = ({ title, titleId, ...props }) => (
3
+ <svg
4
+ width="1em"
5
+ height="1em"
6
+ viewBox="0 0 6 12"
7
+ fill="none"
8
+ xmlns="http://www.w3.org/2000/svg"
9
+ aria-labelledby={titleId}
10
+ {...props}
11
+ >
12
+ {title ? <title id={titleId}>{title}</title> : null}
13
+ <path
14
+ d="M0.851445 11.9985C0.652853 11.9988 0.460393 11.9292 0.307477 11.8017C0.221413 11.7299 0.150271 11.6418 0.0981246 11.5423C0.0459785 11.4428 0.0138536 11.3339 0.0035897 11.2219C-0.00667418 11.1098 0.00512483 10.9969 0.0383107 10.8895C0.0714965 10.7821 0.125416 10.6823 0.196984 10.5958L4.00476 6.01173L0.332976 1.41906C0.262375 1.33158 0.209651 1.23092 0.177836 1.12286C0.146021 1.01481 0.135741 0.901501 0.147589 0.789439C0.159437 0.677378 0.193177 0.568777 0.246871 0.469879C0.300566 0.370982 0.373156 0.283737 0.460468 0.213159C0.548409 0.135301 0.651394 0.0765731 0.76296 0.0406621C0.874526 0.00475112 0.992266 -0.00756759 1.10879 0.00447845C1.22531 0.0165245 1.3381 0.0526755 1.44008 0.110663C1.54206 0.16865 1.63102 0.247221 1.70139 0.341446L5.80665 5.47292C5.93166 5.62596 6 5.81791 6 6.01601C6 6.2141 5.93166 6.40606 5.80665 6.55909L1.5569 11.6906C1.47164 11.7941 1.36333 11.8759 1.24075 11.9294C1.11818 11.9829 0.984807 12.0065 0.851445 11.9985Z"
15
+ fill="#3C393E"
16
+ />
17
+ </svg>
18
+ );
19
+ export default SvgNextArrow;
@@ -97,20 +97,36 @@ export const Input = ({
97
97
 
98
98
  const handleChange = (event) => {
99
99
  const currentValue = event.target.value;
100
+
101
+ setInnerValue(currentValue);
102
+ if (type === 'tel') {
103
+ if (currentValue.length > 8) {
104
+ setInnerValue(currentValue.substr(0, 8));
105
+ }
106
+
107
+ if (!phoneNumberRegex.test(currentValue) && telErrorMessage) {
108
+ setInnerErrorMessage(telErrorMessage);
109
+ } else {
110
+ setInnerErrorMessage('');
111
+ }
112
+ }
113
+
114
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
115
+ setInnerValue(currentValue.substr(0, maxLength));
116
+ }
117
+
118
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
119
+ !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('')
120
+ }
121
+
100
122
  if (onChange) {
101
123
  onChange(currentValue);
102
- } else {
103
- setInnerValue(currentValue);
104
- if (type === 'tel') {
105
- !phoneNumberRegex.test(parseInt(currentValue)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
106
- }
107
-
108
- if (maxLength) {
109
- currentValue.length > maxLength ? setInnerValue(currentValue.substr(0, maxLength)) : setInnerValue(currentValue);
124
+ if (type === 'tel' && currentValue.length > 8) {
125
+ onChange(currentValue.substr(0, 8));
110
126
  }
111
127
 
112
- if (regexp) {
113
- !regexp.test(currentValue) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
128
+ if (maxLength && currentValue.length > maxLength && type !== 'tel') {
129
+ onChange(currentValue.substr(0, maxLength));
114
130
  }
115
131
  }
116
132
  };
@@ -127,40 +143,32 @@ export const Input = ({
127
143
  if (value !== undefined && value !== null) {
128
144
  setInnerValue(value);
129
145
  if (type === 'tel') {
130
- !phoneNumberRegex.test(parseInt(value)) ? setInnerErrorMessage(telErrorMessage) : setInnerErrorMessage('');
131
- }
146
+ if (value.length > 8) {
147
+ setInnerValue(value.substr(0, 8));
148
+ }
132
149
 
133
- if (maxLength) {
134
- value.length > maxLength ? setInnerValue(value.substr(0, maxLength)) : setInnerValue(value);
150
+ if (!phoneNumberRegex.test(value) && telErrorMessage) {
151
+ setInnerErrorMessage(telErrorMessage);
152
+ } else {
153
+ setInnerErrorMessage('');
154
+ }
135
155
  }
136
156
 
137
- if (regexp) {
138
- !regexp.test(value) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('');
157
+ if (maxLength && value.length > maxLength && type !== 'tel') {
158
+ setInnerValue(value.substr(0, maxLength));
139
159
  }
140
- }
141
160
 
142
- if (onChange && (value === undefined || value === null)) {
143
- alert('Please add value prop on input component');
161
+ if (regexp && regexpErrorMessage && !maxLength && type !== 'tel') {
162
+ !regexp.test(value) ? setInnerErrorMessage(regexpErrorMessage) : setInnerErrorMessage('')
163
+ }
144
164
  }
145
- }, [value, onChange]);
146
165
 
147
- useEffect(() => {
148
166
  if (errorMessage) {
149
167
  setInnerErrorMessage(errorMessage);
168
+ } else {
169
+ setInnerErrorMessage('');
150
170
  }
151
- }, [errorMessage]);
152
-
153
- useEffect(() => {
154
- if (type === 'tel' && !telErrorMessage) {
155
- alert('Please add telErrorMessage on input component');
156
- }
157
- }, [type]);
158
-
159
- useEffect(() => {
160
- if (regexp && !regexpErrorMessage) {
161
- alert('Please add regexpErrorMessage prop on input component');
162
- }
163
- }, [regexp]);
171
+ }, [type, value, regexp, maxLength, errorMessage, regexpErrorMessage]);
164
172
 
165
173
  return (
166
174
  <div className={`${styles["input-wrap"]}`}>
@@ -5,6 +5,9 @@ import styles from "./pagination.module.css";
5
5
  import { PaginationRange, Dots } from "./paginationRange";
6
6
  import Icon from "../icon/Icon";
7
7
 
8
+ import DotsIcon from './../../components/icon/Dots';
9
+ import SvgNextArrow from './../../components/icon/NextArrow';
10
+
8
11
  export const Pagination = ({
9
12
  onChange,
10
13
  totalCount,
@@ -68,12 +71,14 @@ export const Pagination = ({
68
71
  return (
69
72
  <ul className={classProps}>
70
73
  <button
74
+ style={{
75
+ transform: 'rotate(180deg)'
76
+ }}
71
77
  className={`${styles["pagination-btn"]} pagination-btn-rem`}
72
78
  onClick={onPrevious}
73
79
  disabled={currentPage === 1 ? true : false}
74
80
  >
75
- {/* <Icon className="icon-arrow-back"/> */}
76
- <i className="icon-arrow-back"></i>
81
+ <SvgNextArrow />
77
82
  </button>
78
83
 
79
84
  {paginationRange.map((pageNumber, id) => {
@@ -100,15 +105,17 @@ export const Pagination = ({
100
105
  `${styles["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
101
106
  }
102
107
  >
103
- <i className="icon-text" />
108
+ <DotsIcon />
104
109
  </span>
105
110
  <span
106
111
  className={
107
112
  `${styles["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
108
113
  }
114
+ style={{
115
+ transform: 'rotate(180deg)'
116
+ }}
109
117
  >
110
- {/* <Icon className="icon-arrow-jump-next"/> */}
111
- <i className="icon-arrow-jump-back"></i>
118
+ <SvgNextArrow />
112
119
  </span>
113
120
  </>
114
121
  ) : (
@@ -118,15 +125,14 @@ export const Pagination = ({
118
125
  `${styles["pagination-jump-next-txt"]} pagination-jump-next-txt-rem`
119
126
  }
120
127
  >
121
- <i className="icon-text" />
128
+ <DotsIcon />
122
129
  </span>
123
130
  <span
124
131
  className={
125
132
  `${styles["pagination-jump-next-arrow"]} pagination-jump-next-arrow-rem`
126
133
  }
127
134
  >
128
- {/* <Icon className="icon-arrow-jump-next"/> */}
129
- <i className="icon-arrow-jump-next"></i>
135
+ <SvgNextArrow />
130
136
  </span>
131
137
  </>
132
138
  )}
@@ -156,8 +162,7 @@ export const Pagination = ({
156
162
  className={`${styles["pagination-btn"]} pagination-btn-rem`}
157
163
  disabled={currentPageNumber === lastPage ? true : false}
158
164
  >
159
- {/* <Icon className='icon-arrow'/> */}
160
- <i className="icon-arrow"></i>
165
+ <SvgNextArrow />
161
166
  </button>
162
167
  </ul>
163
168
  );