react-gldn-kit 0.1.153 → 0.1.155

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.
@@ -147,9 +147,6 @@ var PhoneBox = function (props) {
147
147
  return;
148
148
  }
149
149
  var baseValue = phone.value;
150
- if (countryPhoneSettings.code === '+880') {
151
- baseValue = '1';
152
- }
153
150
  setPhone({
154
151
  value: baseValue,
155
152
  errorText: '',
@@ -15,6 +15,6 @@ exports.EnSvg = void 0;
15
15
  var jsx_runtime_1 = require("react/jsx-runtime");
16
16
  var EnSvg = function (props) {
17
17
  var _a = props.width, width = _a === void 0 ? '16' : _a, _b = props.height, height = _b === void 0 ? '16' : _b, classes = props.classes;
18
- return ((0, jsx_runtime_1.jsxs)("svg", __assign({ width: width, height: height, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: classes }, { children: [(0, jsx_runtime_1.jsxs)("g", __assign({ "clip-path": "url(#clip0_4542_148116)" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M8 16C12.4183 16 16 12.4183 16 8C16 3.58172 12.4183 0 8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16Z", fill: "#F0F0F0" }), (0, jsx_runtime_1.jsx)("path", { d: "M1.65379 3.12944C1.02538 3.94703 0.551541 4.88938 0.275635 5.9131H4.43745L1.65379 3.12944Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M15.7245 5.9131C15.4486 4.88941 14.9747 3.94706 14.3463 3.12947L11.5627 5.9131H15.7245Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M0.275635 10.087C0.551572 11.1107 1.02542 12.053 1.65379 12.8706L4.43735 10.087H0.275635Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M12.8705 1.65378C12.0529 1.02538 11.1106 0.551534 10.0869 0.275597V4.43738L12.8705 1.65378Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M3.12939 14.3462C3.94699 14.9746 4.88933 15.4485 5.91302 15.7244V11.5627L3.12939 14.3462Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91299 0.275597C4.8893 0.551534 3.94696 1.02538 3.12939 1.65375L5.91299 4.43735V0.275597Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 15.7244C11.1106 15.4485 12.0529 14.9746 12.8705 14.3463L10.0869 11.5627V15.7244Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M11.5627 10.087L14.3463 12.8706C14.9747 12.0531 15.4486 11.1107 15.7245 10.087H11.5627Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M15.9323 6.95653H9.04353H9.0435V0.0677188C8.70191 0.02325 8.35366 0 8 0C7.64628 0 7.29809 0.02325 6.95653 0.0677188V6.95647V6.9565H0.0677188C0.02325 7.29809 0 7.64634 0 8C0 8.35372 0.02325 8.70191 0.0677188 9.04347H6.95647H6.9565V15.9323C7.29809 15.9768 7.64628 16 8 16C8.35366 16 8.70191 15.9768 9.04347 15.9323V9.04353V9.0435H15.9323C15.9768 8.70191 16 8.35372 16 8C16 7.64634 15.9768 7.29809 15.9323 6.95653Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 10.087L13.6568 13.6569C13.821 13.4927 13.9776 13.3212 14.127 13.1433L11.0707 10.087H10.0869V10.087Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91292 10.087H5.91286L2.34302 13.6568C2.50714 13.821 2.67874 13.9777 2.85661 14.1271L5.91292 11.0707V10.087Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91293 5.91309V5.91303L2.34305 2.34312C2.17887 2.50725 2.02224 2.67884 1.8728 2.85672L4.92915 5.91306H5.91293V5.91309Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 5.9131L13.6568 2.34316C13.4927 2.17897 13.3211 2.02235 13.1432 1.87294L10.0869 4.92928V5.9131Z", fill: "#D80027" })] })), (0, jsx_runtime_1.jsx)("defs", { children: (0, jsx_runtime_1.jsx)("clipPath", __assign({ id: "clip0_4542_148116" }, { children: (0, jsx_runtime_1.jsx)("rect", { width: "16", height: "16", fill: "white" }) })) })] })));
18
+ return ((0, jsx_runtime_1.jsxs)("svg", __assign({ width: width, height: height, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: classes }, { children: [(0, jsx_runtime_1.jsxs)("g", __assign({ clipPath: "url(#clip0_4542_148116)" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M8 16C12.4183 16 16 12.4183 16 8C16 3.58172 12.4183 0 8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16Z", fill: "#F0F0F0" }), (0, jsx_runtime_1.jsx)("path", { d: "M1.65379 3.12944C1.02538 3.94703 0.551541 4.88938 0.275635 5.9131H4.43745L1.65379 3.12944Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M15.7245 5.9131C15.4486 4.88941 14.9747 3.94706 14.3463 3.12947L11.5627 5.9131H15.7245Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M0.275635 10.087C0.551572 11.1107 1.02542 12.053 1.65379 12.8706L4.43735 10.087H0.275635Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M12.8705 1.65378C12.0529 1.02538 11.1106 0.551534 10.0869 0.275597V4.43738L12.8705 1.65378Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M3.12939 14.3462C3.94699 14.9746 4.88933 15.4485 5.91302 15.7244V11.5627L3.12939 14.3462Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91299 0.275597C4.8893 0.551534 3.94696 1.02538 3.12939 1.65375L5.91299 4.43735V0.275597Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 15.7244C11.1106 15.4485 12.0529 14.9746 12.8705 14.3463L10.0869 11.5627V15.7244Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M11.5627 10.087L14.3463 12.8706C14.9747 12.0531 15.4486 11.1107 15.7245 10.087H11.5627Z", fill: "#0052B4" }), (0, jsx_runtime_1.jsx)("path", { d: "M15.9323 6.95653H9.04353H9.0435V0.0677188C8.70191 0.02325 8.35366 0 8 0C7.64628 0 7.29809 0.02325 6.95653 0.0677188V6.95647V6.9565H0.0677188C0.02325 7.29809 0 7.64634 0 8C0 8.35372 0.02325 8.70191 0.0677188 9.04347H6.95647H6.9565V15.9323C7.29809 15.9768 7.64628 16 8 16C8.35366 16 8.70191 15.9768 9.04347 15.9323V9.04353V9.0435H15.9323C15.9768 8.70191 16 8.35372 16 8C16 7.64634 15.9768 7.29809 15.9323 6.95653Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 10.087L13.6568 13.6569C13.821 13.4927 13.9776 13.3212 14.127 13.1433L11.0707 10.087H10.0869V10.087Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91292 10.087H5.91286L2.34302 13.6568C2.50714 13.821 2.67874 13.9777 2.85661 14.1271L5.91292 11.0707V10.087Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M5.91293 5.91309V5.91303L2.34305 2.34312C2.17887 2.50725 2.02224 2.67884 1.8728 2.85672L4.92915 5.91306H5.91293V5.91309Z", fill: "#D80027" }), (0, jsx_runtime_1.jsx)("path", { d: "M10.0869 5.9131L13.6568 2.34316C13.4927 2.17897 13.3211 2.02235 13.1432 1.87294L10.0869 4.92928V5.9131Z", fill: "#D80027" })] })), (0, jsx_runtime_1.jsx)("defs", { children: (0, jsx_runtime_1.jsx)("clipPath", __assign({ id: "clip0_4542_148116" }, { children: (0, jsx_runtime_1.jsx)("rect", { width: "16", height: "16", fill: "white" }) })) })] })));
19
19
  };
20
20
  exports.EnSvg = EnSvg;
@@ -12,8 +12,8 @@ exports.PHONE_MASK = {
12
12
  BD: {
13
13
  name: 'Bangladesh',
14
14
  code: '+880',
15
- mask: 'XXXX XXXXXX',
16
- length: 10,
15
+ mask: '1XXX XXXXXX',
16
+ length: 9,
17
17
  Flag: BnSvg_1.BnSvg,
18
18
  },
19
19
  TR: {
@@ -97,9 +97,6 @@ var PhoneInput = function (props) {
97
97
  var handleChooseSettings = function (p) { return function () {
98
98
  setCountryPhoneSettings(p);
99
99
  var value = p.code;
100
- if (p.code === '+880') {
101
- value = '+8801';
102
- }
103
100
  setPhone({
104
101
  value: value,
105
102
  errorText: '',
@@ -181,20 +178,27 @@ var PhoneInput = function (props) {
181
178
  setCountryPhoneSettings(country || constants_1.DEFAULT_COUNTRY_INFO);
182
179
  }, [countryCodeDefault, countryInfo, defaultValueProps]);
183
180
  (0, react_1.useEffect)(function () {
184
- if (phone.value && !phone.errorText) {
181
+ var _a, _b;
182
+ var baseLength = defaultValueProps === '+'
183
+ ? (_a = countryPhoneSettings === null || countryPhoneSettings === void 0 ? void 0 : countryPhoneSettings.code.length) !== null && _a !== void 0 ? _a : 0
184
+ : (_b = defaultValueProps === null || defaultValueProps === void 0 ? void 0 : defaultValueProps.length) !== null && _b !== void 0 ? _b : 0;
185
+ if (phone.value && !phone.errorText && phone.value.length > baseLength) {
185
186
  onChange(phone.value);
186
187
  return;
187
188
  }
188
189
  onChange('');
189
- }, [phone, onChange]);
190
+ }, [
191
+ phone.value,
192
+ phone.errorText,
193
+ defaultValueProps,
194
+ countryPhoneSettings,
195
+ onChange,
196
+ ]);
190
197
  (0, react_1.useEffect)(function () {
191
198
  if (countryPhoneSettings === null || countryPhoneSettings === void 0 ? void 0 : countryPhoneSettings.code) {
192
199
  var baseValue = defaultValueProps !== '+'
193
200
  ? defaultValueProps
194
201
  : countryPhoneSettings.code;
195
- if (countryPhoneSettings.code === '+880') {
196
- baseValue = '+8801';
197
- }
198
202
  setPhone({
199
203
  value: baseValue,
200
204
  errorText: '',
package/dist/main.css CHANGED
@@ -9699,12 +9699,6 @@
9699
9699
  }
9700
9700
 
9701
9701
  @media screen and (min-width: 768px) {
9702
- .KIT__AppNotify-module__wrapperAppNotify___MatrE {
9703
- max-width: 400px;
9704
- left: 0.5%;
9705
- bottom: 5%;
9706
- }
9707
-
9708
9702
  .KIT__AppNotify-module__closePopUp___NioNe {
9709
9703
  cursor: pointer;
9710
9704
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-gldn-kit",
3
- "version": "0.1.153",
3
+ "version": "0.1.155",
4
4
  "description": "",
5
5
  "main": "./dist/index.js",
6
6
  "keywords": [],
@@ -44,7 +44,7 @@
44
44
  "postcss-loader": "^8.1.1",
45
45
  "postcss-preset-env": "^10.1.2",
46
46
  "prettier": "^2.8.8",
47
- "react-render-hooks": "^0.0.114",
47
+ "react-render-hooks": "^0.0.115",
48
48
  "rimraf": "^6.0.1",
49
49
  "scheduler": "^0.25.0",
50
50
  "style-loader": "^4.0.0",