@xaypay/tui 0.2.15 → 0.2.17
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 +1050 -250
- package/dist/index.js +1050 -249
- package/package.json +1 -1
- package/tui.config.js +84 -3
package/dist/index.js
CHANGED
|
@@ -152,6 +152,39 @@ const SvgWrong = ({
|
|
|
152
152
|
fill: "#051942"
|
|
153
153
|
}));
|
|
154
154
|
|
|
155
|
+
const SvgDocIcon = ({
|
|
156
|
+
title,
|
|
157
|
+
titleId,
|
|
158
|
+
...props
|
|
159
|
+
}) => /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
160
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
161
|
+
width: "1em",
|
|
162
|
+
height: "1em",
|
|
163
|
+
fill: "none",
|
|
164
|
+
viewBox: "0 0 32 32",
|
|
165
|
+
"aria-labelledby": titleId
|
|
166
|
+
}, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
|
|
167
|
+
id: titleId
|
|
168
|
+
}, title) : null, /*#__PURE__*/React__namespace.createElement("path", {
|
|
169
|
+
stroke: "#D0D5DD",
|
|
170
|
+
strokeWidth: 1.2,
|
|
171
|
+
d: "M6.2 3.2A2.6 2.6 0 0 1 8.8.6h12.8c.097 0 .19.039.258.107l8.635 8.634a.37.37 0 0 1 .107.259v19.2a2.6 2.6 0 0 1-2.6 2.6H8.8a2.6 2.6 0 0 1-2.6-2.6z"
|
|
172
|
+
}), /*#__PURE__*/React__namespace.createElement("path", {
|
|
173
|
+
stroke: "#D0D5DD",
|
|
174
|
+
strokeWidth: 1.2,
|
|
175
|
+
d: "M21.6.4v6a3.2 3.2 0 0 0 3.2 3.2h6"
|
|
176
|
+
}), /*#__PURE__*/React__namespace.createElement("rect", {
|
|
177
|
+
width: 23.8,
|
|
178
|
+
height: 13.2,
|
|
179
|
+
x: 0.5,
|
|
180
|
+
y: 14.2,
|
|
181
|
+
fill: "#3C68FF",
|
|
182
|
+
rx: 1.6
|
|
183
|
+
}), /*#__PURE__*/React__namespace.createElement("path", {
|
|
184
|
+
fill: "#fff",
|
|
185
|
+
d: "M5.922 23.8H3.859v-5.818h2.08q.878 0 1.511.35.633.346.975.996.343.651.343 1.557 0 .909-.343 1.563-.341.653-.98 1.003-.637.349-1.523.349m-.833-1.054h.782q.546 0 .917-.193.375-.196.563-.605.19-.413.19-1.063 0-.645-.19-1.054a1.23 1.23 0 0 0-.56-.602q-.372-.193-.918-.193H5.09zm9.937-1.855q0 .951-.36 1.62a2.5 2.5 0 0 1-.978 1.02q-.616.348-1.386.349-.776 0-1.392-.353a2.5 2.5 0 0 1-.975-1.02q-.357-.668-.358-1.616 0-.952.358-1.62.359-.667.975-1.017a2.76 2.76 0 0 1 1.392-.352q.77 0 1.386.352.62.35.977 1.018.36.667.361 1.619m-1.247 0q0-.617-.185-1.04a1.4 1.4 0 0 0-.514-.642 1.4 1.4 0 0 0-.778-.219q-.447 0-.779.22-.332.218-.517.641-.182.423-.182 1.04 0 .616.182 1.04.185.423.517.642.332.218.779.218.445 0 .778-.218.333-.219.514-.642.185-.425.185-1.04m7.292-.872h-1.245a1.2 1.2 0 0 0-.139-.43 1.1 1.1 0 0 0-.27-.323 1.2 1.2 0 0 0-.38-.205 1.5 1.5 0 0 0-.463-.07 1.4 1.4 0 0 0-.787.224 1.43 1.43 0 0 0-.52.648q-.185.423-.185 1.028 0 .622.185 1.045.188.423.523.64.335.215.775.215.247 0 .457-.065.215-.065.378-.19.165-.128.273-.31.11-.182.154-.415l1.244.006a2.323 2.323 0 0 1-.756 1.435 2.4 2.4 0 0 1-.767.46q-.443.168-1.003.168-.778 0-1.392-.353a2.5 2.5 0 0 1-.966-1.02q-.352-.668-.352-1.616 0-.952.358-1.62.358-.667.972-1.017.614-.352 1.38-.352.506 0 .938.142.434.142.77.415.335.27.545.662.213.391.273.898"
|
|
186
|
+
}));
|
|
187
|
+
|
|
155
188
|
const SvgListItemPdf = ({
|
|
156
189
|
title,
|
|
157
190
|
titleId,
|
|
@@ -263,9 +296,11 @@ const FileItem = /*#__PURE__*/React__default["default"].memo(({
|
|
|
263
296
|
check,
|
|
264
297
|
radius,
|
|
265
298
|
status,
|
|
299
|
+
iconDoc,
|
|
266
300
|
iconPdf,
|
|
267
301
|
iconPng,
|
|
268
302
|
iconJpg,
|
|
303
|
+
iconDocx,
|
|
269
304
|
iconJpeg,
|
|
270
305
|
iconHeic,
|
|
271
306
|
iconWrong,
|
|
@@ -405,7 +440,7 @@ const FileItem = /*#__PURE__*/React__default["default"].memo(({
|
|
|
405
440
|
style: {
|
|
406
441
|
width: '32px'
|
|
407
442
|
}
|
|
408
|
-
}, fileFormat === 'pdf' ? iconPdf ? iconPdf : /*#__PURE__*/React__default["default"].createElement(SvgListItemPdf, null) : fileFormat === 'jpg' ? iconJpg ? iconJpg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpg, null) : fileFormat === 'png' ? iconPng ? iconPng : /*#__PURE__*/React__default["default"].createElement(SvgListItemPng, null) : fileFormat === 'jpeg' ? iconJpeg ? iconJpeg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpeg, null) : fileFormat === 'heic' || fileFormat === 'heif' ? iconHeic ? iconHeic : /*#__PURE__*/React__default["default"].createElement(SvgHeic, null) : ''), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
443
|
+
}, fileFormat === 'pdf' ? iconPdf ? iconPdf : /*#__PURE__*/React__default["default"].createElement(SvgListItemPdf, null) : fileFormat === 'jpg' ? iconJpg ? iconJpg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpg, null) : fileFormat === 'png' ? iconPng ? iconPng : /*#__PURE__*/React__default["default"].createElement(SvgListItemPng, null) : fileFormat === 'jpeg' ? iconJpeg ? iconJpeg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpeg, null) : fileFormat === 'heic' || fileFormat === 'heif' ? iconHeic ? iconHeic : /*#__PURE__*/React__default["default"].createElement(SvgHeic, null) : fileFormat === 'msword' ? iconDoc ? iconDoc : /*#__PURE__*/React__default["default"].createElement(SvgDocIcon, null) : fileFormat === 'vnd.openxmlformats-officedocument.wordprocessingml.document' ? iconDocx ? iconDocx : /*#__PURE__*/React__default["default"].createElement(SvgDocIcon, null) : ''), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
409
444
|
style: {
|
|
410
445
|
position: 'relative',
|
|
411
446
|
display: 'flex',
|
|
@@ -463,8 +498,13 @@ const FileItem = /*#__PURE__*/React__default["default"].memo(({
|
|
|
463
498
|
}, iconDelItem ? iconDelItem : /*#__PURE__*/React__default["default"].createElement(SvgListItemDelete, null))));
|
|
464
499
|
});
|
|
465
500
|
|
|
466
|
-
var img$
|
|
501
|
+
var img$4 = "data:image/svg+xml,%3csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cg clip-path='url(%23clip0_18850_5919)'%3e%3cpath d='M13.4695 11.9505L20.7595 4.66046C20.9234 4.46916 21.009 4.22308 20.9993 3.9714C20.9895 3.71973 20.8852 3.48099 20.7071 3.30289C20.529 3.1248 20.2903 3.02047 20.0386 3.01075C19.7869 3.00102 19.5408 3.08663 19.3495 3.25046L12.0595 10.5405L4.76954 3.24046C4.57824 3.07663 4.33217 2.99102 4.08049 3.00075C3.82881 3.01047 3.59008 3.1148 3.41198 3.29289C3.23389 3.47099 3.12955 3.70973 3.11983 3.9614C3.11011 4.21308 3.19572 4.45915 3.35954 4.65046L10.6495 11.9505L3.34954 19.2405C3.24486 19.3301 3.15984 19.4404 3.09982 19.5645C3.0398 19.6886 3.00606 19.8237 3.00075 19.9614C2.99543 20.0991 3.01863 20.2365 3.06891 20.3648C3.11918 20.4931 3.19544 20.6097 3.29289 20.7071C3.39035 20.8046 3.5069 20.8808 3.63522 20.9311C3.76355 20.9814 3.90088 21.0046 4.0386 20.9993C4.17632 20.9939 4.31145 20.9602 4.43551 20.9002C4.55958 20.8402 4.6699 20.7551 4.75954 20.6505L12.0595 13.3605L19.3495 20.6505C19.5408 20.8143 19.7869 20.8999 20.0386 20.8902C20.2903 20.8804 20.529 20.7761 20.7071 20.598C20.8852 20.4199 20.9895 20.1812 20.9993 19.9295C21.009 19.6778 20.9234 19.4318 20.7595 19.2405L13.4695 11.9505Z' fill='%231C212D'/%3e%3c/g%3e%3cdefs%3e%3cclipPath id='clip0_18850_5919'%3e%3crect width='24' height='24' fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e";
|
|
502
|
+
|
|
503
|
+
var img$3 = "data:image/svg+xml,%3csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M8 1V15M1 8H15' stroke='%23009B8B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e";
|
|
467
504
|
|
|
505
|
+
var img$2 = "data:image/svg+xml,%3csvg width='16' height='2' viewBox='0 0 16 2' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M1 1H15' stroke='%23009B8B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e";
|
|
506
|
+
|
|
507
|
+
// import React from 'react'
|
|
468
508
|
const boxSizing = 'border-box';
|
|
469
509
|
const fontStyle = 'normal';
|
|
470
510
|
const fontFamily = 'Arial';
|
|
@@ -546,6 +586,7 @@ var packageResult = {
|
|
|
546
586
|
className: '',
|
|
547
587
|
maxLength: 255,
|
|
548
588
|
iconWidth: '64px',
|
|
589
|
+
iconPadding: '10px',
|
|
549
590
|
autoComplete: 'off',
|
|
550
591
|
box: {
|
|
551
592
|
sizing: boxSizing,
|
|
@@ -579,6 +620,9 @@ var packageResult = {
|
|
|
579
620
|
marginTop: '10px',
|
|
580
621
|
iconMargin: '10px',
|
|
581
622
|
lineHeight: '19px',
|
|
623
|
+
box: {
|
|
624
|
+
shadow: '0 0 0 1px #F20918'
|
|
625
|
+
},
|
|
582
626
|
font: {
|
|
583
627
|
...fontObject
|
|
584
628
|
}
|
|
@@ -726,6 +770,7 @@ var packageResult = {
|
|
|
726
770
|
SELECT: {
|
|
727
771
|
dots: false,
|
|
728
772
|
className: '',
|
|
773
|
+
arrowNoRotate: false,
|
|
729
774
|
showCloseIcon: true,
|
|
730
775
|
// arrowIcon: React.createElement(SvgChecked, { fill: 'green' }),
|
|
731
776
|
// closeIcon: React.createElement(SvgChecked, { fill: 'green' }),
|
|
@@ -1102,8 +1147,14 @@ var packageResult = {
|
|
|
1102
1147
|
header: {
|
|
1103
1148
|
color: presetColors.primarySecond,
|
|
1104
1149
|
height: '30px',
|
|
1150
|
+
align: 'left',
|
|
1105
1151
|
font: {
|
|
1106
1152
|
...fontObject
|
|
1153
|
+
},
|
|
1154
|
+
icon: {
|
|
1155
|
+
maxWidth: '60px',
|
|
1156
|
+
maxHeight: '60px',
|
|
1157
|
+
marginRight: '20px'
|
|
1107
1158
|
}
|
|
1108
1159
|
},
|
|
1109
1160
|
image: {
|
|
@@ -1149,9 +1200,9 @@ var packageResult = {
|
|
|
1149
1200
|
border: {
|
|
1150
1201
|
radius: '10px'
|
|
1151
1202
|
},
|
|
1152
|
-
withParent: true,
|
|
1203
|
+
// withParent: true,
|
|
1153
1204
|
outSideClose: false,
|
|
1154
|
-
closeIcon: img$
|
|
1205
|
+
closeIcon: img$4
|
|
1155
1206
|
},
|
|
1156
1207
|
// default properties for <Checkbox /> component
|
|
1157
1208
|
CHECKBOX: {
|
|
@@ -1231,7 +1282,31 @@ var packageResult = {
|
|
|
1231
1282
|
},
|
|
1232
1283
|
// default properties for <Pagination /> component
|
|
1233
1284
|
PAGINATION: {
|
|
1234
|
-
|
|
1285
|
+
width: '34px',
|
|
1286
|
+
height: '34px',
|
|
1287
|
+
lineHeight: '16px',
|
|
1288
|
+
className: '',
|
|
1289
|
+
// for pagination class
|
|
1290
|
+
color: '#000000',
|
|
1291
|
+
font: {
|
|
1292
|
+
size: '13px',
|
|
1293
|
+
style: '',
|
|
1294
|
+
weight: '',
|
|
1295
|
+
family: ''
|
|
1296
|
+
},
|
|
1297
|
+
colors: {
|
|
1298
|
+
hover: '#000000',
|
|
1299
|
+
active: '#ffffff',
|
|
1300
|
+
background: '#ffffff',
|
|
1301
|
+
activeHover: '#ffffff',
|
|
1302
|
+
hoverBackground: '#dddddd',
|
|
1303
|
+
activeBackground: '#00236a'
|
|
1304
|
+
},
|
|
1305
|
+
border: {
|
|
1306
|
+
width: '1px',
|
|
1307
|
+
color: 'rgba(238,238,238, 1)',
|
|
1308
|
+
radius: '6px'
|
|
1309
|
+
}
|
|
1235
1310
|
},
|
|
1236
1311
|
// default properties for <Toaster /> component
|
|
1237
1312
|
TOASTER: {
|
|
@@ -1296,10 +1371,12 @@ var packageResult = {
|
|
|
1296
1371
|
width: '2px',
|
|
1297
1372
|
style: 'solid',
|
|
1298
1373
|
color: '#E7E7E7',
|
|
1374
|
+
hoverColor: '#E7E7E7',
|
|
1299
1375
|
activeColor: '#3C3D46'
|
|
1300
1376
|
},
|
|
1301
1377
|
label: {
|
|
1302
1378
|
color: '#3C3D46',
|
|
1379
|
+
activeColor: '#3C3D46',
|
|
1303
1380
|
lineHeight: '21px',
|
|
1304
1381
|
font: {
|
|
1305
1382
|
...fontObject
|
|
@@ -1309,6 +1386,39 @@ var packageResult = {
|
|
|
1309
1386
|
// default properties for <Form /> component
|
|
1310
1387
|
FORM: {
|
|
1311
1388
|
className: ''
|
|
1389
|
+
},
|
|
1390
|
+
// default properties for <Accordion /> component
|
|
1391
|
+
ACCORDION: {
|
|
1392
|
+
className: '',
|
|
1393
|
+
padding: '15px',
|
|
1394
|
+
color: '#121212',
|
|
1395
|
+
marginBottom: '0px',
|
|
1396
|
+
colors: {
|
|
1397
|
+
hover: '#009B8B',
|
|
1398
|
+
background: '#E5E7EA',
|
|
1399
|
+
backgroundHover: '#CBCED5'
|
|
1400
|
+
},
|
|
1401
|
+
border: {
|
|
1402
|
+
color: '#A8ADB9',
|
|
1403
|
+
width: '1px',
|
|
1404
|
+
style: 'solid',
|
|
1405
|
+
radius: '0px',
|
|
1406
|
+
top: false,
|
|
1407
|
+
left: false,
|
|
1408
|
+
right: false,
|
|
1409
|
+
bottom: true
|
|
1410
|
+
},
|
|
1411
|
+
font: {
|
|
1412
|
+
size: '14px',
|
|
1413
|
+
style: 'normal',
|
|
1414
|
+
weight: 700,
|
|
1415
|
+
family: 'Noto Sans Armenian'
|
|
1416
|
+
},
|
|
1417
|
+
icon: {
|
|
1418
|
+
open: img$3,
|
|
1419
|
+
close: img$2,
|
|
1420
|
+
openHover: img$3
|
|
1421
|
+
}
|
|
1312
1422
|
}
|
|
1313
1423
|
};
|
|
1314
1424
|
|
|
@@ -1644,8 +1754,10 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1644
1754
|
progressColor,
|
|
1645
1755
|
noChoosenFile,
|
|
1646
1756
|
iconPdf,
|
|
1757
|
+
iconDoc,
|
|
1647
1758
|
iconPng,
|
|
1648
1759
|
iconJpg,
|
|
1760
|
+
iconDocx,
|
|
1649
1761
|
iconJpeg,
|
|
1650
1762
|
iconHeic,
|
|
1651
1763
|
iconWrong,
|
|
@@ -1749,8 +1861,26 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1749
1861
|
for (let ix = 0; ix < file.length; ix++) {
|
|
1750
1862
|
if (file[ix]) {
|
|
1751
1863
|
if (file[ix].size <= maxSize * Math.pow(2, 20)) {
|
|
1752
|
-
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) {
|
|
1753
|
-
if (
|
|
1864
|
+
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif') || (fileExtensions.includes('doc') || fileExtensions.includes('docx')) && (file[ix].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || file[ix].type.split('/')[1] === 'msword')) {
|
|
1865
|
+
if (file[ix].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
1866
|
+
change({
|
|
1867
|
+
id: '',
|
|
1868
|
+
check: '',
|
|
1869
|
+
status: '',
|
|
1870
|
+
file: file[ix],
|
|
1871
|
+
uuid: v4()
|
|
1872
|
+
});
|
|
1873
|
+
setImage('docx');
|
|
1874
|
+
} else if (file[ix].type === 'application/msword') {
|
|
1875
|
+
change({
|
|
1876
|
+
id: '',
|
|
1877
|
+
check: '',
|
|
1878
|
+
status: '',
|
|
1879
|
+
file: file[ix],
|
|
1880
|
+
uuid: v4()
|
|
1881
|
+
});
|
|
1882
|
+
setImage('doc');
|
|
1883
|
+
} else if ((fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif'))) {
|
|
1754
1884
|
handleCheckHeicFormat(file[ix]).then(() => {
|
|
1755
1885
|
change({
|
|
1756
1886
|
id: '',
|
|
@@ -1797,8 +1927,26 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1797
1927
|
for (let ix = 0; ix < file.length; ix++) {
|
|
1798
1928
|
if (file[ix]) {
|
|
1799
1929
|
if (file[ix].size <= maxSize * Math.pow(2, 20)) {
|
|
1800
|
-
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) {
|
|
1801
|
-
if (
|
|
1930
|
+
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif') || (fileExtensions.includes('doc') || fileExtensions.includes('docx')) && (file[ix].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || file[ix].type.split('/')[1] === 'msword')) {
|
|
1931
|
+
if (file[ix].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
1932
|
+
change({
|
|
1933
|
+
id: '',
|
|
1934
|
+
check: '',
|
|
1935
|
+
status: '',
|
|
1936
|
+
file: file[ix],
|
|
1937
|
+
uuid: v4()
|
|
1938
|
+
});
|
|
1939
|
+
setImage('docx');
|
|
1940
|
+
} else if (file[ix].type === 'application/msword') {
|
|
1941
|
+
change({
|
|
1942
|
+
id: '',
|
|
1943
|
+
check: '',
|
|
1944
|
+
status: '',
|
|
1945
|
+
file: file[ix],
|
|
1946
|
+
uuid: v4()
|
|
1947
|
+
});
|
|
1948
|
+
setImage('doc');
|
|
1949
|
+
} else if ((fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif'))) {
|
|
1802
1950
|
handleCheckHeicFormat(file[ix]).then(() => {
|
|
1803
1951
|
change({
|
|
1804
1952
|
id: '',
|
|
@@ -1854,9 +2002,17 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1854
2002
|
} else {
|
|
1855
2003
|
if (file[0]) {
|
|
1856
2004
|
if (file[0].size <= maxSize * Math.pow(2, 20)) {
|
|
1857
|
-
if (fileExtensions.includes(file[0].type.split('/')[1]) || (fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[0].type === 'image/heif' || file[0].type === 'image/heic' || file[0].name.toLowerCase().endsWith('.heic') || file[0].name.toLowerCase().endsWith('.heif'))) {
|
|
2005
|
+
if (fileExtensions.includes(file[0].type.split('/')[1]) || (fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[0].type === 'image/heif' || file[0].type === 'image/heic' || file[0].name.toLowerCase().endsWith('.heic') || file[0].name.toLowerCase().endsWith('.heif')) || (fileExtensions.includes('doc') || fileExtensions.includes('docx')) && (file[0].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || file[0].type.split('/')[1] === 'msword')) {
|
|
1858
2006
|
setError('');
|
|
1859
|
-
if (file[0].type === 'application/
|
|
2007
|
+
if (file[0].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
2008
|
+
setImage('docx');
|
|
2009
|
+
change(file);
|
|
2010
|
+
setSingleFile(file);
|
|
2011
|
+
} else if (file[0].type === 'application/msword') {
|
|
2012
|
+
setImage('doc');
|
|
2013
|
+
change(file);
|
|
2014
|
+
setSingleFile(file);
|
|
2015
|
+
} else if (file[0].type === 'application/pdf') {
|
|
1860
2016
|
setImage('pdf');
|
|
1861
2017
|
change(file);
|
|
1862
2018
|
setSingleFile(file);
|
|
@@ -1871,6 +2027,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1871
2027
|
});
|
|
1872
2028
|
} else {
|
|
1873
2029
|
change(file);
|
|
2030
|
+
setSingleFile(file);
|
|
1874
2031
|
setImage(URL.createObjectURL(file[0]));
|
|
1875
2032
|
}
|
|
1876
2033
|
} else {
|
|
@@ -1891,8 +2048,12 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1891
2048
|
const handleClick = () => {
|
|
1892
2049
|
inpRef.current.files = null;
|
|
1893
2050
|
inpRef.current.value = null;
|
|
1894
|
-
if (
|
|
2051
|
+
if (multiple) {
|
|
1895
2052
|
inpRef.current.click();
|
|
2053
|
+
} else {
|
|
2054
|
+
if (!image) {
|
|
2055
|
+
inpRef.current.click();
|
|
2056
|
+
}
|
|
1896
2057
|
}
|
|
1897
2058
|
};
|
|
1898
2059
|
const handleDrop = e => {
|
|
@@ -2056,7 +2217,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2056
2217
|
fontFamily: family ?? configStyles.FILE.font.family,
|
|
2057
2218
|
fontWeight: weight ?? configStyles.FILE.font.weight
|
|
2058
2219
|
}
|
|
2059
|
-
}, !multiple && image && preview ? image === 'pdf' ? iconPdf ? iconPdf : configStyles.FILE.icon.pdf ? configStyles.FILE.icon.pdf : /*#__PURE__*/React__default["default"].createElement(SvgPdf, null) : image === 'heif' || image === 'heic' ? iconHeic ? iconHeic : configStyles.FILE.icon.heic ? configStyles.FILE.icon.heic : /*#__PURE__*/React__default["default"].createElement(SvgHeic, null) : /*#__PURE__*/React__default["default"].createElement("img", {
|
|
2220
|
+
}, !multiple && image && preview ? image === 'pdf' ? iconPdf ? iconPdf : configStyles.FILE.icon.pdf ? configStyles.FILE.icon.pdf : /*#__PURE__*/React__default["default"].createElement(SvgPdf, null) : image === 'heif' || image === 'heic' ? iconHeic ? iconHeic : configStyles.FILE.icon.heic ? configStyles.FILE.icon.heic : /*#__PURE__*/React__default["default"].createElement(SvgHeic, null) : image === 'doc' ? iconDoc ? iconDoc : configStyles.FILE.icon.doc ? configStyles.FILE.icon.doc : /*#__PURE__*/React__default["default"].createElement(SvgDocIcon, null) : image === 'docx' ? iconDocx ? iconDocx : configStyles.FILE.icon.docx ? configStyles.FILE.icon.docx : /*#__PURE__*/React__default["default"].createElement(SvgDocIcon, null) : /*#__PURE__*/React__default["default"].createElement("img", {
|
|
2060
2221
|
src: image,
|
|
2061
2222
|
style: {
|
|
2062
2223
|
display: 'block',
|
|
@@ -2081,7 +2242,8 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2081
2242
|
}
|
|
2082
2243
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
2083
2244
|
style: {
|
|
2084
|
-
margin: '0px'
|
|
2245
|
+
margin: '0px',
|
|
2246
|
+
padding: '0px 10px'
|
|
2085
2247
|
}
|
|
2086
2248
|
}, fileSizeText ?? configStyles.FILE.sizeText, " ", maxSize, " \u0544\u0532 (", ' ', fileExtensions.toString().split(',').join(', '), " )"))) : /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2087
2249
|
style: {
|
|
@@ -2113,7 +2275,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2113
2275
|
whiteSpace: 'nowrap',
|
|
2114
2276
|
textOverflow: 'ellipsis'
|
|
2115
2277
|
}
|
|
2116
|
-
}, singleFile ? singleFile[0].name : /*#__PURE__*/React__default["default"].createElement("span", null, fileSizeText ?? configStyles.FILE.sizeText, " ", maxSize, " \u0544\u0532 (", ' ', fileExtensions.toString().split(',').join(', '), " )"))))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2278
|
+
}, singleFile && singleFile[`${0}`] ? singleFile[`${0}`].name : /*#__PURE__*/React__default["default"].createElement("span", null, fileSizeText ?? configStyles.FILE.sizeText, " ", maxSize, " \u0544\u0532 (", ' ', fileExtensions.toString().split(',').join(', '), " )"))))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2117
2279
|
style: {
|
|
2118
2280
|
position: 'absolute',
|
|
2119
2281
|
top: '0px',
|
|
@@ -2152,11 +2314,13 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2152
2314
|
uuid: item.uuid,
|
|
2153
2315
|
check: item.check,
|
|
2154
2316
|
status: item.status,
|
|
2155
|
-
size: item
|
|
2156
|
-
name: item
|
|
2317
|
+
size: item?.file?.size,
|
|
2318
|
+
name: item?.file?.name,
|
|
2157
2319
|
iconPdf: iconPdf ?? configStyles.FILE.icon.pdf,
|
|
2320
|
+
iconDoc: iconDoc ?? configStyles.FILE.icon.doc,
|
|
2158
2321
|
iconPng: iconPng ?? configStyles.FILE.icon.png,
|
|
2159
2322
|
iconJpg: iconJpg ?? configStyles.FILE.icon.jpg,
|
|
2323
|
+
iconDocx: iconDocx ?? configStyles.FILE.icon.docx,
|
|
2160
2324
|
iconJpeg: iconJpeg ?? configStyles.FILE.icon.jpeg,
|
|
2161
2325
|
iconHeic: iconHeic ?? configStyles.FILE.icon.heic,
|
|
2162
2326
|
iconWrong: iconWrong ?? configStyles.FILE.icon.wrong,
|
|
@@ -2164,7 +2328,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2164
2328
|
timeForRemoveError: timeForRemoveError,
|
|
2165
2329
|
removeFile: removeFile ? removeFile : _ => _,
|
|
2166
2330
|
radius: radius ?? configStyles.FILE.radius,
|
|
2167
|
-
fileFormat: item
|
|
2331
|
+
fileFormat: item?.file?.type.split('/')[1]?.toLowerCase(),
|
|
2168
2332
|
progressColor: progressColor ?? configStyles.FILE.progress.color,
|
|
2169
2333
|
listItemHeight: listItemHeight ?? configStyles.FILE.listItem.height,
|
|
2170
2334
|
listItemPadding: listItemPadding ?? configStyles.FILE.listItem.padding,
|
|
@@ -2230,8 +2394,10 @@ File.propTypes = {
|
|
|
2230
2394
|
deleteComponent: PropTypes__default["default"].bool,
|
|
2231
2395
|
removeComponent: PropTypes__default["default"].func,
|
|
2232
2396
|
iconPdf: PropTypes__default["default"].element,
|
|
2397
|
+
iconDoc: PropTypes__default["default"].element,
|
|
2233
2398
|
iconPng: PropTypes__default["default"].element,
|
|
2234
2399
|
iconJpg: PropTypes__default["default"].element,
|
|
2400
|
+
iconDocx: PropTypes__default["default"].element,
|
|
2235
2401
|
iconJpeg: PropTypes__default["default"].element,
|
|
2236
2402
|
iconHeic: PropTypes__default["default"].element,
|
|
2237
2403
|
iconWrong: PropTypes__default["default"].element,
|
|
@@ -2479,15 +2645,21 @@ const handleUtilsCheckTypeTel = (val, prevVal) => {
|
|
|
2479
2645
|
}
|
|
2480
2646
|
return val;
|
|
2481
2647
|
};
|
|
2482
|
-
const handleUtilsCheckTypeNumber = (val, prevVal, maxLength, floatToFix, maxNumSize, withoutDot, innerMinNumSize, numberMaxLength) => {
|
|
2648
|
+
const handleUtilsCheckTypeNumber = (val, prevVal, maxLength, floatToFix, maxNumSize, withoutDot, innerMinNumSize, numberMaxLength, cardNumber) => {
|
|
2483
2649
|
if (maxLength && maxLength > 0) {
|
|
2484
2650
|
if (val.length > maxLength) {
|
|
2485
2651
|
val = val.substr(0, maxLength);
|
|
2486
2652
|
}
|
|
2487
2653
|
} else {
|
|
2488
2654
|
const regNum = floatToFix && floatToFix >= 0 ? /^\d+(\.|\․|\.|\,)?(\d+)?$/ : /^\d+$/;
|
|
2489
|
-
if (
|
|
2490
|
-
val
|
|
2655
|
+
if (cardNumber) {
|
|
2656
|
+
if (val.length > 19 && !val.includes('.')) {
|
|
2657
|
+
val = val.substr(0, 19);
|
|
2658
|
+
}
|
|
2659
|
+
} else {
|
|
2660
|
+
if (val.length > 16 && !val.includes('.')) {
|
|
2661
|
+
val = val.substr(0, 16);
|
|
2662
|
+
}
|
|
2491
2663
|
}
|
|
2492
2664
|
if (numberMaxLength && numberMaxLength > 0 && !val.includes('.')) {
|
|
2493
2665
|
val = val.substr(0, numberMaxLength);
|
|
@@ -2563,9 +2735,9 @@ function styleInject(css, ref) {
|
|
|
2563
2735
|
}
|
|
2564
2736
|
}
|
|
2565
2737
|
|
|
2566
|
-
var css_248z$
|
|
2567
|
-
var styles$a = {"sorting-arrows":"table-module_sorting-arrows__BaN-G","td-span":"table-module_td-span__XHo6k","list-text":"table-module_list-text__kmKIq","dots-option-item":"table-module_dots-option-item__jNOxO"};
|
|
2568
|
-
styleInject(css_248z$
|
|
2738
|
+
var css_248z$c = ".table-module_sorting-arrows__BaN-G:after{content:\"▲\";font-size:11px;position:absolute;right:0;top:calc(50% - 12px)}.table-module_sorting-arrows__BaN-G:before{bottom:calc(50% - 12px);content:\"▼\";font-size:11px;position:absolute;right:0}.table-module_td-span__XHo6k{display:inline-block;position:relative}.table-module_td-span__XHo6k>svg{left:0;position:absolute;top:0;z-index:-1}.table-module_list-text__kmKIq{align-items:center;cursor:pointer;display:flex;margin:0 0 8px;min-height:38px;white-space:wrap}.table-module_dots-option-item__jNOxO{box-sizing:border-box;cursor:pointer;display:flex;height:39px;margin-bottom:2px;padding:10px;position:relative;width:100%}.table-module_dots-option-item__jNOxO:after{background-color:#eee;border-radius:1px;-webkit-border-radius:1px;-moz-border-radius:1px;-ms-border-radius:1px;-o-border-radius:1px;content:\"\";height:2px;left:10px;position:absolute;top:calc(100% - 2px);width:calc(100% - 20px)}.table-module_dots-option-item__jNOxO:last-child:after{display:none}.table-module_no-tabel-data__6xp3N{align-items:center;display:flex;height:200px;justify-content:center;width:100%}";
|
|
2739
|
+
var styles$a = {"sorting-arrows":"table-module_sorting-arrows__BaN-G","td-span":"table-module_td-span__XHo6k","list-text":"table-module_list-text__kmKIq","dots-option-item":"table-module_dots-option-item__jNOxO","no-tabel-data":"table-module_no-tabel-data__6xp3N"};
|
|
2740
|
+
styleInject(css_248z$c);
|
|
2569
2741
|
|
|
2570
2742
|
/* eslint-disable no-prototype-builtins */
|
|
2571
2743
|
const TH = ({
|
|
@@ -2623,7 +2795,8 @@ const TH = ({
|
|
|
2623
2795
|
unCheckedColor: item.checkBox.unCheckedColor ? item.checkBox.unCheckedColor : ''
|
|
2624
2796
|
}) : '', /*#__PURE__*/React__default["default"].createElement("p", {
|
|
2625
2797
|
style: {
|
|
2626
|
-
margin: '0px'
|
|
2798
|
+
margin: '0px',
|
|
2799
|
+
whiteSpace: 'nowrap'
|
|
2627
2800
|
},
|
|
2628
2801
|
onClick: e => handleCheckArrowAction(e, item, 'arrowComponent')
|
|
2629
2802
|
}, item.type === 'show' ? item.content : hasOwnerProperty(item, 'arrowComponent') ? item.status === 'close' ? item.closeArrow : item.openArrow : '')));
|
|
@@ -3048,7 +3221,7 @@ const Table = ({
|
|
|
3048
3221
|
const [header, setHeader] = React.useState([]);
|
|
3049
3222
|
const [disableArr, setDisableArr] = React.useState([]);
|
|
3050
3223
|
const [classProps, setClassProps] = React.useState({});
|
|
3051
|
-
const [checkDrag, setCheckDrag] = React.useState(
|
|
3224
|
+
const [checkDrag, setCheckDrag] = React.useState(null);
|
|
3052
3225
|
const [checkedArray, setCheckedArray] = React.useState([]);
|
|
3053
3226
|
const [configStyles, setConfigStyles] = React.useState({});
|
|
3054
3227
|
const [dragging, setDragging] = React.useState(false);
|
|
@@ -3527,19 +3700,21 @@ const Table = ({
|
|
|
3527
3700
|
});
|
|
3528
3701
|
};
|
|
3529
3702
|
React.useEffect(() => {
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3703
|
+
if (checkDrag != null) {
|
|
3704
|
+
const draggableArray = body && body.length > 0 ? body.map((item, index) => {
|
|
3705
|
+
if (showOrder) {
|
|
3706
|
+
Object.values(item).map((innerItem, innerIndex) => {
|
|
3707
|
+
if (innerIndex === 1) {
|
|
3708
|
+
innerItem.content = index + 1, innerItem.draggable = true;
|
|
3709
|
+
}
|
|
3710
|
+
return innerItem;
|
|
3711
|
+
});
|
|
3712
|
+
}
|
|
3713
|
+
return item;
|
|
3714
|
+
}) : [];
|
|
3715
|
+
getDraggableData && getDraggableData(draggableArray);
|
|
3716
|
+
setBody(() => draggableArray);
|
|
3717
|
+
}
|
|
3543
3718
|
}, [checkDrag]);
|
|
3544
3719
|
React.useEffect(() => {
|
|
3545
3720
|
const isEqual = handleSafeStringify(body) === handleSafeStringify(dataBody);
|
|
@@ -3548,7 +3723,7 @@ const Table = ({
|
|
|
3548
3723
|
let newArray = [];
|
|
3549
3724
|
let checkedItems = [];
|
|
3550
3725
|
const disabledArray = [];
|
|
3551
|
-
const checkBodyForChackedItems = dataBody.slice().map(item => Object.values(item));
|
|
3726
|
+
const checkBodyForChackedItems = dataBody && dataBody.length > 0 ? dataBody.slice().map(item => Object.values(item)) : [];
|
|
3552
3727
|
if (arrowShow) {
|
|
3553
3728
|
let column = arrowColumn;
|
|
3554
3729
|
if (draggable) {
|
|
@@ -3576,7 +3751,7 @@ const Table = ({
|
|
|
3576
3751
|
newArray = insert;
|
|
3577
3752
|
checkedItems = handleSetCheckboxArray(insert);
|
|
3578
3753
|
} else {
|
|
3579
|
-
insert = checkBodyForChackedItems.map((item, index) => {
|
|
3754
|
+
insert = checkBodyForChackedItems && checkBodyForChackedItems.length > 0 ? checkBodyForChackedItems.map((item, index) => {
|
|
3580
3755
|
item.map((innerItem, innerIndex) => {
|
|
3581
3756
|
if (hasOwnerProperty(innerItem, 'checkBox')) {
|
|
3582
3757
|
if (hasOwnerProperty(innerItem.checkBox, 'disabled')) {
|
|
@@ -3592,12 +3767,12 @@ const Table = ({
|
|
|
3592
3767
|
}
|
|
3593
3768
|
});
|
|
3594
3769
|
return item;
|
|
3595
|
-
});
|
|
3770
|
+
}) : [];
|
|
3596
3771
|
newArray = insert;
|
|
3597
3772
|
checkedItems = handleSetCheckboxArray(insert);
|
|
3598
3773
|
}
|
|
3599
|
-
if (draggable) {
|
|
3600
|
-
newArray = insert && insert.length
|
|
3774
|
+
if (draggable && dataBody && dataBody.length > 0) {
|
|
3775
|
+
newArray = insert && insert.length > 0 ? insert.map((item, index) => {
|
|
3601
3776
|
item.map(innerItem => {
|
|
3602
3777
|
if (hasOwnerProperty(innerItem, 'colorStatus')) {
|
|
3603
3778
|
innerItem.colorStatus = null;
|
|
@@ -3614,12 +3789,11 @@ const Table = ({
|
|
|
3614
3789
|
colorStatus: draggableColor
|
|
3615
3790
|
});
|
|
3616
3791
|
return item;
|
|
3617
|
-
});
|
|
3792
|
+
}) : [];
|
|
3618
3793
|
}
|
|
3619
3794
|
setBody(() => [...newArray]);
|
|
3620
3795
|
setDisableArr(disabledArray);
|
|
3621
3796
|
setCheckedArray(() => checkedItems);
|
|
3622
|
-
getDraggableData && getDraggableData(newArray);
|
|
3623
3797
|
}
|
|
3624
3798
|
}, [dataBody, arrowColumn, arrowShow, draggable]);
|
|
3625
3799
|
React.useEffect(() => {
|
|
@@ -3666,7 +3840,7 @@ const Table = ({
|
|
|
3666
3840
|
console.error(error);
|
|
3667
3841
|
});
|
|
3668
3842
|
}, []);
|
|
3669
|
-
return configStyles.TABLE && /*#__PURE__*/React__default["default"].createElement("table", {
|
|
3843
|
+
return configStyles.TABLE && /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("table", {
|
|
3670
3844
|
style: {
|
|
3671
3845
|
width: '100%',
|
|
3672
3846
|
borderCollapse: tableRowItem ?? configStyles.TABLE.body.row.asItem ? 'separate' : 'collapse',
|
|
@@ -3701,7 +3875,7 @@ const Table = ({
|
|
|
3701
3875
|
tableColumnMinWidth: tableColumnMinWidth ?? configStyles.TABLE.column.minWidth,
|
|
3702
3876
|
tableColumnMaxWidth: tableColumnMaxWidth ?? configStyles.TABLE.column.maxWidth
|
|
3703
3877
|
});
|
|
3704
|
-
}))), body && body.length > 0
|
|
3878
|
+
}))), body && body.length > 0 ? /*#__PURE__*/React__default["default"].createElement("tbody", {
|
|
3705
3879
|
style: {
|
|
3706
3880
|
boxShadow: tBodyBoxShadow ?? configStyles.TABLE.body.box.shadow
|
|
3707
3881
|
}
|
|
@@ -3713,7 +3887,7 @@ const Table = ({
|
|
|
3713
3887
|
style: {
|
|
3714
3888
|
backgroundColor: tableRowBGColor ?? configStyles.TABLE.body.row.colors.background,
|
|
3715
3889
|
borderBottom: index === body.length - 1 ? 'none' : tBodyRowBorder ? tBodyRowBorder : configStyles.TABLE.body.row.border,
|
|
3716
|
-
borderColor: hideBorder ? 'transparent' : configStyles.TABLE.body.row.borderColor,
|
|
3890
|
+
borderColor: hideBorder || index === body.length - 1 ? 'transparent' : configStyles.TABLE.body.row.borderColor,
|
|
3717
3891
|
boxShadow: (tableRowItem ? tableRowItem : configStyles.TABLE.body.row.asItem) ? tableRowBoxShadow ? tableRowBoxShadow : configStyles.TABLE.body.row.box.shadow : 'none'
|
|
3718
3892
|
},
|
|
3719
3893
|
ref: el => setRef(index, el)
|
|
@@ -3760,7 +3934,7 @@ const Table = ({
|
|
|
3760
3934
|
handleOpenCloseRowSingleArrow: handleOpenCloseRowSingleArrow
|
|
3761
3935
|
});
|
|
3762
3936
|
}));
|
|
3763
|
-
})), draggable && dragging && draggedItem && /*#__PURE__*/React__default["default"].createElement("
|
|
3937
|
+
})) : '', body && body.length > 0 && draggable && dragging && draggedItem && /*#__PURE__*/React__default["default"].createElement("tbody", null, /*#__PURE__*/React__default["default"].createElement("tr", {
|
|
3764
3938
|
style: {
|
|
3765
3939
|
position: 'fixed',
|
|
3766
3940
|
top: `${position.y - 30}px`,
|
|
@@ -3806,7 +3980,9 @@ const Table = ({
|
|
|
3806
3980
|
borderRight: innerIndex === Object.values(draggedItem).length - 1 ? 'none' : configStyles.TABLE.body.row.border,
|
|
3807
3981
|
borderRightColor: innerIndex === Object.values(draggedItem).length - 1 ? 'transparent' : configStyles.TABLE.body.row.borderColor
|
|
3808
3982
|
});
|
|
3809
|
-
})))
|
|
3983
|
+
})))), !body.length && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3984
|
+
className: styles$a['no-tabel-data']
|
|
3985
|
+
}, /*#__PURE__*/React__default["default"].createElement("p", null, "\u054F\u057E\u0575\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576")));
|
|
3810
3986
|
};
|
|
3811
3987
|
Table.propTypes = {
|
|
3812
3988
|
getData: PropTypes__default["default"].func,
|
|
@@ -3850,9 +4026,9 @@ Table.propTypes = {
|
|
|
3850
4026
|
hideBorder: PropTypes__default["default"].bool
|
|
3851
4027
|
};
|
|
3852
4028
|
|
|
3853
|
-
var css_248z$
|
|
4029
|
+
var css_248z$b = ".modal-module_animation__modal__3mt48{animation:modal-module_show-popup__WrH7a .15s;-webkit-animation:modal-module_show-popup__WrH7a .15s}@keyframes modal-module_show-popup__WrH7a{0%{transform:translate3d(0,-50%,0);-webkit-transform:translate3d(0,-50%,0);-moz-transform:translate3d(0,-50%,0);-ms-transform:translate3d(0,-50%,0);-o-transform:translate3d(0,-50%,0)}to{opacity:1;transform:translateZ(0);-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0)}}";
|
|
3854
4030
|
var styles$9 = {"animation__modal":"modal-module_animation__modal__3mt48","show-popup":"modal-module_show-popup__WrH7a"};
|
|
3855
|
-
styleInject(css_248z$
|
|
4031
|
+
styleInject(css_248z$b);
|
|
3856
4032
|
|
|
3857
4033
|
const SvgNext = ({
|
|
3858
4034
|
title,
|
|
@@ -3972,6 +4148,7 @@ const Modal = ({
|
|
|
3972
4148
|
prevIcon,
|
|
3973
4149
|
nextIcon,
|
|
3974
4150
|
closeIcon,
|
|
4151
|
+
showCloseIcon,
|
|
3975
4152
|
closeSlideIcon,
|
|
3976
4153
|
selected,
|
|
3977
4154
|
children,
|
|
@@ -3984,6 +4161,7 @@ const Modal = ({
|
|
|
3984
4161
|
headerText,
|
|
3985
4162
|
imageWidth,
|
|
3986
4163
|
headerSize,
|
|
4164
|
+
headerIcon,
|
|
3987
4165
|
headerStyle,
|
|
3988
4166
|
headerFamily,
|
|
3989
4167
|
imageHeight,
|
|
@@ -3997,10 +4175,14 @@ const Modal = ({
|
|
|
3997
4175
|
headerWeight,
|
|
3998
4176
|
headerHeight,
|
|
3999
4177
|
justifyContent,
|
|
4178
|
+
headerTextAlign,
|
|
4000
4179
|
backgroundColor,
|
|
4001
4180
|
imageWrapHeight,
|
|
4002
4181
|
grayDecorHeight,
|
|
4182
|
+
headerIconMaxWidth,
|
|
4183
|
+
headerIconMaxHeight,
|
|
4003
4184
|
layerBackgroundColor,
|
|
4185
|
+
headerIconMarginRight,
|
|
4004
4186
|
closeAreaBackgroundColor,
|
|
4005
4187
|
type = 'content'
|
|
4006
4188
|
}) => {
|
|
@@ -4012,7 +4194,15 @@ const Modal = ({
|
|
|
4012
4194
|
const [classProps, setClassProps] = React.useState({});
|
|
4013
4195
|
const [configStyles, setConfigStyles] = React.useState({});
|
|
4014
4196
|
const handleCloseModal = () => {
|
|
4015
|
-
|
|
4197
|
+
if (outsideClose !== undefined) {
|
|
4198
|
+
if (outsideClose) {
|
|
4199
|
+
setShow(false);
|
|
4200
|
+
}
|
|
4201
|
+
} else {
|
|
4202
|
+
if (configStyles.MODAL.outsideClose) {
|
|
4203
|
+
setShow(false);
|
|
4204
|
+
}
|
|
4205
|
+
}
|
|
4016
4206
|
};
|
|
4017
4207
|
const handleStopClosing = e => {
|
|
4018
4208
|
e.stopPropagation();
|
|
@@ -4107,7 +4297,7 @@ const Modal = ({
|
|
|
4107
4297
|
}, []);
|
|
4108
4298
|
return configStyles.MODAL && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4109
4299
|
className: classProps,
|
|
4110
|
-
onClick:
|
|
4300
|
+
onClick: handleCloseModal,
|
|
4111
4301
|
style: {
|
|
4112
4302
|
top: '0px',
|
|
4113
4303
|
left: '0px',
|
|
@@ -4156,7 +4346,18 @@ const Modal = ({
|
|
|
4156
4346
|
justifyContent: headerText && type === 'content' ? 'space-between' : 'flex-end',
|
|
4157
4347
|
backgroundColor: closeAreaBackgroundColor ?? configStyles.MODAL.closeAreaBackgroundColor
|
|
4158
4348
|
}
|
|
4159
|
-
},
|
|
4349
|
+
}, headerIcon && type === 'content' && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4350
|
+
style: {
|
|
4351
|
+
display: 'flex',
|
|
4352
|
+
width: 'fit-content',
|
|
4353
|
+
alignItems: 'center',
|
|
4354
|
+
height: 'fit-content',
|
|
4355
|
+
justifyContent: 'center',
|
|
4356
|
+
maxWidth: headerIconMaxWidth ?? configStyles.MODAL.header.icon.maxWidth,
|
|
4357
|
+
maxHeight: headerIconMaxHeight ?? configStyles.MODAL.header.icon.maxHeight,
|
|
4358
|
+
marginRight: headerIconMarginRight ?? configStyles.MODAL.header.icon.marginRight
|
|
4359
|
+
}
|
|
4360
|
+
}, headerIcon), headerText && type === 'content' && /*#__PURE__*/React__default["default"].createElement("p", {
|
|
4160
4361
|
style: {
|
|
4161
4362
|
flex: '1',
|
|
4162
4363
|
overflow: 'hidden',
|
|
@@ -4165,18 +4366,25 @@ const Modal = ({
|
|
|
4165
4366
|
margin: '0px 16px 0px 0px',
|
|
4166
4367
|
color: headerColor ?? configStyles.MODAL.header.color,
|
|
4167
4368
|
fontSize: headerSize ?? configStyles.MODAL.header.font.size,
|
|
4369
|
+
textAlign: headerTextAlign ?? configStyles.MODAL.header.align,
|
|
4168
4370
|
fontStyle: headerStyle ?? configStyles.MODAL.header.font.style,
|
|
4169
4371
|
fontFamily: headerFamily ?? configStyles.MODAL.header.font.family,
|
|
4170
4372
|
fontWeight: headerWeight ?? configStyles.MODAL.header.font.weight
|
|
4171
4373
|
}
|
|
4172
|
-
}, headerText), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4173
|
-
onClick:
|
|
4374
|
+
}, headerText), showCloseIcon ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4375
|
+
onClick: () => setShow(false),
|
|
4174
4376
|
style: {
|
|
4175
|
-
|
|
4176
|
-
|
|
4177
|
-
|
|
4377
|
+
display: 'flex',
|
|
4378
|
+
minWidth: '14px',
|
|
4379
|
+
minHeight: '14px',
|
|
4380
|
+
cursor: 'pointer',
|
|
4381
|
+
width: 'fit-content',
|
|
4382
|
+
alignItems: 'center',
|
|
4383
|
+
alignSelf: 'flex-end',
|
|
4384
|
+
height: 'fit-content',
|
|
4385
|
+
justifyContent: 'center'
|
|
4178
4386
|
}
|
|
4179
|
-
}, closeIcon ? closeIcon : configStyles.MODAL.icon.close ? configStyles.MODAL.icon.close : /*#__PURE__*/React__default["default"].createElement(SvgCloseIcon, null))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4387
|
+
}, closeIcon ? closeIcon : configStyles.MODAL.icon.close ? configStyles.MODAL.icon.close : /*#__PURE__*/React__default["default"].createElement(SvgCloseIcon, null)) : ''), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4180
4388
|
style: {
|
|
4181
4389
|
display: 'flex',
|
|
4182
4390
|
width: '100%',
|
|
@@ -4219,7 +4427,7 @@ const Modal = ({
|
|
|
4219
4427
|
background: closeAreaBackgroundColor ?? configStyles.MODAL.closeAreaBackgroundColor
|
|
4220
4428
|
}
|
|
4221
4429
|
}, /*#__PURE__*/React__default["default"].createElement("button", {
|
|
4222
|
-
onClick:
|
|
4430
|
+
onClick: () => setShow(false),
|
|
4223
4431
|
style: {
|
|
4224
4432
|
position: 'absolute',
|
|
4225
4433
|
zIndex: '1',
|
|
@@ -4324,14 +4532,20 @@ Modal.propTypes = {
|
|
|
4324
4532
|
prevIcon: PropTypes__default["default"].element,
|
|
4325
4533
|
nextIcon: PropTypes__default["default"].element,
|
|
4326
4534
|
closeIcon: PropTypes__default["default"].element,
|
|
4535
|
+
showCloseIcon: PropTypes__default["default"].bool,
|
|
4327
4536
|
closeSlideIcon: PropTypes__default["default"].element,
|
|
4328
|
-
alignItems: PropTypes__default["default"].string,
|
|
4329
|
-
mMaxHeight: PropTypes__default["default"].string,
|
|
4330
4537
|
headerText: PropTypes__default["default"].string,
|
|
4331
|
-
imageWidth: PropTypes__default["default"].string,
|
|
4332
4538
|
headerSize: PropTypes__default["default"].string,
|
|
4333
4539
|
headerStyle: PropTypes__default["default"].string,
|
|
4540
|
+
headerIcon: PropTypes__default["default"].element,
|
|
4334
4541
|
headerFamily: PropTypes__default["default"].string,
|
|
4542
|
+
headerTextAlign: PropTypes__default["default"].string,
|
|
4543
|
+
headerIconMaxWidth: PropTypes__default["default"].string,
|
|
4544
|
+
headerIconMaxHeight: PropTypes__default["default"].string,
|
|
4545
|
+
headerIconMarginRight: PropTypes__default["default"].string,
|
|
4546
|
+
alignItems: PropTypes__default["default"].string,
|
|
4547
|
+
mMaxHeight: PropTypes__default["default"].string,
|
|
4548
|
+
imageWidth: PropTypes__default["default"].string,
|
|
4335
4549
|
outsideClose: PropTypes__default["default"].bool,
|
|
4336
4550
|
showZoomIcon: PropTypes__default["default"].bool,
|
|
4337
4551
|
imageMargin: PropTypes__default["default"].string,
|
|
@@ -4410,19 +4624,23 @@ const TelInput = ({
|
|
|
4410
4624
|
...inpStyles,
|
|
4411
4625
|
border: 'none',
|
|
4412
4626
|
outline: 'none',
|
|
4413
|
-
|
|
4627
|
+
borderTopRightRadius: radius,
|
|
4628
|
+
borderBottomRightRadius: radius
|
|
4414
4629
|
}
|
|
4415
4630
|
}));
|
|
4416
4631
|
};
|
|
4417
4632
|
|
|
4418
4633
|
const TextInput = ({
|
|
4634
|
+
ssn,
|
|
4419
4635
|
value,
|
|
4420
4636
|
radius,
|
|
4421
|
-
|
|
4637
|
+
disabled,
|
|
4422
4638
|
maxLength,
|
|
4423
4639
|
inpStyles,
|
|
4424
|
-
|
|
4425
|
-
inpAttributes
|
|
4640
|
+
inputChange,
|
|
4641
|
+
inpAttributes,
|
|
4642
|
+
checkLeftIcon,
|
|
4643
|
+
checkRightIcon
|
|
4426
4644
|
}) => {
|
|
4427
4645
|
const [innerValue, setInnerValue] = React.useState('');
|
|
4428
4646
|
const handleChange = event => {
|
|
@@ -4431,9 +4649,9 @@ const TextInput = ({
|
|
|
4431
4649
|
if (maxLength && currentValue.length > maxLength) {
|
|
4432
4650
|
currentValue = currentValue.substr(0, maxLength);
|
|
4433
4651
|
}
|
|
4434
|
-
setInnerValue(() => currentValue);
|
|
4652
|
+
setInnerValue(() => ssn ? currentValue.replace(/[^a-zA-ZԱ-Ֆա-ֆА-Яа-яЁё0-9\s]/g, '') : currentValue);
|
|
4435
4653
|
if (inputChange && currentValue !== prevValue) {
|
|
4436
|
-
inputChange(currentValue);
|
|
4654
|
+
inputChange(ssn ? currentValue.replace(/[^a-zA-ZԱ-Ֆա-ֆА-Яа-яЁё0-9\s]/g, '') : currentValue);
|
|
4437
4655
|
}
|
|
4438
4656
|
};
|
|
4439
4657
|
React.useEffect(() => {
|
|
@@ -4444,7 +4662,7 @@ const TextInput = ({
|
|
|
4444
4662
|
newValue = value.substr(0, maxLength);
|
|
4445
4663
|
}
|
|
4446
4664
|
}
|
|
4447
|
-
setInnerValue(() => newValue);
|
|
4665
|
+
setInnerValue(() => ssn ? newValue.replace(/[^a-zA-ZԱ-Ֆա-ֆА-Яа-яЁё0-9\s]/g, '') : newValue);
|
|
4448
4666
|
}, [value]);
|
|
4449
4667
|
return /*#__PURE__*/React__default["default"].createElement("input", {
|
|
4450
4668
|
type: "text",
|
|
@@ -4458,7 +4676,10 @@ const TextInput = ({
|
|
|
4458
4676
|
...inpStyles,
|
|
4459
4677
|
border: 'none',
|
|
4460
4678
|
outline: 'none',
|
|
4461
|
-
|
|
4679
|
+
borderTopLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4680
|
+
borderTopRightRadius: checkRightIcon ? '0px' : radius,
|
|
4681
|
+
borderBottomLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4682
|
+
borderBottomRightRadius: checkRightIcon ? '0px' : radius
|
|
4462
4683
|
}
|
|
4463
4684
|
});
|
|
4464
4685
|
};
|
|
@@ -4467,11 +4688,13 @@ const PassInput = ({
|
|
|
4467
4688
|
show,
|
|
4468
4689
|
value,
|
|
4469
4690
|
radius,
|
|
4470
|
-
|
|
4691
|
+
disabled,
|
|
4471
4692
|
maxLength,
|
|
4693
|
+
inpStyles,
|
|
4694
|
+
inputChange,
|
|
4472
4695
|
inpAttributes,
|
|
4473
|
-
|
|
4474
|
-
|
|
4696
|
+
checkLeftIcon,
|
|
4697
|
+
checkRightIcon
|
|
4475
4698
|
}) => {
|
|
4476
4699
|
const [innerShow, setInnerShow] = React.useState('');
|
|
4477
4700
|
const [innerValue, setInnerValue] = React.useState('');
|
|
@@ -4511,7 +4734,10 @@ const PassInput = ({
|
|
|
4511
4734
|
...inpStyles,
|
|
4512
4735
|
border: 'none',
|
|
4513
4736
|
outline: 'none',
|
|
4514
|
-
|
|
4737
|
+
borderTopLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4738
|
+
borderTopRightRadius: checkRightIcon ? '0px' : radius,
|
|
4739
|
+
borderBottomLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4740
|
+
borderBottomRightRadius: checkRightIcon ? '0px' : radius
|
|
4515
4741
|
}
|
|
4516
4742
|
});
|
|
4517
4743
|
};
|
|
@@ -4524,11 +4750,15 @@ const NumberInput = ({
|
|
|
4524
4750
|
withZero,
|
|
4525
4751
|
disabled,
|
|
4526
4752
|
inpStyles,
|
|
4753
|
+
cardNumber,
|
|
4527
4754
|
minNumSize,
|
|
4528
4755
|
maxNumSize,
|
|
4529
4756
|
insideError,
|
|
4530
4757
|
inputChange,
|
|
4758
|
+
errorMessage,
|
|
4759
|
+
checkLeftIcon,
|
|
4531
4760
|
inpAttributes,
|
|
4761
|
+
checkRightIcon,
|
|
4532
4762
|
numberMaxLength,
|
|
4533
4763
|
setInnerErrorMessage
|
|
4534
4764
|
}) => {
|
|
@@ -4537,32 +4767,51 @@ const NumberInput = ({
|
|
|
4537
4767
|
const handleChange = event => {
|
|
4538
4768
|
let prevValue = innerValue;
|
|
4539
4769
|
let currentValue = event.target.value.replace(/\.|․|\.|,/g, '.');
|
|
4540
|
-
currentValue = handleUtilsCheckTypeNumber(currentValue, prevValue, null, float, maxNumSize, dots, innerMinNumSize, numberMaxLength);
|
|
4541
|
-
setInnerValue(() => currentValue);
|
|
4770
|
+
currentValue = handleUtilsCheckTypeNumber(currentValue, prevValue, null, float, maxNumSize, dots, innerMinNumSize, numberMaxLength, cardNumber);
|
|
4771
|
+
setInnerValue(() => cardNumber ? currentValue.replace(/(\d{4})(?=\d)/g, '$1-') : currentValue);
|
|
4542
4772
|
if (inputChange && currentValue !== prevValue) {
|
|
4543
4773
|
if (currentValue < Number.MIN_SAFE_INTEGER || currentValue > Number.MAX_SAFE_INTEGER) {
|
|
4544
|
-
if (
|
|
4545
|
-
|
|
4774
|
+
if (!cardNumber) {
|
|
4775
|
+
if (currentValue === '') {
|
|
4776
|
+
setInnerErrorMessage(() => '');
|
|
4777
|
+
} else {
|
|
4778
|
+
insideError && insideError();
|
|
4779
|
+
setInnerErrorMessage(() => `Լրացված դաշտի արժեքը պետք է լինի ${Number.MIN_SAFE_INTEGER} - ${Number.MAX_SAFE_INTEGER} թվերի միջակայքում`);
|
|
4780
|
+
}
|
|
4546
4781
|
} else {
|
|
4547
|
-
|
|
4548
|
-
|
|
4782
|
+
inputChange(currentValue.replaceAll('-', ''));
|
|
4783
|
+
if (errorMessage) {
|
|
4784
|
+
setInnerErrorMessage(() => errorMessage);
|
|
4785
|
+
} else {
|
|
4786
|
+
setInnerErrorMessage(() => '');
|
|
4787
|
+
}
|
|
4549
4788
|
}
|
|
4550
4789
|
} else if (innerMinNumSize && currentValue < innerMinNumSize || maxNumSize && currentValue > maxNumSize) {
|
|
4551
4790
|
if (currentValue === '') {
|
|
4552
4791
|
setInnerErrorMessage(() => '');
|
|
4553
4792
|
} else {
|
|
4554
|
-
|
|
4555
|
-
|
|
4556
|
-
|
|
4557
|
-
|
|
4558
|
-
|
|
4559
|
-
|
|
4560
|
-
|
|
4793
|
+
if (!cardNumber) {
|
|
4794
|
+
insideError && insideError();
|
|
4795
|
+
if (innerMinNumSize && !maxNumSize) {
|
|
4796
|
+
setInnerErrorMessage(() => `Լրացված դաշտի արժեքը պետք է լինի ոչ պակաս ${innerMinNumSize} - ից`);
|
|
4797
|
+
} else if (!innerMinNumSize && maxNumSize) {
|
|
4798
|
+
setInnerErrorMessage(() => `Լրացված դաշտի արժեքը պետք է լինի ոչ մեծ ${maxNumSize} ֊ ից`);
|
|
4799
|
+
} else if (innerMinNumSize && maxNumSize) {
|
|
4800
|
+
setInnerErrorMessage(() => `Լրացված դաշտի արժեքը պետք է լինի ${innerMinNumSize} - ${maxNumSize} թվերի միջակայքում`);
|
|
4801
|
+
}
|
|
4561
4802
|
}
|
|
4562
4803
|
}
|
|
4563
4804
|
} else if (currentValue >= Number.MIN_SAFE_INTEGER || currentValue <= Number.MAX_SAFE_INTEGER || innerMinNumSize && currentValue >= innerMinNumSize || maxNumSize && currentValue <= maxNumSize) {
|
|
4564
|
-
inputChange(currentValue);
|
|
4565
|
-
|
|
4805
|
+
inputChange(cardNumber ? currentValue.replaceAll('-', '') : currentValue);
|
|
4806
|
+
if (cardNumber) {
|
|
4807
|
+
if (errorMessage) {
|
|
4808
|
+
setInnerErrorMessage(() => errorMessage);
|
|
4809
|
+
} else {
|
|
4810
|
+
setInnerErrorMessage(() => '');
|
|
4811
|
+
}
|
|
4812
|
+
} else {
|
|
4813
|
+
setInnerErrorMessage(() => '');
|
|
4814
|
+
}
|
|
4566
4815
|
}
|
|
4567
4816
|
}
|
|
4568
4817
|
};
|
|
@@ -4572,7 +4821,7 @@ const NumberInput = ({
|
|
|
4572
4821
|
if (parseFloat(newVal) === 0) {
|
|
4573
4822
|
inputChange('');
|
|
4574
4823
|
} else {
|
|
4575
|
-
inputChange(newVal);
|
|
4824
|
+
inputChange(cardNumber ? newVal.replaceAll('-', '') : newVal);
|
|
4576
4825
|
}
|
|
4577
4826
|
}
|
|
4578
4827
|
};
|
|
@@ -4590,10 +4839,11 @@ const NumberInput = ({
|
|
|
4590
4839
|
React.useEffect(() => {
|
|
4591
4840
|
let newValue = '';
|
|
4592
4841
|
if (value !== undefined && value !== null) {
|
|
4593
|
-
newValue = handleUtilsCheckTypeNumber(value, newValue, null, float, maxNumSize, dots, innerMinNumSize, numberMaxLength);
|
|
4842
|
+
newValue = handleUtilsCheckTypeNumber(value, newValue, null, float, maxNumSize, dots, innerMinNumSize, numberMaxLength, cardNumber);
|
|
4594
4843
|
}
|
|
4595
|
-
setInnerValue(() => newValue);
|
|
4596
|
-
|
|
4844
|
+
setInnerValue(() => cardNumber ? newValue.replace(/(\d{4})(?=\d)/g, '$1-') : newValue);
|
|
4845
|
+
// inputChange(cardNumber ? newValue.replaceAll('-', '') : newValue);
|
|
4846
|
+
}, [dots, value, float, cardNumber, maxNumSize, minNumSize, numberMaxLength]);
|
|
4597
4847
|
return /*#__PURE__*/React__default["default"].createElement("input", {
|
|
4598
4848
|
type: "text",
|
|
4599
4849
|
value: innerValue,
|
|
@@ -4605,7 +4855,10 @@ const NumberInput = ({
|
|
|
4605
4855
|
...inpStyles,
|
|
4606
4856
|
border: 'none',
|
|
4607
4857
|
outline: 'none',
|
|
4608
|
-
|
|
4858
|
+
borderTopLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4859
|
+
borderTopRightRadius: checkRightIcon ? '0px' : radius,
|
|
4860
|
+
borderBottomLeftRadius: checkLeftIcon ? '0px' : radius,
|
|
4861
|
+
borderBottomRightRadius: checkRightIcon ? '0px' : radius
|
|
4609
4862
|
},
|
|
4610
4863
|
min: minNumSize,
|
|
4611
4864
|
max: maxNumSize,
|
|
@@ -4614,9 +4867,9 @@ const NumberInput = ({
|
|
|
4614
4867
|
});
|
|
4615
4868
|
};
|
|
4616
4869
|
|
|
4617
|
-
var css_248z$
|
|
4870
|
+
var css_248z$a = ".input-module_input-wrap__NunrE{position:relative;width:100%}.input-module_input-content__kP7lZ{appearance:none!important;-webkit-appearance:none!important;display:flex;width:100%}input:-webkit-autofill,input:-webkit-autofill:active,input:-webkit-autofill:focus,input:-webkit-autofill:hover{background-color:inherit!important}input::-ms-clear,input::-ms-reveal{display:none}.input-module_error-message-show__OrVSo{animation-fill-mode:forwards;animation-name:input-module_error-show__9MP6k}.input-module_inp-num__vH7HL::-webkit-inner-spin-button,.input-module_inp-num__vH7HL::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.input-module_inp-num__vH7HL[type=number]{-moz-appearance:textfield}@keyframes input-module_error-show__9MP6k{to{bottom:-20px;transform:scaleX(1);-webkit-transform:scaleX(1);-moz-transform:scaleX(1);-ms-transform:scaleX(1);-o-transform:scaleX(1)}}";
|
|
4618
4871
|
var styles$8 = {"input-wrap":"input-module_input-wrap__NunrE","input-content":"input-module_input-content__kP7lZ","error-message-show":"input-module_error-message-show__OrVSo","error-show":"input-module_error-show__9MP6k","inp-num":"input-module_inp-num__vH7HL"};
|
|
4619
|
-
styleInject(css_248z$
|
|
4872
|
+
styleInject(css_248z$a);
|
|
4620
4873
|
|
|
4621
4874
|
const InputTypes = {
|
|
4622
4875
|
TEL: 'tel',
|
|
@@ -4632,6 +4885,7 @@ const P = styled__default["default"].span`
|
|
|
4632
4885
|
animation: ${true};
|
|
4633
4886
|
`;
|
|
4634
4887
|
const Input = ({
|
|
4888
|
+
ssn,
|
|
4635
4889
|
size,
|
|
4636
4890
|
name,
|
|
4637
4891
|
style,
|
|
@@ -4671,6 +4925,7 @@ const Input = ({
|
|
|
4671
4925
|
errorColor,
|
|
4672
4926
|
withoutDot,
|
|
4673
4927
|
errorStyle,
|
|
4928
|
+
iconPadding,
|
|
4674
4929
|
labelAction,
|
|
4675
4930
|
errorAction,
|
|
4676
4931
|
placeholder,
|
|
@@ -4687,6 +4942,7 @@ const Input = ({
|
|
|
4687
4942
|
errorIconSide,
|
|
4688
4943
|
showErrorIcon,
|
|
4689
4944
|
errorMarginTop,
|
|
4945
|
+
errorBoxShadow,
|
|
4690
4946
|
boxShadowHover,
|
|
4691
4947
|
errorClassName,
|
|
4692
4948
|
labelIconMargin,
|
|
@@ -4707,6 +4963,7 @@ const Input = ({
|
|
|
4707
4963
|
fireInputInsideError,
|
|
4708
4964
|
backgroundDisableColor,
|
|
4709
4965
|
telBorderRightColorHover,
|
|
4966
|
+
cardNumber,
|
|
4710
4967
|
type = 'text'
|
|
4711
4968
|
}) => {
|
|
4712
4969
|
const [show, setShow] = React.useState(false);
|
|
@@ -4738,19 +4995,22 @@ const Input = ({
|
|
|
4738
4995
|
iName: name ? name : `tui_${uuid}_tui`,
|
|
4739
4996
|
autoComplete: autoComplete ?? configStyles.INPUT.autoComplete
|
|
4740
4997
|
};
|
|
4741
|
-
|
|
4742
|
-
|
|
4743
|
-
|
|
4744
|
-
|
|
4745
|
-
|
|
4746
|
-
|
|
4747
|
-
|
|
4748
|
-
|
|
4749
|
-
|
|
4750
|
-
|
|
4751
|
-
|
|
4752
|
-
|
|
4753
|
-
|
|
4998
|
+
|
|
4999
|
+
// const errorShow = keyframes`
|
|
5000
|
+
// 100% {
|
|
5001
|
+
// bottom: '-20px';
|
|
5002
|
+
// transform: scale3d(1,1,1);
|
|
5003
|
+
// -webkit-transform: scale3d(1,1,1);
|
|
5004
|
+
// -moz-transform: scale3d(1,1,1);
|
|
5005
|
+
// -ms-transform: scale3d(1,1,1);
|
|
5006
|
+
// -o-transform: scale3d(1,1,1);
|
|
5007
|
+
// }
|
|
5008
|
+
// `
|
|
5009
|
+
|
|
5010
|
+
// const animation = () => css`
|
|
5011
|
+
// ${errorShow} 240ms forwards
|
|
5012
|
+
// `
|
|
5013
|
+
|
|
4754
5014
|
const handleMouseEnter = () => {
|
|
4755
5015
|
setIsHover(true);
|
|
4756
5016
|
};
|
|
@@ -4848,7 +5108,7 @@ const Input = ({
|
|
|
4848
5108
|
style: {
|
|
4849
5109
|
width: width ?? configStyles.INPUT.width,
|
|
4850
5110
|
borderRadius: radius ?? configStyles.INPUT.radius,
|
|
4851
|
-
boxShadow: innerErrorMessage ?
|
|
5111
|
+
boxShadow: innerErrorMessage ? errorBoxShadow ? errorBoxShadow : configStyles.INPUT.error.box.shadow : isHover && !disabled ? boxShadowHover ? boxShadowHover : configStyles.INPUT.box.shadowHover : boxShadow ? boxShadow : configStyles.INPUT.box.shadow
|
|
4852
5112
|
},
|
|
4853
5113
|
onMouseEnter: handleMouseEnter,
|
|
4854
5114
|
onMouseLeave: handleMouseLeave
|
|
@@ -4860,9 +5120,9 @@ const Input = ({
|
|
|
4860
5120
|
justifyContent: 'center',
|
|
4861
5121
|
cursor: type === 'password' ? 'pointer' : 'default',
|
|
4862
5122
|
height: height ?? configStyles.INPUT.height,
|
|
4863
|
-
padding: padding ?? configStyles.INPUT.padding,
|
|
4864
5123
|
width: iconWidth ?? configStyles.INPUT.iconWidth,
|
|
4865
5124
|
boxSizing: boxSizing ?? configStyles.INPUT.box.sizing,
|
|
5125
|
+
padding: iconPadding ?? configStyles.INPUT.iconPadding,
|
|
4866
5126
|
borderTopLeftRadius: radius ?? configStyles.INPUT.radius,
|
|
4867
5127
|
borderBottomLeftRadius: radius ?? configStyles.INPUT.radius,
|
|
4868
5128
|
backgroundColor: disabled ? backgroundDisableColor ? backgroundDisableColor : configStyles.INPUT.colors.backgroundDisable : backgroundColor ? backgroundColor : configStyles.INPUT.colors.background
|
|
@@ -4891,13 +5151,17 @@ const Input = ({
|
|
|
4891
5151
|
withZero: withZero,
|
|
4892
5152
|
inputChange: change,
|
|
4893
5153
|
inpStyles: inpStyles,
|
|
5154
|
+
cardNumber: cardNumber,
|
|
5155
|
+
errorMessage: errorMessage,
|
|
4894
5156
|
inpAttributes: inpAttributes,
|
|
4895
5157
|
numberMaxLength: numberMaxLength,
|
|
4896
5158
|
insideError: fireInputInsideError,
|
|
4897
5159
|
minNumSize: minNumSize ? minNumSize : '',
|
|
4898
5160
|
maxNumSize: maxNumSize ? maxNumSize : '',
|
|
4899
5161
|
setInnerErrorMessage: setInnerErrorMessage,
|
|
4900
|
-
radius: radius ?? configStyles.INPUT.radius
|
|
5162
|
+
radius: radius ?? configStyles.INPUT.radius,
|
|
5163
|
+
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5164
|
+
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
4901
5165
|
}) : type === 'password' ? /*#__PURE__*/React__default["default"].createElement(PassInput, {
|
|
4902
5166
|
show: show,
|
|
4903
5167
|
type: type,
|
|
@@ -4907,15 +5171,20 @@ const Input = ({
|
|
|
4907
5171
|
inpStyles: inpStyles,
|
|
4908
5172
|
inpAttributes: inpAttributes,
|
|
4909
5173
|
radius: radius ?? configStyles.INPUT.radius,
|
|
4910
|
-
maxLength: maxLength ?? configStyles.INPUT.maxLength
|
|
5174
|
+
maxLength: maxLength ?? configStyles.INPUT.maxLength,
|
|
5175
|
+
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5176
|
+
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
4911
5177
|
}) : /*#__PURE__*/React__default["default"].createElement(TextInput, {
|
|
5178
|
+
ssn: ssn,
|
|
4912
5179
|
value: innerValue,
|
|
4913
5180
|
disabled: disabled,
|
|
4914
5181
|
inputChange: change,
|
|
4915
5182
|
inpStyles: inpStyles,
|
|
4916
5183
|
inpAttributes: inpAttributes,
|
|
4917
5184
|
radius: radius ?? configStyles.INPUT.radius,
|
|
4918
|
-
maxLength: maxLength ?? configStyles.INPUT.maxLength
|
|
5185
|
+
maxLength: maxLength ?? configStyles.INPUT.maxLength,
|
|
5186
|
+
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5187
|
+
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
4919
5188
|
}), rightIcon && rightIcon.length > 0 ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4920
5189
|
onClick: type === 'password' ? handleShowPass : _ => _,
|
|
4921
5190
|
style: {
|
|
@@ -4924,15 +5193,16 @@ const Input = ({
|
|
|
4924
5193
|
justifyContent: 'center',
|
|
4925
5194
|
cursor: type === 'password' ? 'pointer' : 'default',
|
|
4926
5195
|
height: height ?? configStyles.INPUT.height,
|
|
4927
|
-
padding: padding ?? configStyles.INPUT.padding,
|
|
4928
5196
|
width: iconWidth ?? configStyles.INPUT.iconWidth,
|
|
4929
5197
|
boxSizing: boxSizing ?? configStyles.INPUT.box.sizing,
|
|
5198
|
+
padding: iconPadding ?? configStyles.INPUT.iconPadding,
|
|
4930
5199
|
borderTopRightRadius: radius ?? configStyles.INPUT.radius,
|
|
4931
5200
|
borderBottomRightRadius: radius ?? configStyles.INPUT.radius,
|
|
4932
5201
|
backgroundColor: disabled ? backgroundDisableColor ? backgroundDisableColor : configStyles.INPUT.colors.backgroundDisable : backgroundColor ? backgroundColor : configStyles.INPUT.colors.background
|
|
4933
5202
|
}
|
|
4934
|
-
}, type === 'password' ? show ? rightIcon[1] : rightIcon[0] : rightIcon[0]) : ''), tooltip ? tooltip : '', innerErrorMessage ? /*#__PURE__*/React__default["default"].createElement(P
|
|
4935
|
-
|
|
5203
|
+
}, type === 'password' ? show ? rightIcon[1] : rightIcon[0] : rightIcon[0]) : ''), tooltip ? tooltip : '', innerErrorMessage ? /*#__PURE__*/React__default["default"].createElement(P
|
|
5204
|
+
// animation={animation}
|
|
5205
|
+
, {
|
|
4936
5206
|
style: {
|
|
4937
5207
|
margin: '0px',
|
|
4938
5208
|
display: 'flex',
|
|
@@ -4982,6 +5252,7 @@ const Input = ({
|
|
|
4982
5252
|
})) : '');
|
|
4983
5253
|
};
|
|
4984
5254
|
Input.propTypes = {
|
|
5255
|
+
ssn: PropTypes__default["default"].bool,
|
|
4985
5256
|
size: PropTypes__default["default"].string,
|
|
4986
5257
|
name: PropTypes__default["default"].string,
|
|
4987
5258
|
change: PropTypes__default["default"].func,
|
|
@@ -4996,10 +5267,12 @@ Input.propTypes = {
|
|
|
4996
5267
|
height: PropTypes__default["default"].string,
|
|
4997
5268
|
radius: PropTypes__default["default"].string,
|
|
4998
5269
|
padding: PropTypes__default["default"].string,
|
|
5270
|
+
cardNumber: PropTypes__default["default"].bool,
|
|
4999
5271
|
tooltip: PropTypes__default["default"].element,
|
|
5000
5272
|
withoutDot: PropTypes__default["default"].bool,
|
|
5001
5273
|
className: PropTypes__default["default"].string,
|
|
5002
5274
|
iconWidth: PropTypes__default["default"].string,
|
|
5275
|
+
iconPadding: PropTypes__default["default"].string,
|
|
5003
5276
|
maxLength: PropTypes__default["default"].number,
|
|
5004
5277
|
floatToFix: PropTypes__default["default"].number,
|
|
5005
5278
|
minNumSize: PropTypes__default["default"].number,
|
|
@@ -5043,6 +5316,7 @@ Input.propTypes = {
|
|
|
5043
5316
|
errorLineHeight: PropTypes__default["default"].string,
|
|
5044
5317
|
boxSizing: PropTypes__default["default"].string,
|
|
5045
5318
|
boxShadow: PropTypes__default["default"].string,
|
|
5319
|
+
errorBoxShadow: PropTypes__default["default"].string,
|
|
5046
5320
|
boxShadowHover: PropTypes__default["default"].string,
|
|
5047
5321
|
phoneAlignItems: PropTypes__default["default"].string,
|
|
5048
5322
|
numberMaxLength: PropTypes__default["default"].number,
|
|
@@ -5079,10 +5353,12 @@ const Radio = ({
|
|
|
5079
5353
|
borderStyle,
|
|
5080
5354
|
labelFontSize,
|
|
5081
5355
|
labelFontStyle,
|
|
5356
|
+
labelActiveColor,
|
|
5082
5357
|
labelFontFamily,
|
|
5083
5358
|
labelFontWeight,
|
|
5084
5359
|
labelLineHeight,
|
|
5085
5360
|
radioMarginRight,
|
|
5361
|
+
borderHoverColor,
|
|
5086
5362
|
borderActiveColor,
|
|
5087
5363
|
radioItemMarginRight,
|
|
5088
5364
|
radioItemMarginBottom,
|
|
@@ -5101,22 +5377,14 @@ const Radio = ({
|
|
|
5101
5377
|
});
|
|
5102
5378
|
const handleMouseEnter = (id, elemID) => {
|
|
5103
5379
|
const elem = document.querySelector(`#${elemID}`);
|
|
5104
|
-
|
|
5105
|
-
|
|
5106
|
-
|
|
5107
|
-
// ? borderActiveColor
|
|
5108
|
-
// ? borderActiveColor
|
|
5109
|
-
// : configStyles.RADIO.border.activeColor
|
|
5110
|
-
// : borderColor
|
|
5111
|
-
// ? borderColor
|
|
5112
|
-
// : configStyles.RADIO.border.color
|
|
5113
|
-
// }
|
|
5114
|
-
// handleUtilsMouseEnterLeave(e, newStyles);
|
|
5115
|
-
|
|
5116
|
-
elem.style.backgroundColor = id === innerSelectedData?.id ? borderActiveColor ? borderActiveColor : configStyles.RADIO.border.activeColor : borderColor ? borderColor : configStyles.RADIO.border.color;
|
|
5380
|
+
const borderStyle = elem.parentElement;
|
|
5381
|
+
borderStyle.style.borderColor = id === innerSelectedData?.id ? borderActiveColor ? borderActiveColor : configStyles.RADIO.border.activeColor : borderHoverColor ? borderHoverColor : configStyles.RADIO.border.hoverColor;
|
|
5382
|
+
elem.style.backgroundColor = id === innerSelectedData?.id ? borderActiveColor ? borderActiveColor : configStyles.RADIO.border.activeColor : borderHoverColor ? borderHoverColor : configStyles.RADIO.border.hoverColor;
|
|
5117
5383
|
};
|
|
5118
5384
|
const handleMouseLeave = (id, elemID) => {
|
|
5119
5385
|
const elem = document.querySelector(`#${elemID}`);
|
|
5386
|
+
const borderStyle = elem.parentElement;
|
|
5387
|
+
borderStyle.style.borderColor = id === innerSelectedData?.id ? borderActiveColor ? borderActiveColor : configStyles.RADIO.border.activeColor : borderColor ? borderColor : configStyles.RADIO.border.color;
|
|
5120
5388
|
elem.style.backgroundColor = id === innerSelectedData?.id ? borderActiveColor ? borderActiveColor : configStyles.RADIO.border.activeColor : 'transparent';
|
|
5121
5389
|
};
|
|
5122
5390
|
const handleChecked = selItem => {
|
|
@@ -5223,15 +5491,13 @@ const Radio = ({
|
|
|
5223
5491
|
}
|
|
5224
5492
|
})), item[innerKeyNames.label] ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
5225
5493
|
style: {
|
|
5226
|
-
color: labelColor ?? configStyles.RADIO.label.color,
|
|
5494
|
+
color: item[innerKeyNames.id] === innerSelectedData.id ? labelActiveColor ?? configStyles.RADIO.label.activeColor : labelColor ?? configStyles.RADIO.label.color,
|
|
5227
5495
|
fontSize: labelFontSize ?? configStyles.RADIO.label.font.size,
|
|
5228
5496
|
fontStyle: labelFontStyle ?? configStyles.RADIO.label.font.style,
|
|
5229
5497
|
fontFamily: labelFontFamily ?? configStyles.RADIO.label.font.family,
|
|
5230
5498
|
fontWeight: labelFontWeight ?? configStyles.RADIO.label.font.weight,
|
|
5231
5499
|
lineHeight: labelLineHeight ?? configStyles.RADIO.label.lineHeight
|
|
5232
|
-
}
|
|
5233
|
-
onMouseEnter: () => handleMouseEnter(item[innerKeyNames.id], elemId),
|
|
5234
|
-
onMouseLeave: () => handleMouseLeave(item[innerKeyNames.id], elemId)
|
|
5500
|
+
}
|
|
5235
5501
|
}, item[innerKeyNames.label]) : '');
|
|
5236
5502
|
}));
|
|
5237
5503
|
};
|
|
@@ -5246,11 +5512,13 @@ Radio.propTypes = {
|
|
|
5246
5512
|
borderStyle: PropTypes__default["default"].string,
|
|
5247
5513
|
labelFontSize: PropTypes__default["default"].string,
|
|
5248
5514
|
labelFontStyle: PropTypes__default["default"].string,
|
|
5515
|
+
labelActiveColor: PropTypes__default["default"].string,
|
|
5249
5516
|
labelFontFamily: PropTypes__default["default"].string,
|
|
5250
5517
|
labelFontWeight: PropTypes__default["default"].string,
|
|
5251
5518
|
labelLineHeight: PropTypes__default["default"].string,
|
|
5252
5519
|
radioMarginRight: PropTypes__default["default"].string,
|
|
5253
5520
|
getData: PropTypes__default["default"].func.isRequired,
|
|
5521
|
+
borderHoverColor: PropTypes__default["default"].string,
|
|
5254
5522
|
borderActiveColor: PropTypes__default["default"].string,
|
|
5255
5523
|
radioItemMarginRight: PropTypes__default["default"].string,
|
|
5256
5524
|
radioItemMarginBottom: PropTypes__default["default"].string,
|
|
@@ -5277,12 +5545,13 @@ const SvgArrow = ({
|
|
|
5277
5545
|
fill: fillColor ? fillColor : '#3C393E'
|
|
5278
5546
|
}));
|
|
5279
5547
|
|
|
5280
|
-
var css_248z$
|
|
5548
|
+
var css_248z$9 = ".select-module_select-content__GCMDX{-webkit-appearance:none;display:flex;flex-direction:column;position:relative}.select-module_select-content-top__Aw-fB{align-items:center;-webkit-appearance:none;display:flex;flex-direction:row;flex-wrap:nowrap}.select-module_select-content-bottom__ueZCR{animation:select-module_select-show__391hQ .64s linear forwards;-webkit-animation:select-module_select-show__391hQ .64s linear forwards;left:0;max-height:0;overflow:hidden;position:absolute;width:100%;z-index:99999999999}.select-module_select-content-bottom-inner__NWy2X{display:flex;flex-direction:column;max-height:234px;overflow-x:hidden;overflow-y:auto}.select-module_select-content-top-icon__MBrGK{align-items:center;box-sizing:border-box;display:flex;flex:0 0 auto}.select-module_select-content-top-icon__MBrGK>div{align-items:center;display:flex;height:fit-content;justify-content:center;max-height:30px;max-width:30px;min-height:14px;min-width:14px;width:fit-content}.select-module_close-icon__SFNaJ{border-right:1px solid #eee;box-sizing:content-box;padding-right:9px}.select-module_arrow-icon__rjHt-{margin-left:9px;transform-origin:center;transition:all .64s ease;-webkit-transition:all .64s ease;-moz-transition:all .64s ease;-ms-transition:all .64s ease;-o-transition:all .64s ease}.select-module_select-content-bottom-row__eKq5L{align-items:center;display:flex;transition:background-color .24s,color .24s;-webkit-transition:background-color .24s,color .24s;-moz-transition:background-color .24s,color .24s;-ms-transition:background-color .24s,color .24s;-o-transition:background-color .24s,color .24s}.select-module_select-content-bottom-row__eKq5L:last-child{margin-bottom:0}.select-module_ellipsis__uNgol{display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@keyframes select-module_select-show__391hQ{to{max-height:234px}}";
|
|
5281
5549
|
var styles$7 = {"select-content":"select-module_select-content__GCMDX","select-content-top":"select-module_select-content-top__Aw-fB","select-content-bottom":"select-module_select-content-bottom__ueZCR","select-show":"select-module_select-show__391hQ","select-content-bottom-inner":"select-module_select-content-bottom-inner__NWy2X","select-content-top-icon":"select-module_select-content-top-icon__MBrGK","close-icon":"select-module_close-icon__SFNaJ","arrow-icon":"select-module_arrow-icon__rjHt-","select-content-bottom-row":"select-module_select-content-bottom-row__eKq5L","ellipsis":"select-module_ellipsis__uNgol"};
|
|
5282
|
-
styleInject(css_248z$
|
|
5550
|
+
styleInject(css_248z$9);
|
|
5283
5551
|
|
|
5284
5552
|
const Select = ({
|
|
5285
5553
|
dots,
|
|
5554
|
+
lang,
|
|
5286
5555
|
options,
|
|
5287
5556
|
multiple,
|
|
5288
5557
|
disabled,
|
|
@@ -5296,6 +5565,7 @@ const Select = ({
|
|
|
5296
5565
|
closeIcon,
|
|
5297
5566
|
errorZindex,
|
|
5298
5567
|
errorMessage,
|
|
5568
|
+
arrowNoRotate,
|
|
5299
5569
|
showCloseIcon,
|
|
5300
5570
|
defaultOption,
|
|
5301
5571
|
multipleCheckbox,
|
|
@@ -5336,6 +5606,8 @@ const Select = ({
|
|
|
5336
5606
|
optionItemCursor,
|
|
5337
5607
|
optionItemPadding,
|
|
5338
5608
|
optionItemFontSize,
|
|
5609
|
+
optionItemFontStyle,
|
|
5610
|
+
optionItemFontFamily,
|
|
5339
5611
|
optionItemMinHeight,
|
|
5340
5612
|
optionItemBoxSizing,
|
|
5341
5613
|
optionItemFontWeight,
|
|
@@ -5345,7 +5617,8 @@ const Select = ({
|
|
|
5345
5617
|
optionItemBackgroudColor,
|
|
5346
5618
|
optionItemBackgroudColorHover,
|
|
5347
5619
|
boxShadow,
|
|
5348
|
-
boxShadowHover
|
|
5620
|
+
boxShadowHover,
|
|
5621
|
+
insidePagination
|
|
5349
5622
|
}) => {
|
|
5350
5623
|
const ref = React.useRef();
|
|
5351
5624
|
const [opened, setOpened] = React.useState(false);
|
|
@@ -5493,10 +5766,10 @@ const Select = ({
|
|
|
5493
5766
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5494
5767
|
className: styles$7['select-content']
|
|
5495
5768
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5769
|
+
className: `${styles$7['select-content-top']}`,
|
|
5496
5770
|
style: {
|
|
5497
5771
|
cursor: disabled ? 'not-allowed' : cursor ? cursor : configStyles.SELECT.selected.cursor,
|
|
5498
5772
|
minHeight: selectedMinHeight ?? configStyles.SELECT.selected.minHeight,
|
|
5499
|
-
padding: selectedPadding ?? configStyles.SELECT.selected.padding,
|
|
5500
5773
|
borderRadius: selectedRadius ?? configStyles.SELECT.selected.radius,
|
|
5501
5774
|
fontSize: selectedFontSize ?? configStyles.SELECT.selected.font.size,
|
|
5502
5775
|
fontStyle: selectedFontStyle ?? configStyles.SELECT.selected.font.style,
|
|
@@ -5505,19 +5778,20 @@ const Select = ({
|
|
|
5505
5778
|
fontWeight: selectedFontWeight ?? configStyles.SELECT.selected.font.weight,
|
|
5506
5779
|
lineHeight: selectedLineHeight ?? configStyles.SELECT.selected.lineHeight,
|
|
5507
5780
|
transition: selectedTransition ?? configStyles.SELECT.selected.transition,
|
|
5781
|
+
padding: insidePagination ? '0px 2px' : selectedPadding ?? configStyles.SELECT.selected.padding,
|
|
5782
|
+
justifyContent: insidePagination ? 'center' : 'space-between',
|
|
5508
5783
|
backgroundColor: disabled ? selectedDisableBackgroundColor ? selectedDisableBackgroundColor : configStyles.SELECT.selected.colors.backgroundDisable : selectedBackgroundColor ? selectedBackgroundColor : configStyles.SELECT.selected.colors.background,
|
|
5509
5784
|
boxShadow: errorMessage ? errorColor ? `0 0 0 2px ${errorColor}` : configStyles.SELECT.error.box.shadow : isHover ? boxShadowHover ? boxShadowHover : configStyles.SELECT.box.shadowHover : boxShadow ? boxShadow : configStyles.SELECT.box.shadow
|
|
5510
5785
|
},
|
|
5511
5786
|
onClick: disabled ? _ => _ : () => handleOpenClose(),
|
|
5512
5787
|
onMouseEnter: disabled ? _ => _ : () => handleMouseEnter(),
|
|
5513
|
-
onMouseLeave: disabled ? _ => _ : () => handleMouseLeave()
|
|
5514
|
-
className: `${styles$7['select-content-top']}`
|
|
5788
|
+
onMouseLeave: disabled ? _ => _ : () => handleMouseLeave()
|
|
5515
5789
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5516
5790
|
className: `${styles$7['select-content-top-text']}`,
|
|
5517
5791
|
style: {
|
|
5518
5792
|
whiteSpace: disabled ? 'pre-wrap' : 'nowrap',
|
|
5519
|
-
overflow: 'hidden',
|
|
5520
|
-
textOverflow: 'ellipsis',
|
|
5793
|
+
overflow: insidePagination ? 'visible' : 'hidden',
|
|
5794
|
+
textOverflow: insidePagination ? 'initial' : 'ellipsis',
|
|
5521
5795
|
color: isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selected.colors.hover : selectedColor ? selectedColor : configStyles.SELECT.selected.color
|
|
5522
5796
|
}
|
|
5523
5797
|
}, !multiple && newSelected && newSelected[0] && newSelected[0][keyNames.name] ? newSelected[0][keyNames.name] : newSelected && newSelected.length > 0 ? newSelected.map((_, index) => {
|
|
@@ -5529,7 +5803,10 @@ const Select = ({
|
|
|
5529
5803
|
}
|
|
5530
5804
|
}
|
|
5531
5805
|
}) : defaultOption ? defaultOption : ''), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5532
|
-
className: `${styles$7['select-content-top-icon']}
|
|
5806
|
+
className: `${styles$7['select-content-top-icon']}`,
|
|
5807
|
+
style: {
|
|
5808
|
+
padding: lang ? '0px' : insidePagination ? '0px 5px' : '0 5px 0 20px'
|
|
5809
|
+
}
|
|
5533
5810
|
}, !disabled && multiple && newSelected.length > 1 && /*#__PURE__*/React__default["default"].createElement("span", null, newSelected.length), (showCloseIcon === true || showCloseIcon === false ? showCloseIcon : configStyles.SELECT.showCloseIcon) && !disabled && newSelected && newSelected.length > 0 && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5534
5811
|
className: `${styles$7['close-icon']}`,
|
|
5535
5812
|
onClick: disabled ? _ => _ : handleClearSelect,
|
|
@@ -5537,10 +5814,11 @@ const Select = ({
|
|
|
5537
5814
|
marginLeft: multiple && newSelected.length > 1 ? '17px' : '0px'
|
|
5538
5815
|
}
|
|
5539
5816
|
}, closeIcon ? closeIcon : configStyles.SELECT.closeIcon ? configStyles.SELECT.closeIcon : /*#__PURE__*/React__default["default"].createElement(SvgCloseIcon, null)), !disabled ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5817
|
+
className: `${styles$7['arrow-icon']}`,
|
|
5540
5818
|
style: {
|
|
5541
|
-
|
|
5542
|
-
|
|
5543
|
-
|
|
5819
|
+
marginLeft: lang ? '0px' : '9px',
|
|
5820
|
+
transform: arrowNoRotate || configStyles.SELECT.arrowNoRotate ? 'rotate(0deg)' : opened ? 'rotate(180deg)' : 'rotate(0deg)'
|
|
5821
|
+
}
|
|
5544
5822
|
}, arrowIcon ? arrowIcon : configStyles.SELECT.arrowIcon ? configStyles.SELECT.arrowIcon : /*#__PURE__*/React__default["default"].createElement(SvgArrow, null)) : '')), opened && existOptions && existOptions.length > 0 && !disabled ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5545
5823
|
style: {
|
|
5546
5824
|
boxShadow: optionsBoxShadow ?? configStyles.SELECT.options.box.shadow,
|
|
@@ -5566,12 +5844,15 @@ const Select = ({
|
|
|
5566
5844
|
cursor: optionItemCursor ?? configStyles.SELECT.options.item.cursor,
|
|
5567
5845
|
padding: optionItemPadding ?? configStyles.SELECT.options.item.padding,
|
|
5568
5846
|
fontSize: optionItemFontSize ?? configStyles.SELECT.options.item.font.size,
|
|
5847
|
+
fontStyle: optionItemFontStyle ?? configStyles.SELECT.options.item.font.style,
|
|
5848
|
+
fontFamily: optionItemFontFamily ?? configStyles.SELECT.options.item.font.family,
|
|
5569
5849
|
boxSizing: optionItemBoxSizing ?? configStyles.SELECT.options.item.box.sizing,
|
|
5570
5850
|
minHeight: optionItemMinHeight ?? configStyles.SELECT.options.item.minHeight,
|
|
5571
5851
|
fontWeight: optionItemFontWeight ?? configStyles.SELECT.options.item.font.weight,
|
|
5572
5852
|
lineHeight: dots || configStyles.SELECT.dots ? '46px' : optionItemLineHeight ? optionItemLineHeight : configStyles.SELECT.options.item.lineHeight,
|
|
5573
5853
|
marginBottom: optionItemMarginBottom ?? configStyles.SELECT.options.item.marginBottom,
|
|
5574
|
-
backgroundColor: optionItemBackgroudColor ?? configStyles.SELECT.options.item.colors.backgroud
|
|
5854
|
+
backgroundColor: optionItemBackgroudColor ?? configStyles.SELECT.options.item.colors.backgroud,
|
|
5855
|
+
justifyContent: lang ? 'center' : 'flex-start'
|
|
5575
5856
|
}
|
|
5576
5857
|
}, multiple && multipleCheckbox ? /*#__PURE__*/React__default["default"].createElement(SingleCheckbox, {
|
|
5577
5858
|
checked: option.checked
|
|
@@ -5591,6 +5872,7 @@ const Select = ({
|
|
|
5591
5872
|
};
|
|
5592
5873
|
Select.propTypes = {
|
|
5593
5874
|
dots: PropTypes__default["default"].bool,
|
|
5875
|
+
lang: PropTypes__default["default"].bool,
|
|
5594
5876
|
options: PropTypes__default["default"].array,
|
|
5595
5877
|
multiple: PropTypes__default["default"].bool,
|
|
5596
5878
|
onChange: PropTypes__default["default"].func,
|
|
@@ -5602,6 +5884,7 @@ Select.propTypes = {
|
|
|
5602
5884
|
className: PropTypes__default["default"].string,
|
|
5603
5885
|
arrowIcon: PropTypes__default["default"].element,
|
|
5604
5886
|
closeIcon: PropTypes__default["default"].element,
|
|
5887
|
+
arrowNoRotate: PropTypes__default["default"].bool,
|
|
5605
5888
|
showCloseIcon: PropTypes__default["default"].bool,
|
|
5606
5889
|
errorZindex: PropTypes__default["default"].number,
|
|
5607
5890
|
errorMessage: PropTypes__default["default"].string,
|
|
@@ -5641,6 +5924,8 @@ Select.propTypes = {
|
|
|
5641
5924
|
optionItemCursor: PropTypes__default["default"].string,
|
|
5642
5925
|
optionItemPadding: PropTypes__default["default"].string,
|
|
5643
5926
|
optionItemFontSize: PropTypes__default["default"].string,
|
|
5927
|
+
optionItemFontStyle: PropTypes__default["default"].string,
|
|
5928
|
+
optionItemFontFamily: PropTypes__default["default"].string,
|
|
5644
5929
|
optionItemMinHeight: PropTypes__default["default"].string,
|
|
5645
5930
|
optionItemBoxSizing: PropTypes__default["default"].string,
|
|
5646
5931
|
optionItemFontWeight: PropTypes__default["default"].string,
|
|
@@ -5650,7 +5935,8 @@ Select.propTypes = {
|
|
|
5650
5935
|
optionItemBackgroudColor: PropTypes__default["default"].string,
|
|
5651
5936
|
optionItemBackgroudColorHover: PropTypes__default["default"].string,
|
|
5652
5937
|
boxShadow: PropTypes__default["default"].string,
|
|
5653
|
-
boxShadowHover: PropTypes__default["default"].string
|
|
5938
|
+
boxShadowHover: PropTypes__default["default"].string,
|
|
5939
|
+
insidePagination: PropTypes__default["default"].bool
|
|
5654
5940
|
};
|
|
5655
5941
|
|
|
5656
5942
|
const SvgToasterInfo = ({
|
|
@@ -5772,9 +6058,9 @@ const SvgToasterSuccess = ({
|
|
|
5772
6058
|
fill: fillColor ? fillColor : '#0DA574'
|
|
5773
6059
|
}));
|
|
5774
6060
|
|
|
5775
|
-
var css_248z$
|
|
6061
|
+
var css_248z$8 = "#toaster-module_top-left__q0LcN{left:0;top:1em}#toaster-module_top-right__f-AFL{right:0;top:1em}#toaster-module_top-center__eVRbc{left:50%;top:1em;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}#toaster-module_bottom-left__b-YHI{bottom:1em;left:0}#toaster-module_bottom-right__g9ACP{bottom:1em;right:0}#toaster-module_bottom-center__4KcFe{bottom:1em;left:50%;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_top-left__q0LcN{left:0;top:1em}.toaster-module_top-right__f-AFL{right:0;top:1em}.toaster-module_top-center__eVRbc{left:50%;top:1em;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_bottom-left__b-YHI{bottom:1em;left:0}.toaster-module_bottom-right__g9ACP{bottom:1em;right:0}.toaster-module_bottom-center__4KcFe{bottom:1em;left:50%;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_notify-block__pRnEB{-webkit-animation-duration:.5s;animation-duration:.5s;-webkit-animation-fill-mode:both;animation-fill-mode:both}.toaster-module_bounce-in-right__shR2D{-webkit-animation-name:toaster-module_bounceInRight__rSk5p;animation-name:toaster-module_bounceInRight__rSk5p}.toaster-module_bounce-out-right__48pyA{-webkit-animation-name:toaster-module_bounceOutRight__bmFGS;animation-name:toaster-module_bounceOutRight__bmFGS}.toaster-module_notify-desc__bcWe2,.toaster-module_notify-title__8lFLy{overflow:hidden;text-overflow:ellipsis}.toaster-module_notify-desc__bcWe2{-webkit-box-orient:vertical;-webkit-line-clamp:2;display:-webkit-box}@keyframes toaster-module_bounceInRight__rSk5p{0%{opacity:0;right:-100%}60%{opacity:1;right:40px}75%{right:0}90%{right:30px}to{right:20px}}@keyframes toaster-module_bounceOutRight__bmFGS{0%{opacity:1;right:20px}60%{opacity:1;right:60px}to{opacity:0;right:-100%}}.toaster-module_bounce-in-left__xoF-M{-webkit-animation-name:toaster-module_bounceInLeft__to59v;animation-name:toaster-module_bounceInLeft__to59v}.toaster-module_bounce-out-left__fDOZw{-webkit-animation-name:toaster-module_bounceOutLeft__k5QgO;animation-name:toaster-module_bounceOutLeft__k5QgO}@keyframes toaster-module_bounceInLeft__to59v{0%{left:-100%;opacity:0}60%{left:40px;opacity:1}75%{left:0}90%{left:30px}to{left:20px}}@keyframes toaster-module_bounceInLeftMobile__CA2dc{0%{left:-100%;opacity:0}60%{left:40px;opacity:1}75%{left:0}90%{left:30px}to{left:0}}@keyframes toaster-module_bounceOutLeft__k5QgO{0%{left:20px;opacity:1}60%{left:60px;opacity:1}to{left:-100%;opacity:0}}@media(max-width:480px){.toaster-module_bounce-in-left__xoF-M{-webkit-animation-name:toaster-module_bounceInLeftMobile__CA2dc;animation-name:toaster-module_bounceInLeftMobile__CA2dc}}";
|
|
5776
6062
|
var styles$6 = {"top-left":"toaster-module_top-left__q0LcN","top-right":"toaster-module_top-right__f-AFL","top-center":"toaster-module_top-center__eVRbc","bottom-left":"toaster-module_bottom-left__b-YHI","bottom-right":"toaster-module_bottom-right__g9ACP","bottom-center":"toaster-module_bottom-center__4KcFe","notify-block":"toaster-module_notify-block__pRnEB","bounce-in-right":"toaster-module_bounce-in-right__shR2D","bounceInRight":"toaster-module_bounceInRight__rSk5p","bounce-out-right":"toaster-module_bounce-out-right__48pyA","bounceOutRight":"toaster-module_bounceOutRight__bmFGS","notify-title":"toaster-module_notify-title__8lFLy","notify-desc":"toaster-module_notify-desc__bcWe2","bounce-in-left":"toaster-module_bounce-in-left__xoF-M","bounceInLeft":"toaster-module_bounceInLeft__to59v","bounce-out-left":"toaster-module_bounce-out-left__fDOZw","bounceOutLeft":"toaster-module_bounceOutLeft__k5QgO","bounceInLeftMobile":"toaster-module_bounceInLeftMobile__CA2dc"};
|
|
5777
|
-
styleInject(css_248z$
|
|
6063
|
+
styleInject(css_248z$8);
|
|
5778
6064
|
|
|
5779
6065
|
const ToasterType = {
|
|
5780
6066
|
info: 'info',
|
|
@@ -6174,9 +6460,9 @@ const SvgTooltip = ({
|
|
|
6174
6460
|
fill: fillColor ? fillColor : '#D1D1D1'
|
|
6175
6461
|
}));
|
|
6176
6462
|
|
|
6177
|
-
var css_248z$
|
|
6463
|
+
var css_248z$7 = ".tooltip-module_tooltip-block__v8U9u{align-items:center;display:flex;justify-content:center;position:relative}.tooltip-module_tooltip__emM6A{box-sizing:border-box;padding:10px;position:absolute;z-index:1}.tooltip-module_tooltip-rel__to9gq{align-items:center;border-radius:5px;-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;-o-border-radius:5px;display:flex;height:auto;justify-content:center;min-height:10px;min-width:30px;position:relative;width:auto}.tooltip-module_tooltip-decor__qvt7t{border-radius:2px;-webkit-border-radius:2px;-moz-border-radius:2px;-ms-border-radius:2px;-o-border-radius:2px;height:10px;position:absolute;transform:rotate(45deg);-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);-o-transform:rotate(45deg);width:10px;z-index:-1}";
|
|
6178
6464
|
var styles$5 = {"tooltip-block":"tooltip-module_tooltip-block__v8U9u","tooltip":"tooltip-module_tooltip__emM6A","tooltip-rel":"tooltip-module_tooltip-rel__to9gq","tooltip-decor":"tooltip-module_tooltip-decor__qvt7t"};
|
|
6179
|
-
styleInject(css_248z$
|
|
6465
|
+
styleInject(css_248z$7);
|
|
6180
6466
|
|
|
6181
6467
|
const TooltipDirections = {
|
|
6182
6468
|
TOP: 'top',
|
|
@@ -6380,9 +6666,9 @@ const SvgCaptchaArrowDown = ({
|
|
|
6380
6666
|
fill: fillColor ? fillColor : '#00236A'
|
|
6381
6667
|
}));
|
|
6382
6668
|
|
|
6383
|
-
var css_248z$
|
|
6669
|
+
var css_248z$6 = ".captcha-module_start-point__LkOqy:after{background-color:#d1d1d1;border:2px solid #fff;border-radius:6px;-webkit-border-radius:6px;-moz-border-radius:6px;-ms-border-radius:6px;-o-border-radius:6px;content:\"\";height:10px;left:0;position:absolute;top:7.5px;width:10px;z-index:-1}.captcha-module_range__k24I2{-webkit-appearance:none;margin:0}.captcha-module_range__k24I2::-webkit-slider-runnable-track{-webkit-appearance:none;width:100%}.captcha-module_range-default__-O0QD::-webkit-slider-thumb{background-image:url(../../assets/range-arrow-default.svg)}.captcha-module_range-default__-O0QD::-webkit-slider-thumb,.captcha-module_range-error__FKMfG::-webkit-slider-thumb{-webkit-appearance:none;background-position:-5px;background-repeat:no-repeat;background-size:46px 46px;border-radius:17px;-webkit-border-radius:17px;-moz-border-radius:17px;-ms-border-radius:17px;-o-border-radius:17px;cursor:ew-resize;height:34px;width:34px}.captcha-module_range-error__FKMfG::-webkit-slider-thumb{background-image:url(../../assets/range-arrow-error.svg)}.captcha-module_range-success__VzLPq::-webkit-slider-thumb{-webkit-appearance:none;background-image:url(../../assets/range-arrow-success.svg);background-position:-5px;background-repeat:no-repeat;background-size:46px 46px;border-radius:17px;-webkit-border-radius:17px;-moz-border-radius:17px;-ms-border-radius:17px;-o-border-radius:17px;cursor:ew-resize;height:34px;width:34px}";
|
|
6384
6670
|
var styles$4 = {"start-point":"captcha-module_start-point__LkOqy","range":"captcha-module_range__k24I2","range-default":"captcha-module_range-default__-O0QD","range-error":"captcha-module_range-error__FKMfG","range-success":"captcha-module_range-success__VzLPq"};
|
|
6385
|
-
styleInject(css_248z$
|
|
6671
|
+
styleInject(css_248z$6);
|
|
6386
6672
|
|
|
6387
6673
|
const Captcha = ({
|
|
6388
6674
|
color,
|
|
@@ -6527,9 +6813,9 @@ Captcha.propTypes = {
|
|
|
6527
6813
|
getRange: PropTypes__default["default"].func.isRequired
|
|
6528
6814
|
};
|
|
6529
6815
|
|
|
6530
|
-
var css_248z$
|
|
6816
|
+
var css_248z$5 = ".stepper-module_stepper-container__-OVGy>div:last-child:before{display:none}.stepper-module_activeRing__Lzvh1,.stepper-module_bigRing__5GBm0{border-radius:50%;height:36px;margin-bottom:36px;position:relative;width:36px}.stepper-module_bigRing__5GBm0{box-shadow:0 0 0 2px #d1d1d1}.stepper-module_bigRing__5GBm0:before{background:#d1d1d1}.stepper-module_activeRing__Lzvh1{box-shadow:0 0 0 2px #00236a}.stepper-module_activeRing__Lzvh1:before{background:#00236a}.stepper-module_activeRing__Lzvh1:before,.stepper-module_bigRing__5GBm0:before{border-radius:20px;bottom:-32px;content:\"\";height:28px;left:0;margin:auto;overflow:hidden;position:absolute;right:0;width:2px}.stepper-module_smallActiveRing__im-XG,.stepper-module_smallRing__u-5a8{border-radius:50%;bottom:0;left:0;margin:auto;position:absolute;right:0;top:0}.stepper-module_smallRing__u-5a8{background-color:#d1d1d1;height:14px;width:14px}.stepper-module_smallActiveRing__im-XG{align-items:center;background-color:#00236a;color:#fff;display:flex;height:28px;justify-content:center;width:28px}";
|
|
6531
6817
|
var styles$3 = {"stepper-container":"stepper-module_stepper-container__-OVGy","bigRing":"stepper-module_bigRing__5GBm0","activeRing":"stepper-module_activeRing__Lzvh1","smallRing":"stepper-module_smallRing__u-5a8","smallActiveRing":"stepper-module_smallActiveRing__im-XG"};
|
|
6532
|
-
styleInject(css_248z$
|
|
6818
|
+
styleInject(css_248z$5);
|
|
6533
6819
|
|
|
6534
6820
|
const Stepper = ({
|
|
6535
6821
|
stepLength,
|
|
@@ -6692,8 +6978,8 @@ Checkbox.propTypes = {
|
|
|
6692
6978
|
data: PropTypes__default["default"].oneOfType([PropTypes__default["default"].arrayOf(PropTypes__default["default"].object), PropTypes__default["default"].object])
|
|
6693
6979
|
};
|
|
6694
6980
|
|
|
6695
|
-
var css_248z$
|
|
6696
|
-
styleInject(css_248z$
|
|
6981
|
+
var css_248z$4 = "textarea{-webkit-appearance:none}textarea::-webkit-scrollbar{width:6px}textarea::-webkit-scrollbar-track{background:#eee}textarea::-webkit-scrollbar-thumb,textarea::-webkit-scrollbar-track{border-radius:3px;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;-o-border-radius:3px}textarea::-webkit-scrollbar-thumb{background:#d1d1d1}";
|
|
6982
|
+
styleInject(css_248z$4);
|
|
6697
6983
|
|
|
6698
6984
|
const PositionSide = {
|
|
6699
6985
|
TOP: 'top',
|
|
@@ -6701,6 +6987,7 @@ const PositionSide = {
|
|
|
6701
6987
|
};
|
|
6702
6988
|
const Textarea = ({
|
|
6703
6989
|
size,
|
|
6990
|
+
name,
|
|
6704
6991
|
style,
|
|
6705
6992
|
family,
|
|
6706
6993
|
weight,
|
|
@@ -6762,25 +7049,26 @@ const Textarea = ({
|
|
|
6762
7049
|
};
|
|
6763
7050
|
const handleChange = e => {
|
|
6764
7051
|
const value = e.target.value;
|
|
6765
|
-
onChange
|
|
7052
|
+
if (onChange) {
|
|
7053
|
+
onChange(value);
|
|
7054
|
+
}
|
|
6766
7055
|
setInnerValue(() => value);
|
|
6767
7056
|
if (maxLength) {
|
|
6768
7057
|
if (value.length > maxLength) {
|
|
6769
|
-
onChange
|
|
7058
|
+
if (onChange) {
|
|
7059
|
+
onChange(value.substr(0, maxLength));
|
|
7060
|
+
}
|
|
6770
7061
|
setInnerValue(() => value.substr(0, maxLength));
|
|
6771
7062
|
}
|
|
6772
7063
|
} else {
|
|
6773
7064
|
if (value.length > configStyles.TEXTAREA.maxLength) {
|
|
6774
|
-
onChange
|
|
7065
|
+
if (onChange) {
|
|
7066
|
+
onChange(value.substr(0, configStyles.TEXTAREA.maxLength));
|
|
7067
|
+
}
|
|
6775
7068
|
setInnerValue(() => value.substr(0, configStyles.TEXTAREA.maxLength));
|
|
6776
7069
|
}
|
|
6777
7070
|
}
|
|
6778
7071
|
};
|
|
6779
|
-
React.useEffect(() => {
|
|
6780
|
-
if (!onChange) {
|
|
6781
|
-
alert('Please add onChange function on Textarea component');
|
|
6782
|
-
}
|
|
6783
|
-
}, [onChange]);
|
|
6784
7072
|
React.useEffect(() => {
|
|
6785
7073
|
if (value === undefined) {
|
|
6786
7074
|
alert('Please add value prop on Textarea component');
|
|
@@ -6827,7 +7115,7 @@ const Textarea = ({
|
|
|
6827
7115
|
style: {
|
|
6828
7116
|
display: labelDisplay ?? configStyles.TEXTAREA.label.display
|
|
6829
7117
|
}
|
|
6830
|
-
}, label, required && /*#__PURE__*/React__default["default"].createElement("sup", null, /*#__PURE__*/React__default["default"].createElement(SvgRequired, null))) : '', showCharacterCount && maxLength && characterCountPosition === 'top' && /*#__PURE__*/React__default["default"].createElement("span", null, maxLength -
|
|
7118
|
+
}, label, required && /*#__PURE__*/React__default["default"].createElement("sup", null, /*#__PURE__*/React__default["default"].createElement(SvgRequired, null))) : '', showCharacterCount && maxLength && characterCountPosition === 'top' && /*#__PURE__*/React__default["default"].createElement("span", null, maxLength - innerValue.length, " \u0576\u056B\u0577")), /*#__PURE__*/React__default["default"].createElement("textarea", {
|
|
6831
7119
|
style: {
|
|
6832
7120
|
width: '100%',
|
|
6833
7121
|
border: 'none',
|
|
@@ -6850,6 +7138,7 @@ const Textarea = ({
|
|
|
6850
7138
|
boxShadow: error ? errorColor ? `0 0 0 2px ${errorColor}` : configStyles.TEXTAREA.error.box.shadow : isFocus ? borderFocusColor ? `0 0 0 2px ${borderFocusColor}` : configStyles.TEXTAREA.box.colors.focus : isHover ? borderHoverColor ? `0 0 0 2px ${borderHoverColor}` : configStyles.TEXTAREA.box.colors.hover : boxShadow ? boxShadow : configStyles.INPUT.box.shadow,
|
|
6851
7139
|
resize: resize ? resize : configStyles.TEXTAREA.resize
|
|
6852
7140
|
},
|
|
7141
|
+
name: name,
|
|
6853
7142
|
value: innerValue,
|
|
6854
7143
|
disabled: disabled,
|
|
6855
7144
|
onBlur: handleBlur,
|
|
@@ -6889,6 +7178,7 @@ const Textarea = ({
|
|
|
6889
7178
|
};
|
|
6890
7179
|
Textarea.propTypes = {
|
|
6891
7180
|
size: PropTypes__default["default"].string,
|
|
7181
|
+
name: PropTypes__default["default"].string,
|
|
6892
7182
|
style: PropTypes__default["default"].string,
|
|
6893
7183
|
family: PropTypes__default["default"].string,
|
|
6894
7184
|
weight: PropTypes__default["default"].string,
|
|
@@ -6899,6 +7189,7 @@ Textarea.propTypes = {
|
|
|
6899
7189
|
radius: PropTypes__default["default"].string,
|
|
6900
7190
|
required: PropTypes__default["default"].bool,
|
|
6901
7191
|
disabled: PropTypes__default["default"].bool,
|
|
7192
|
+
onChange: PropTypes__default["default"].func,
|
|
6902
7193
|
padding: PropTypes__default["default"].string,
|
|
6903
7194
|
minWidth: PropTypes__default["default"].string,
|
|
6904
7195
|
maxWidth: PropTypes__default["default"].string,
|
|
@@ -6927,10 +7218,304 @@ Textarea.propTypes = {
|
|
|
6927
7218
|
borderFocusColor: PropTypes__default["default"].string,
|
|
6928
7219
|
borderHoverColor: PropTypes__default["default"].string,
|
|
6929
7220
|
labelMarginBottom: PropTypes__default["default"].string,
|
|
6930
|
-
onChange: PropTypes__default["default"].func.isRequired,
|
|
6931
7221
|
characterCountPosition: PropTypes__default["default"].oneOf(Object.values(PositionSide))
|
|
6932
7222
|
};
|
|
6933
7223
|
|
|
7224
|
+
const AccordionItem = ({
|
|
7225
|
+
item,
|
|
7226
|
+
open,
|
|
7227
|
+
index,
|
|
7228
|
+
onClick,
|
|
7229
|
+
openIcon,
|
|
7230
|
+
closeIcon,
|
|
7231
|
+
showIcons,
|
|
7232
|
+
className,
|
|
7233
|
+
titleAlign,
|
|
7234
|
+
multipleOpen,
|
|
7235
|
+
openHoverIcon,
|
|
7236
|
+
color,
|
|
7237
|
+
border,
|
|
7238
|
+
padding,
|
|
7239
|
+
fontSize,
|
|
7240
|
+
fontStyle,
|
|
7241
|
+
fontWeight,
|
|
7242
|
+
fontFamily,
|
|
7243
|
+
borderTop,
|
|
7244
|
+
borderLeft,
|
|
7245
|
+
hoverColor,
|
|
7246
|
+
borderRight,
|
|
7247
|
+
borderRadius,
|
|
7248
|
+
borderBottom,
|
|
7249
|
+
marginBottom,
|
|
7250
|
+
backgroundColor,
|
|
7251
|
+
backgroundHoverColor
|
|
7252
|
+
}) => {
|
|
7253
|
+
const [isOpen, setIsOpen] = React.useState(false);
|
|
7254
|
+
const [isHover, setIsHover] = React.useState(false);
|
|
7255
|
+
const handleClick = () => {
|
|
7256
|
+
onClick(item, index);
|
|
7257
|
+
if (multipleOpen) {
|
|
7258
|
+
setIsOpen(() => !isOpen);
|
|
7259
|
+
}
|
|
7260
|
+
};
|
|
7261
|
+
const handleMouseEnter = () => {
|
|
7262
|
+
setIsHover(() => true);
|
|
7263
|
+
};
|
|
7264
|
+
const handleMouseLeave = () => {
|
|
7265
|
+
setIsHover(() => false);
|
|
7266
|
+
};
|
|
7267
|
+
React.useEffect(() => {
|
|
7268
|
+
setIsOpen(() => open);
|
|
7269
|
+
}, [open]);
|
|
7270
|
+
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7271
|
+
className: className,
|
|
7272
|
+
style: {
|
|
7273
|
+
marginBottom: marginBottom ? marginBottom : '0px'
|
|
7274
|
+
}
|
|
7275
|
+
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7276
|
+
onClick: handleClick,
|
|
7277
|
+
onMouseEnter: handleMouseEnter,
|
|
7278
|
+
onMouseLeave: handleMouseLeave,
|
|
7279
|
+
style: {
|
|
7280
|
+
display: 'flex',
|
|
7281
|
+
cursor: 'pointer',
|
|
7282
|
+
padding: padding,
|
|
7283
|
+
alignItems: 'center',
|
|
7284
|
+
borderRadius: borderRadius,
|
|
7285
|
+
borderTop: borderTop ? border : 'none',
|
|
7286
|
+
borderLeft: borderLeft ? border : 'none',
|
|
7287
|
+
borderRight: borderRight ? border : 'none',
|
|
7288
|
+
borderBottom: borderBottom ? border : 'none',
|
|
7289
|
+
justifyContent: showIcons ? 'space-between' : 'flex-start',
|
|
7290
|
+
backgroundColor: isHover ? backgroundHoverColor : backgroundColor
|
|
7291
|
+
}
|
|
7292
|
+
}, item.title && /*#__PURE__*/React__default["default"].createElement("p", {
|
|
7293
|
+
style: {
|
|
7294
|
+
width: '90%',
|
|
7295
|
+
margin: '0px',
|
|
7296
|
+
fontSize: fontSize,
|
|
7297
|
+
overflow: 'hidden',
|
|
7298
|
+
whiteSpace: 'nowrap',
|
|
7299
|
+
fontStyle: fontStyle,
|
|
7300
|
+
fontWeight: fontWeight,
|
|
7301
|
+
fontFamily: fontFamily,
|
|
7302
|
+
textOverflow: 'ellipsis',
|
|
7303
|
+
textAlign: titleAlign ? titleAlign : 'left',
|
|
7304
|
+
color: isOpen ? hoverColor : isHover ? hoverColor : color
|
|
7305
|
+
}
|
|
7306
|
+
}, item.title), showIcons && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7307
|
+
style: {
|
|
7308
|
+
display: 'flex',
|
|
7309
|
+
width: 'fit-content',
|
|
7310
|
+
height: 'fit-content',
|
|
7311
|
+
minWidth: '14px',
|
|
7312
|
+
minHeight: '14px',
|
|
7313
|
+
alignItems: 'center',
|
|
7314
|
+
justifyContent: 'center'
|
|
7315
|
+
}
|
|
7316
|
+
}, isOpen ? closeIcon : isHover ? openHoverIcon ? openHoverIcon : openIcon : openIcon)), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7317
|
+
style: {
|
|
7318
|
+
overflow: 'hidden',
|
|
7319
|
+
height: isOpen ? 'auto' : '0px'
|
|
7320
|
+
}
|
|
7321
|
+
}, item.content ? item.content : ''));
|
|
7322
|
+
};
|
|
7323
|
+
AccordionItem.propTypes = {
|
|
7324
|
+
open: PropTypes__default["default"].bool
|
|
7325
|
+
};
|
|
7326
|
+
|
|
7327
|
+
const SvgGreenplus = ({
|
|
7328
|
+
title,
|
|
7329
|
+
titleId,
|
|
7330
|
+
...props
|
|
7331
|
+
}) => /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
7332
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7333
|
+
width: "1em",
|
|
7334
|
+
height: "1em",
|
|
7335
|
+
fill: "none",
|
|
7336
|
+
viewBox: "0 0 16 16",
|
|
7337
|
+
"aria-labelledby": titleId
|
|
7338
|
+
}, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
|
|
7339
|
+
id: titleId
|
|
7340
|
+
}, title) : null, /*#__PURE__*/React__namespace.createElement("path", {
|
|
7341
|
+
stroke: "#009B8B",
|
|
7342
|
+
strokeLinecap: "round",
|
|
7343
|
+
strokeLinejoin: "round",
|
|
7344
|
+
strokeWidth: 1.6,
|
|
7345
|
+
d: "M8 1v14M1 8h14"
|
|
7346
|
+
}));
|
|
7347
|
+
|
|
7348
|
+
const SvgGreenminus = ({
|
|
7349
|
+
title,
|
|
7350
|
+
titleId,
|
|
7351
|
+
...props
|
|
7352
|
+
}) => /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
7353
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7354
|
+
width: "1em",
|
|
7355
|
+
height: "1em",
|
|
7356
|
+
fill: "none",
|
|
7357
|
+
viewBox: "0 0 16 2",
|
|
7358
|
+
"aria-labelledby": titleId
|
|
7359
|
+
}, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
|
|
7360
|
+
id: titleId
|
|
7361
|
+
}, title) : null, /*#__PURE__*/React__namespace.createElement("path", {
|
|
7362
|
+
stroke: "#009B8B",
|
|
7363
|
+
strokeLinecap: "round",
|
|
7364
|
+
strokeLinejoin: "round",
|
|
7365
|
+
strokeWidth: 1.6,
|
|
7366
|
+
d: "M1 1h14"
|
|
7367
|
+
}));
|
|
7368
|
+
|
|
7369
|
+
var css_248z$3 = "";
|
|
7370
|
+
styleInject(css_248z$3);
|
|
7371
|
+
|
|
7372
|
+
const Accordion = ({
|
|
7373
|
+
data,
|
|
7374
|
+
click,
|
|
7375
|
+
openIcon,
|
|
7376
|
+
closeIcon,
|
|
7377
|
+
className,
|
|
7378
|
+
showIcons,
|
|
7379
|
+
titleAlign,
|
|
7380
|
+
multipleOpen,
|
|
7381
|
+
openHoverIcon,
|
|
7382
|
+
borderTop,
|
|
7383
|
+
borderLeft,
|
|
7384
|
+
borderRight,
|
|
7385
|
+
borderColor,
|
|
7386
|
+
borderWidth,
|
|
7387
|
+
borderStyle,
|
|
7388
|
+
borderBottom,
|
|
7389
|
+
borderRadius,
|
|
7390
|
+
fontSize,
|
|
7391
|
+
fontStyle,
|
|
7392
|
+
fontWeight,
|
|
7393
|
+
fontFamily,
|
|
7394
|
+
color,
|
|
7395
|
+
padding,
|
|
7396
|
+
hoverColor,
|
|
7397
|
+
marginBottom,
|
|
7398
|
+
backgroundColor,
|
|
7399
|
+
backgroundHoverColor
|
|
7400
|
+
}) => {
|
|
7401
|
+
const [openIndex, setOpenIndex] = React.useState(-1);
|
|
7402
|
+
const [classProps, setClassProps] = React.useState({});
|
|
7403
|
+
const [configStyles, setConfigStyles] = React.useState({});
|
|
7404
|
+
const handleClick = (item, index) => {
|
|
7405
|
+
if (click) {
|
|
7406
|
+
click(item);
|
|
7407
|
+
}
|
|
7408
|
+
if (!multipleOpen) {
|
|
7409
|
+
setOpenIndex(() => openIndex === index ? -1 : index);
|
|
7410
|
+
}
|
|
7411
|
+
};
|
|
7412
|
+
React.useEffect(() => {
|
|
7413
|
+
className && setClassProps(() => classnames__default["default"](className ?? configStyles.BUTTON.className));
|
|
7414
|
+
}, [className]);
|
|
7415
|
+
React.useEffect(() => {
|
|
7416
|
+
configStylesPromise.then(data => {
|
|
7417
|
+
setClassProps(() => classnames__default["default"](className ?? data.BUTTON.className));
|
|
7418
|
+
setConfigStyles(() => {
|
|
7419
|
+
return {
|
|
7420
|
+
...data
|
|
7421
|
+
};
|
|
7422
|
+
});
|
|
7423
|
+
}, error => {
|
|
7424
|
+
console.error(error);
|
|
7425
|
+
});
|
|
7426
|
+
}, []);
|
|
7427
|
+
return configStyles.ACCORDION && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7428
|
+
style: {
|
|
7429
|
+
width: '100%'
|
|
7430
|
+
}
|
|
7431
|
+
}, data && data.length ? data.map((item, index) => {
|
|
7432
|
+
return /*#__PURE__*/React__default["default"].createElement(AccordionItem, {
|
|
7433
|
+
item: item,
|
|
7434
|
+
index: index,
|
|
7435
|
+
onClick: handleClick,
|
|
7436
|
+
titleAlign: titleAlign,
|
|
7437
|
+
multipleOpen: multipleOpen,
|
|
7438
|
+
key: `${item.title}__TUI__${index}`,
|
|
7439
|
+
open: openIndex === index ? true : false,
|
|
7440
|
+
showIcons: showIcons ?? configStyles.ACCORDION.showIcons,
|
|
7441
|
+
openIcon: openIcon ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7442
|
+
src: openIcon,
|
|
7443
|
+
alt: "open icon"
|
|
7444
|
+
}) : configStyles.ACCORDION.icon.open ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7445
|
+
src: configStyles.ACCORDION.icon.open,
|
|
7446
|
+
alt: "open icon"
|
|
7447
|
+
}) : /*#__PURE__*/React__default["default"].createElement(SvgGreenplus, null),
|
|
7448
|
+
openHoverIcon: openHoverIcon ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7449
|
+
src: openHoverIcon,
|
|
7450
|
+
alt: "open icon"
|
|
7451
|
+
}) : configStyles.ACCORDION.icon.openHover ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7452
|
+
src: configStyles.ACCORDION.icon.openHover,
|
|
7453
|
+
alt: "open icon"
|
|
7454
|
+
}) : /*#__PURE__*/React__default["default"].createElement(SvgGreenplus, null),
|
|
7455
|
+
closeIcon: closeIcon ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7456
|
+
src: closeIcon,
|
|
7457
|
+
alt: "close icon"
|
|
7458
|
+
}) : configStyles.ACCORDION.icon.close ? /*#__PURE__*/React__default["default"].createElement("img", {
|
|
7459
|
+
src: configStyles.ACCORDION.icon.close,
|
|
7460
|
+
alt: "close icon"
|
|
7461
|
+
}) : /*#__PURE__*/React__default["default"].createElement(SvgGreenminus, null),
|
|
7462
|
+
className: classProps,
|
|
7463
|
+
color: color ?? configStyles.ACCORDION.color,
|
|
7464
|
+
padding: padding ?? configStyles.ACCORDION.padding,
|
|
7465
|
+
fontSize: fontSize ?? configStyles.ACCORDION.font.size,
|
|
7466
|
+
fontStyle: fontStyle ?? configStyles.ACCORDION.font.style,
|
|
7467
|
+
fontWeight: fontWeight ?? configStyles.ACCORDION.font.weight,
|
|
7468
|
+
fontFamily: fontFamily ?? configStyles.ACCORDION.font.family,
|
|
7469
|
+
hoverColor: hoverColor ?? configStyles.ACCORDION.colors.hover,
|
|
7470
|
+
marginBottom: marginBottom ?? configStyles.ACCORDION.marginBottom,
|
|
7471
|
+
border: `
|
|
7472
|
+
${borderWidth ?? configStyles.ACCORDION.border.width}
|
|
7473
|
+
${borderStyle ?? configStyles.ACCORDION.border.style}
|
|
7474
|
+
${openIndex === index ? 'transparent' : borderColor ?? configStyles.ACCORDION.border.color}
|
|
7475
|
+
`,
|
|
7476
|
+
borderTop: borderTop ?? configStyles.ACCORDION.border.top,
|
|
7477
|
+
borderLeft: borderLeft ?? configStyles.ACCORDION.border.left,
|
|
7478
|
+
borderRight: borderRight ?? configStyles.ACCORDION.border.right,
|
|
7479
|
+
borderBottom: borderBottom ?? configStyles.ACCORDION.border.bottom,
|
|
7480
|
+
borderRadius: borderRadius ?? configStyles.ACCORDION.border.radius,
|
|
7481
|
+
backgroundColor: backgroundColor ?? configStyles.ACCORDION.colors.background,
|
|
7482
|
+
backgroundHoverColor: backgroundHoverColor ?? configStyles.ACCORDION.colors.backgroundHover
|
|
7483
|
+
});
|
|
7484
|
+
}) : '');
|
|
7485
|
+
};
|
|
7486
|
+
Accordion.propTypes = {
|
|
7487
|
+
data: PropTypes__default["default"].arrayOf(PropTypes__default["default"].shape({
|
|
7488
|
+
title: PropTypes__default["default"].string,
|
|
7489
|
+
content: PropTypes__default["default"].element
|
|
7490
|
+
})),
|
|
7491
|
+
click: PropTypes__default["default"].func,
|
|
7492
|
+
showIcons: PropTypes__default["default"].bool,
|
|
7493
|
+
multipleOpen: PropTypes__default["default"].bool,
|
|
7494
|
+
color: PropTypes__default["default"].string,
|
|
7495
|
+
hoverColor: PropTypes__default["default"].string,
|
|
7496
|
+
backgroundColor: PropTypes__default["default"].string,
|
|
7497
|
+
backgroundHoverColor: PropTypes__default["default"].string,
|
|
7498
|
+
titleAlign: PropTypes__default["default"].oneOf(['left', 'center', 'right']),
|
|
7499
|
+
padding: PropTypes__default["default"].string,
|
|
7500
|
+
openIcon: PropTypes__default["default"].string,
|
|
7501
|
+
className: PropTypes__default["default"].string,
|
|
7502
|
+
closeIcon: PropTypes__default["default"].string,
|
|
7503
|
+
marginBottom: PropTypes__default["default"].string,
|
|
7504
|
+
openHoverIcon: PropTypes__default["default"].string,
|
|
7505
|
+
borderTop: PropTypes__default["default"].bool,
|
|
7506
|
+
borderLeft: PropTypes__default["default"].bool,
|
|
7507
|
+
borderRight: PropTypes__default["default"].bool,
|
|
7508
|
+
borderBottom: PropTypes__default["default"].bool,
|
|
7509
|
+
borderColor: PropTypes__default["default"].string,
|
|
7510
|
+
borderWidth: PropTypes__default["default"].string,
|
|
7511
|
+
borderStyle: PropTypes__default["default"].string,
|
|
7512
|
+
borderRadius: PropTypes__default["default"].string,
|
|
7513
|
+
fontSize: PropTypes__default["default"].string,
|
|
7514
|
+
fontStyle: PropTypes__default["default"].string,
|
|
7515
|
+
fontWeight: PropTypes__default["default"].number,
|
|
7516
|
+
fontFamily: PropTypes__default["default"].string
|
|
7517
|
+
};
|
|
7518
|
+
|
|
6934
7519
|
const Swipe = ({
|
|
6935
7520
|
id,
|
|
6936
7521
|
title,
|
|
@@ -6952,8 +7537,8 @@ const Swipe = ({
|
|
|
6952
7537
|
} = props || {};
|
|
6953
7538
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
6954
7539
|
style: {
|
|
6955
|
-
width:
|
|
6956
|
-
height:
|
|
7540
|
+
width: '100%',
|
|
7541
|
+
height: '100%'
|
|
6957
7542
|
}
|
|
6958
7543
|
}, (title || showCloseIcon) && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
6959
7544
|
style: {
|
|
@@ -7022,11 +7607,11 @@ const createElem = (id, title, child, props, swipeBlock, innerConfigStyles) => {
|
|
|
7022
7607
|
borderRadius,
|
|
7023
7608
|
backgroundColor
|
|
7024
7609
|
} = props || {};
|
|
7025
|
-
swipeBlock.style.position = '
|
|
7610
|
+
swipeBlock.style.position = 'absolute';
|
|
7026
7611
|
swipeBlock.style.zIndex = swipeCount;
|
|
7027
7612
|
swipeBlock.style.backgroundColor = backgroundColor ?? innerConfigStyles.SWIPEMODAL.colors.background;
|
|
7028
7613
|
swipeBlock.style.width = position === 'left' || position === 'right' ? width ?? innerConfigStyles.SWIPEMODAL.width : '100%';
|
|
7029
|
-
swipeBlock.style.height = position === 'top' || position === 'bottom' ? height ?? innerConfigStyles.SWIPEMODAL.height : '
|
|
7614
|
+
swipeBlock.style.height = position === 'top' || position === 'bottom' ? height ?? innerConfigStyles.SWIPEMODAL.height : '100%';
|
|
7030
7615
|
swipeBlock.style.borderTopLeftRadius = position === 'right' || position === 'bottom' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
7031
7616
|
swipeBlock.style.borderTopRightRadius = position === 'left' || position === 'bottom' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
7032
7617
|
swipeBlock.style.borderBottomLeftRadius = position === 'right' || position === 'top' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
@@ -7060,26 +7645,25 @@ const createSwipe = (id, title, child, props, swipable) => {
|
|
|
7060
7645
|
};
|
|
7061
7646
|
createElem(id, title, child, props, swipeBlock, innerConfigStyles);
|
|
7062
7647
|
if (!swipable) {
|
|
7063
|
-
const widthParent = hasOwnerProperty(props, 'withParent') ? props.withParent === true ? true : false : innerConfigStyles.SWIPEMODAL.withParent;
|
|
7064
7648
|
swipable = document.createElement('div');
|
|
7065
7649
|
swipable.setAttribute('id', 'swipable');
|
|
7066
|
-
swipable.style.position = '
|
|
7650
|
+
swipable.style.position = 'absolute';
|
|
7067
7651
|
swipable.style.top = '0px';
|
|
7068
7652
|
swipable.style.left = '0px';
|
|
7069
7653
|
swipable.style.zIndex = 99999;
|
|
7070
7654
|
swipable.style.maxWidth = '100%';
|
|
7071
7655
|
swipable.style.maxHeight = '100vh';
|
|
7072
|
-
swipable.style.
|
|
7073
|
-
swipable.style.
|
|
7074
|
-
swipable.style.height = widthParent ? '100vh' : '0px';
|
|
7656
|
+
swipable.style.width = '100%';
|
|
7657
|
+
swipable.style.height = '100%';
|
|
7075
7658
|
swipable.style.backgroundColor = props?.parent?.backgroundColor ?? innerConfigStyles.SWIPEMODAL.parent.colors.background;
|
|
7076
|
-
swipable.classList.add(styles$2['visible']);
|
|
7077
7659
|
if (props.outSideClose || innerConfigStyles.SWIPEMODAL.outSideClose) {
|
|
7078
7660
|
swipable.addEventListener('click', function () {
|
|
7079
7661
|
hasOwnerProperty(props, 'callClose') && {}.toString.call(props.callClose) === '[object Function]' ? props.callClose() : '';
|
|
7080
7662
|
});
|
|
7081
7663
|
}
|
|
7082
|
-
document.
|
|
7664
|
+
const SwipifyBlock = document.getElementById('swipify_tui');
|
|
7665
|
+
SwipifyBlock.style.display = 'block';
|
|
7666
|
+
SwipifyBlock.appendChild(swipable);
|
|
7083
7667
|
}
|
|
7084
7668
|
swipable.appendChild(swipeBlock);
|
|
7085
7669
|
}, error => {
|
|
@@ -7128,7 +7712,6 @@ const swipe = {
|
|
|
7128
7712
|
close: id => {
|
|
7129
7713
|
if (id === undefined || id === null && (typeof id !== 'string' || typeof id !== 'number')) {
|
|
7130
7714
|
alert('Please pass valid id prop (string / number) when call swipe.close function');
|
|
7131
|
-
return;
|
|
7132
7715
|
}
|
|
7133
7716
|
let swipable = document.getElementById('swipable');
|
|
7134
7717
|
swipeCount -= 1;
|
|
@@ -7143,7 +7726,9 @@ const swipe = {
|
|
|
7143
7726
|
if (swipeCount === 0 && swipable) {
|
|
7144
7727
|
window.removeEventListener('popstate', handleNavigationChange);
|
|
7145
7728
|
window.removeEventListener('navigationchange', handleNavigationChange);
|
|
7146
|
-
document.
|
|
7729
|
+
const SwipifyBlock = document.getElementById('swipify_tui');
|
|
7730
|
+
SwipifyBlock.style.display = 'none';
|
|
7731
|
+
SwipifyBlock.removeChild(swipable);
|
|
7147
7732
|
}
|
|
7148
7733
|
}, 200);
|
|
7149
7734
|
} else {
|
|
@@ -7151,14 +7736,42 @@ const swipe = {
|
|
|
7151
7736
|
if (swipeCount === 0 && swipable) {
|
|
7152
7737
|
window.removeEventListener('popstate', handleNavigationChange);
|
|
7153
7738
|
window.removeEventListener('navigationchange', handleNavigationChange);
|
|
7154
|
-
document.
|
|
7739
|
+
const SwipifyBlock = document.getElementById('swipify_tui');
|
|
7740
|
+
SwipifyBlock.style.display = 'none';
|
|
7741
|
+
SwipifyBlock.removeChild(swipable);
|
|
7155
7742
|
}
|
|
7156
7743
|
}
|
|
7744
|
+
} else {
|
|
7745
|
+
if (swipeCount === 0 && swipable) {
|
|
7746
|
+
const SwipifyBlock = document.getElementById('swipify_tui');
|
|
7747
|
+
SwipifyBlock.style.display = 'none';
|
|
7748
|
+
SwipifyBlock.removeChild(swipable);
|
|
7749
|
+
}
|
|
7157
7750
|
}
|
|
7158
7751
|
}
|
|
7159
7752
|
};
|
|
7160
7753
|
const SwipeModal = () => {
|
|
7161
|
-
|
|
7754
|
+
const ref = React.useRef(null);
|
|
7755
|
+
React.useEffect(() => {
|
|
7756
|
+
const parentSize = ref.current.parentNode.style.height;
|
|
7757
|
+
if (Number(parentSize.replace(/\D/g, '')) > 0) {
|
|
7758
|
+
ref.current.style.height = '100%';
|
|
7759
|
+
} else {
|
|
7760
|
+
ref.current.style.height = '100vh';
|
|
7761
|
+
}
|
|
7762
|
+
}, [ref]);
|
|
7763
|
+
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7764
|
+
ref: ref,
|
|
7765
|
+
id: "swipify_tui",
|
|
7766
|
+
style: {
|
|
7767
|
+
position: 'absolute',
|
|
7768
|
+
width: '100%',
|
|
7769
|
+
top: 0,
|
|
7770
|
+
overflow: 'hidden',
|
|
7771
|
+
zIndex: 1,
|
|
7772
|
+
display: 'none'
|
|
7773
|
+
}
|
|
7774
|
+
});
|
|
7162
7775
|
};
|
|
7163
7776
|
|
|
7164
7777
|
const TypographyType = {
|
|
@@ -7277,13 +7890,13 @@ const range = (start, end) => {
|
|
|
7277
7890
|
}, (_, idx) => idx + start);
|
|
7278
7891
|
};
|
|
7279
7892
|
const PaginationRange = ({
|
|
7280
|
-
|
|
7893
|
+
innerOffset,
|
|
7281
7894
|
currentTotalCount,
|
|
7282
7895
|
currentPageNumber
|
|
7283
7896
|
}) => {
|
|
7284
7897
|
const paginationRange = React.useMemo(() => {
|
|
7285
7898
|
const firstPageIndex = 1;
|
|
7286
|
-
const totalPageCount = Math.ceil(currentTotalCount /
|
|
7899
|
+
const totalPageCount = Math.ceil(currentTotalCount / innerOffset);
|
|
7287
7900
|
const lastPageIndex = totalPageCount;
|
|
7288
7901
|
if (7 >= totalPageCount) {
|
|
7289
7902
|
return range(1, totalPageCount);
|
|
@@ -7306,14 +7919,10 @@ const PaginationRange = ({
|
|
|
7306
7919
|
} else {
|
|
7307
7920
|
return range(firstPageIndex, totalPageCount);
|
|
7308
7921
|
}
|
|
7309
|
-
}, [currentTotalCount,
|
|
7922
|
+
}, [currentTotalCount, innerOffset, currentPageNumber]);
|
|
7310
7923
|
return paginationRange;
|
|
7311
7924
|
};
|
|
7312
7925
|
|
|
7313
|
-
var css_248z$1 = ".pagination-module_listItem__b1-WN:focus{background-color:#4caf50;color:#fff}.pagination-module_listItem__b1-WN:hover:not(.pagination-module_active__KwBDp){background-color:#ddd}.pagination-module_pagination-bar__MrtYT>ul{display:flex;flex-direction:row;flex-wrap:nowrap;gap:8px;justify-content:center}.pagination-module_pagination-btn__w8Yh8{border:none;border-radius:6px;outline:none}.pagination-module_pagination-btn__w8Yh8,.pagination-module_pagination-item__t3emS,.pagination-module_pagination-jump-next__LAb9Z{align-items:center;background-color:#fff;box-shadow:0 0 0 1px #eee;cursor:pointer;display:flex;height:34px;justify-content:center;width:34px}.pagination-module_pagination-item__t3emS,.pagination-module_pagination-jump-next__LAb9Z{border-radius:6px;flex:0 0 auto;font-size:13px;line-height:16px;position:relative;transition:background-color .24s}.pagination-module_pagination-item__t3emS:hover{background-color:#eee}.pagination-module_pagination-item__t3emS.pagination-module_selected__EXzCA{background-color:#00236a;color:#fff}.pagination-module_pagination-jump-next-arrow__aEVD8,.pagination-module_pagination-jump-next-txt__e7nFj{align-items:center;bottom:0;display:flex;font-size:12px;justify-content:center;left:0;line-height:14px;margin:auto;position:absolute;right:0;top:0;transition:opacity .24s,color .24s}.pagination-module_pagination-jump-next-arrow__aEVD8{opacity:0}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-arrow__aEVD8{opacity:1}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-txt__e7nFj{opacity:0}i{color:#3c393e;font-size:12px;line-height:12px}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}";
|
|
7314
|
-
var styles$1 = {"listItem":"pagination-module_listItem__b1-WN","active":"pagination-module_active__KwBDp","pagination-bar":"pagination-module_pagination-bar__MrtYT","pagination-btn":"pagination-module_pagination-btn__w8Yh8","pagination-item":"pagination-module_pagination-item__t3emS","pagination-jump-next":"pagination-module_pagination-jump-next__LAb9Z","selected":"pagination-module_selected__EXzCA","pagination-jump-next-txt":"pagination-module_pagination-jump-next-txt__e7nFj","pagination-jump-next-arrow":"pagination-module_pagination-jump-next-arrow__aEVD8"};
|
|
7315
|
-
styleInject(css_248z$1);
|
|
7316
|
-
|
|
7317
7926
|
const SvgDots = ({
|
|
7318
7927
|
title,
|
|
7319
7928
|
titleId,
|
|
@@ -7352,57 +7961,51 @@ const SvgNextarrow = ({
|
|
|
7352
7961
|
fill: fillColor ? fillColor : '#3C393E'
|
|
7353
7962
|
}));
|
|
7354
7963
|
|
|
7964
|
+
var css_248z$1 = ".pagination-module_listItem__b1-WN:focus{background-color:#4caf50;color:#fff}.pagination-module_listItem__b1-WN:hover:not(.pagination-module_active__KwBDp){background-color:#ddd}.pagination-module_pagination-bar__MrtYT>ul{display:flex;flex-direction:row;flex-wrap:nowrap;gap:8px;justify-content:center}.pagination-module_pagination-btn__w8Yh8{align-items:center;border:none;cursor:pointer;display:flex;justify-content:center;outline:none}.pagination-module_pagination-item__t3emS,.pagination-module_pagination-jump-next__LAb9Z{align-items:center;cursor:pointer;display:flex;flex:0 0 auto;justify-content:center;position:relative;transition:background-color .24s}.pagination-module_pagination-item__t3emS:hover{background-color:#eee}.pagination-module_pagination-item__t3emS.pagination-module_selected__EXzCA{background-color:#00236a;color:#fff}.pagination-module_pagination-jump-next-arrow__aEVD8,.pagination-module_pagination-jump-next-txt__e7nFj{align-items:center;bottom:0;display:flex;font-size:12px;justify-content:center;left:0;line-height:14px;margin:auto;position:absolute;right:0;top:0;transition:opacity .24s,color .24s}.pagination-module_pagination-jump-next-arrow__aEVD8{opacity:0}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-arrow__aEVD8{opacity:1}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-txt__e7nFj{opacity:0}.pagination-module_show-offset-block__ksPGm{height:34px;margin-left:10px!important;margin-right:4px!important;width:91px}i{color:#3c393e;font-size:12px;line-height:12px}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}";
|
|
7965
|
+
var styles$1 = {"listItem":"pagination-module_listItem__b1-WN","active":"pagination-module_active__KwBDp","pagination-bar":"pagination-module_pagination-bar__MrtYT","pagination-btn":"pagination-module_pagination-btn__w8Yh8","pagination-item":"pagination-module_pagination-item__t3emS","pagination-jump-next":"pagination-module_pagination-jump-next__LAb9Z","selected":"pagination-module_selected__EXzCA","pagination-jump-next-txt":"pagination-module_pagination-jump-next-txt__e7nFj","pagination-jump-next-arrow":"pagination-module_pagination-jump-next-arrow__aEVD8","show-offset-block":"pagination-module_show-offset-block__ksPGm"};
|
|
7966
|
+
styleInject(css_248z$1);
|
|
7967
|
+
|
|
7355
7968
|
const Pagination = ({
|
|
7356
7969
|
goTo,
|
|
7357
|
-
offset
|
|
7970
|
+
offset,
|
|
7358
7971
|
onChange,
|
|
7359
7972
|
className,
|
|
7973
|
+
getOffset,
|
|
7360
7974
|
totalCount,
|
|
7361
|
-
|
|
7975
|
+
showOffset,
|
|
7976
|
+
currentPage,
|
|
7977
|
+
offsetCounts,
|
|
7978
|
+
color,
|
|
7979
|
+
width,
|
|
7980
|
+
height,
|
|
7981
|
+
fontSize,
|
|
7982
|
+
fontStyle,
|
|
7983
|
+
fontWeight,
|
|
7984
|
+
fontFamily,
|
|
7985
|
+
lineHeight,
|
|
7986
|
+
activeColor,
|
|
7987
|
+
hoverColor,
|
|
7988
|
+
backgroundColor,
|
|
7989
|
+
hoverBackgroundColor,
|
|
7990
|
+
activeBackgroundColor,
|
|
7991
|
+
borderColor,
|
|
7992
|
+
borderWidth,
|
|
7993
|
+
borderRadius
|
|
7362
7994
|
}) => {
|
|
7363
7995
|
const [inpVal, setInpVal] = React.useState('');
|
|
7364
7996
|
const [error, setError] = React.useState(false);
|
|
7997
|
+
const [isHover, setIsHover] = React.useState(false);
|
|
7365
7998
|
const [classProps, setClassProps] = React.useState({});
|
|
7999
|
+
const [offsetArgs, setOffsetArgs] = React.useState({});
|
|
8000
|
+
const [innerOffset, setInnerOffset] = React.useState(2);
|
|
7366
8001
|
const [configStyles, setConfigStyles] = React.useState({});
|
|
8002
|
+
const [innerShowOffset, setInnerShowOffset] = React.useState(false);
|
|
7367
8003
|
const [currentPageNumber, setCurrentPage] = React.useState(currentPage);
|
|
7368
8004
|
const [currentTotalCount, setcurrentTotalCount] = React.useState(totalCount);
|
|
7369
|
-
React.useEffect(() => {
|
|
7370
|
-
configStylesPromise.then(data => {
|
|
7371
|
-
setClassProps(() => classnames__default["default"](
|
|
7372
|
-
// TODO: check and remove pagination-bar-rem class
|
|
7373
|
-
styles$1.list, className ?? data.PAGINATION.className, `${styles$1['pagination-bar']} pagination-bar-rem`));
|
|
7374
|
-
setConfigStyles(() => {
|
|
7375
|
-
return {
|
|
7376
|
-
...data
|
|
7377
|
-
};
|
|
7378
|
-
});
|
|
7379
|
-
}, error => {
|
|
7380
|
-
console.error(error);
|
|
7381
|
-
});
|
|
7382
|
-
}, []);
|
|
7383
|
-
React.useEffect(() => {
|
|
7384
|
-
className && setClassProps(() => classnames__default["default"](
|
|
7385
|
-
// TODO: check and remove pagination-bar-rem class
|
|
7386
|
-
styles$1.list, className ?? configStyles.PAGINATION.className, `${styles$1['pagination-bar']} pagination-bar-rem`));
|
|
7387
|
-
}, [className]);
|
|
7388
|
-
React.useEffect(() => {
|
|
7389
|
-
setcurrentTotalCount(totalCount);
|
|
7390
|
-
}, [totalCount]);
|
|
7391
|
-
React.useEffect(() => {
|
|
7392
|
-
setCurrentPage(currentPage);
|
|
7393
|
-
}, [currentPage]);
|
|
7394
|
-
const onPageChange = page => {
|
|
7395
|
-
if (page > 0) {
|
|
7396
|
-
setCurrentPage(page);
|
|
7397
|
-
}
|
|
7398
|
-
};
|
|
7399
|
-
React.useEffect(() => {
|
|
7400
|
-
onChange(currentPageNumber);
|
|
7401
|
-
}, [currentPageNumber]);
|
|
7402
8005
|
const paginationRange = PaginationRange({
|
|
7403
8006
|
currentPageNumber,
|
|
7404
8007
|
currentTotalCount,
|
|
7405
|
-
|
|
8008
|
+
innerOffset
|
|
7406
8009
|
});
|
|
7407
8010
|
if (currentPageNumber === 0 || paginationRange?.length < 2) {
|
|
7408
8011
|
return null;
|
|
@@ -7444,16 +8047,88 @@ const Pagination = ({
|
|
|
7444
8047
|
if (inpVal <= 1) {
|
|
7445
8048
|
setInpVal(1);
|
|
7446
8049
|
onPageChange(1);
|
|
7447
|
-
} else if (inpVal >= totalCount /
|
|
7448
|
-
setInpVal(Math.ceil(totalCount /
|
|
7449
|
-
onPageChange(Math.ceil(totalCount /
|
|
8050
|
+
} else if (inpVal >= totalCount / innerOffset) {
|
|
8051
|
+
setInpVal(Math.ceil(totalCount / innerOffset));
|
|
8052
|
+
onPageChange(Math.ceil(totalCount / innerOffset));
|
|
7450
8053
|
} else {
|
|
7451
8054
|
onPageChange(inpVal);
|
|
7452
8055
|
}
|
|
7453
8056
|
}
|
|
7454
8057
|
}
|
|
7455
8058
|
};
|
|
8059
|
+
const handleChangeSelect = e => {
|
|
8060
|
+
setInnerOffset(() => {
|
|
8061
|
+
return parseInt(e.value.split('/')[0].trim());
|
|
8062
|
+
});
|
|
8063
|
+
if (getOffset) {
|
|
8064
|
+
getOffset(parseInt(e.value.split('/')[0].trim()));
|
|
8065
|
+
}
|
|
8066
|
+
};
|
|
8067
|
+
const handleMouseEnter = hoverIndex => {
|
|
8068
|
+
setIsHover(hoverIndex);
|
|
8069
|
+
};
|
|
8070
|
+
const handleMouseLeave = () => {
|
|
8071
|
+
setIsHover(false);
|
|
8072
|
+
};
|
|
8073
|
+
const onPageChange = page => {
|
|
8074
|
+
if (page > 0) {
|
|
8075
|
+
setCurrentPage(page);
|
|
8076
|
+
}
|
|
8077
|
+
};
|
|
7456
8078
|
let lastPage = paginationRange[paginationRange.length - 1];
|
|
8079
|
+
React.useEffect(() => {
|
|
8080
|
+
configStylesPromise.then(data => {
|
|
8081
|
+
setClassProps(() => classnames__default["default"](
|
|
8082
|
+
// TODO: check and remove pagination-bar-rem class
|
|
8083
|
+
styles$1.list, className ?? data.PAGINATION.className, `${styles$1['pagination-bar']} pagination-bar-rem`));
|
|
8084
|
+
setConfigStyles(() => {
|
|
8085
|
+
return {
|
|
8086
|
+
...data
|
|
8087
|
+
};
|
|
8088
|
+
});
|
|
8089
|
+
}, error => {
|
|
8090
|
+
console.error(error);
|
|
8091
|
+
});
|
|
8092
|
+
}, []);
|
|
8093
|
+
React.useEffect(() => {
|
|
8094
|
+
setInnerShowOffset(() => showOffset);
|
|
8095
|
+
if (showOffset && offsetCounts && offsetCounts.length) {
|
|
8096
|
+
const newOptions = offsetCounts.map((innerItem, innerIndex) => {
|
|
8097
|
+
return {
|
|
8098
|
+
item: innerIndex,
|
|
8099
|
+
value: `${innerItem} / Էջ `
|
|
8100
|
+
};
|
|
8101
|
+
});
|
|
8102
|
+
setOffsetArgs(() => {
|
|
8103
|
+
return {
|
|
8104
|
+
showCloseIcon: false,
|
|
8105
|
+
options: newOptions,
|
|
8106
|
+
onChange: handleChangeSelect,
|
|
8107
|
+
defaultOption: `${newOptions[0].value}`,
|
|
8108
|
+
keyNames: {
|
|
8109
|
+
name: 'value',
|
|
8110
|
+
id: 'item'
|
|
8111
|
+
}
|
|
8112
|
+
};
|
|
8113
|
+
});
|
|
8114
|
+
setInnerOffset(() => offsetCounts[0]);
|
|
8115
|
+
}
|
|
8116
|
+
}, [offsetCounts, showOffset]);
|
|
8117
|
+
React.useEffect(() => {
|
|
8118
|
+
className && setClassProps(() => classnames__default["default"](
|
|
8119
|
+
// TODO: check and remove pagination-bar-rem class
|
|
8120
|
+
styles$1.list, className ?? configStyles.PAGINATION.className, `${styles$1['pagination-bar']} pagination-bar-rem`));
|
|
8121
|
+
}, [className]);
|
|
8122
|
+
React.useEffect(() => {
|
|
8123
|
+
setcurrentTotalCount(totalCount);
|
|
8124
|
+
setInnerOffset(() => offset > totalCount ? totalCount : offset);
|
|
8125
|
+
}, [totalCount, offset]);
|
|
8126
|
+
React.useEffect(() => {
|
|
8127
|
+
setCurrentPage(currentPage);
|
|
8128
|
+
}, [currentPage]);
|
|
8129
|
+
React.useEffect(() => {
|
|
8130
|
+
onChange(currentPageNumber);
|
|
8131
|
+
}, [currentPageNumber]);
|
|
7457
8132
|
return configStyles.PAGINATION && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
7458
8133
|
style: {
|
|
7459
8134
|
display: 'flex',
|
|
@@ -7464,6 +8139,20 @@ const Pagination = ({
|
|
|
7464
8139
|
className: classProps
|
|
7465
8140
|
}, /*#__PURE__*/React__default["default"].createElement("ul", null, /*#__PURE__*/React__default["default"].createElement("button", {
|
|
7466
8141
|
style: {
|
|
8142
|
+
width: width ?? configStyles.PAGINATION.width,
|
|
8143
|
+
height: height ?? configStyles.PAGINATION.height,
|
|
8144
|
+
fontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8145
|
+
fontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8146
|
+
fontWeight: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8147
|
+
fontFamily: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8148
|
+
lineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8149
|
+
backgroundColor: backgroundColor ?? configStyles.PAGINATION.backgroundColor,
|
|
8150
|
+
boxShadow: `
|
|
8151
|
+
0 0 0
|
|
8152
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8153
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8154
|
+
`,
|
|
8155
|
+
borderRadius: borderRadius ?? configStyles.PAGINATION.border.radius,
|
|
7467
8156
|
transform: 'rotate(180deg)'
|
|
7468
8157
|
},
|
|
7469
8158
|
onClick: onPrevious,
|
|
@@ -7474,7 +8163,17 @@ const Pagination = ({
|
|
|
7474
8163
|
let currentPageIndex = paginationRange.indexOf(currentPageNumber);
|
|
7475
8164
|
return /*#__PURE__*/React__default["default"].createElement("li", {
|
|
7476
8165
|
key: id,
|
|
7477
|
-
className: classnames__default["default"](`${styles$1['pagination-jump-next']} pagination-jump-next-rem
|
|
8166
|
+
className: classnames__default["default"](`${styles$1['pagination-jump-next']} pagination-jump-next-rem`),
|
|
8167
|
+
style: {
|
|
8168
|
+
width: width ?? configStyles.PAGINATION.width,
|
|
8169
|
+
height: height ?? configStyles.PAGINATION.height,
|
|
8170
|
+
boxShadow: `
|
|
8171
|
+
0 0 0
|
|
8172
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8173
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8174
|
+
`,
|
|
8175
|
+
borderRadius: borderRadius ?? configStyles.PAGINATION.border.radius
|
|
8176
|
+
},
|
|
7478
8177
|
onClick: id < currentPageIndex ? onPreviousFive : onNextFive,
|
|
7479
8178
|
disabled: currentPageIndex === 0 ? true : false
|
|
7480
8179
|
}, id < currentPageIndex ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement("span", {
|
|
@@ -7493,43 +8192,144 @@ const Pagination = ({
|
|
|
7493
8192
|
return /*#__PURE__*/React__default["default"].createElement("li", {
|
|
7494
8193
|
onClick: () => onPageChange(pageNumber),
|
|
7495
8194
|
key: id,
|
|
7496
|
-
className: classnames__default["default"](`${
|
|
8195
|
+
className: classnames__default["default"](`${styles$1['pagination-item']} pagination-item-rem`),
|
|
8196
|
+
onMouseEnter: () => handleMouseEnter(id),
|
|
8197
|
+
onMouseLeave: () => handleMouseLeave(),
|
|
8198
|
+
style: {
|
|
8199
|
+
width: width ?? configStyles.PAGINATION.width,
|
|
8200
|
+
height: height ?? configStyles.PAGINATION.height,
|
|
8201
|
+
fontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8202
|
+
fontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8203
|
+
fontWeight: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8204
|
+
fontFamily: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8205
|
+
lineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8206
|
+
color: `
|
|
8207
|
+
${pageNumber === currentPageNumber ? activeColor ?? configStyles.PAGINATION.colors.active : isHover === id ? hoverColor ?? configStyles.PAGINATION.colors.hover : color ?? configStyles.PAGINATION.color}
|
|
8208
|
+
`,
|
|
8209
|
+
backgroundColor: `
|
|
8210
|
+
${pageNumber === currentPageNumber ? activeBackgroundColor ?? configStyles.PAGINATION.colors.activeBackground : isHover === id ? hoverBackgroundColor ?? configStyles.PAGINATION.colors.hoverBackground : backgroundColor ?? configStyles.PAGINATION.colors.background}
|
|
8211
|
+
`,
|
|
8212
|
+
boxShadow: `
|
|
8213
|
+
0 0 0
|
|
8214
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8215
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8216
|
+
`,
|
|
8217
|
+
borderRadius: borderRadius ?? configStyles.PAGINATION.border.radius
|
|
8218
|
+
}
|
|
7497
8219
|
}, pageNumber);
|
|
7498
8220
|
}), /*#__PURE__*/React__default["default"].createElement("button", {
|
|
7499
8221
|
onClick: onNext,
|
|
7500
8222
|
disabled: currentPageNumber === lastPage ? true : false,
|
|
7501
|
-
className: `${styles$1['pagination-btn']} pagination-btn-rem
|
|
7502
|
-
|
|
8223
|
+
className: `${styles$1['pagination-btn']} pagination-btn-rem`,
|
|
8224
|
+
style: {
|
|
8225
|
+
width: width ?? configStyles.PAGINATION.width,
|
|
8226
|
+
height: height ?? configStyles.PAGINATION.height,
|
|
8227
|
+
fontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8228
|
+
fontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8229
|
+
fontWeight: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8230
|
+
fontFamily: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8231
|
+
lineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8232
|
+
backgroundColor: backgroundColor ?? configStyles.PAGINATION.backgroundColor,
|
|
8233
|
+
boxShadow: `
|
|
8234
|
+
0 0 0
|
|
8235
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8236
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8237
|
+
`,
|
|
8238
|
+
borderRadius: borderRadius ?? configStyles.PAGINATION.border.radius
|
|
8239
|
+
}
|
|
8240
|
+
}, /*#__PURE__*/React__default["default"].createElement(SvgNextarrow, null))), innerShowOffset && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
8241
|
+
className: "show-offset-block",
|
|
8242
|
+
style: {
|
|
8243
|
+
width: '91px',
|
|
8244
|
+
height: '34px',
|
|
8245
|
+
marginLeft: '10px',
|
|
8246
|
+
marginRight: '3px'
|
|
8247
|
+
}
|
|
8248
|
+
}, /*#__PURE__*/React__default["default"].createElement(Select, _extends({
|
|
8249
|
+
insidePagination: true,
|
|
8250
|
+
selectedMinHeight: "34px",
|
|
8251
|
+
boxShadow: `
|
|
8252
|
+
0 0 0
|
|
8253
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8254
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8255
|
+
`,
|
|
8256
|
+
boxShadowHover: `
|
|
8257
|
+
0 0 0
|
|
8258
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8259
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8260
|
+
`,
|
|
8261
|
+
selectedFontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8262
|
+
selectedFontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8263
|
+
selectedLineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8264
|
+
selectedFontFamily: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8265
|
+
selectedFontWeight: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8266
|
+
optionItemFontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8267
|
+
optionItemFontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8268
|
+
optionItemLineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8269
|
+
optionItemFontFamily: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8270
|
+
optionItemFontWeight: fontFamily ?? configStyles.PAGINATION.font.family
|
|
8271
|
+
}, offsetArgs))), goTo && /*#__PURE__*/React__default["default"].createElement("div", null, /*#__PURE__*/React__default["default"].createElement("input", {
|
|
7503
8272
|
onKeyDown: handleKeyDown,
|
|
7504
8273
|
onInput: handleChangeInput,
|
|
7505
8274
|
type: "number",
|
|
7506
8275
|
style: {
|
|
7507
|
-
width: '
|
|
7508
|
-
|
|
8276
|
+
width: '55px',
|
|
8277
|
+
border: 'none',
|
|
7509
8278
|
outline: 'none',
|
|
7510
|
-
color: '#3C393E',
|
|
7511
|
-
fontSize: '13px',
|
|
7512
8279
|
margin: '0px 6px',
|
|
7513
|
-
fontWeight: '500',
|
|
7514
8280
|
textAlign: 'center',
|
|
7515
|
-
|
|
7516
|
-
|
|
7517
|
-
|
|
8281
|
+
color: color ?? configStyles.PAGINATION.color,
|
|
8282
|
+
height: height ?? configStyles.PAGINATION.height,
|
|
8283
|
+
fontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8284
|
+
fontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8285
|
+
fontWeight: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8286
|
+
fontFamily: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8287
|
+
lineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight,
|
|
8288
|
+
backgroundColor: backgroundColor ?? configStyles.PAGINATION.backgroundColor,
|
|
8289
|
+
boxShadow: `
|
|
8290
|
+
0 0 0
|
|
8291
|
+
${borderWidth ?? configStyles.PAGINATION.border.width}
|
|
8292
|
+
${borderColor ?? configStyles.PAGINATION.border.color}
|
|
8293
|
+
`,
|
|
8294
|
+
borderRadius: borderRadius ?? configStyles.PAGINATION.border.radius
|
|
7518
8295
|
},
|
|
7519
8296
|
value: inpVal
|
|
7520
8297
|
}), /*#__PURE__*/React__default["default"].createElement("span", {
|
|
7521
8298
|
style: {
|
|
7522
|
-
color:
|
|
7523
|
-
fontSize:
|
|
8299
|
+
color: color ?? configStyles.PAGINATION.color,
|
|
8300
|
+
fontSize: fontSize ?? configStyles.PAGINATION.font.size,
|
|
8301
|
+
fontStyle: fontStyle ?? configStyles.PAGINATION.font.style,
|
|
8302
|
+
fontWeight: fontWeight ?? configStyles.PAGINATION.font.weight,
|
|
8303
|
+
fontFamily: fontFamily ?? configStyles.PAGINATION.font.family,
|
|
8304
|
+
lineHeight: lineHeight ?? configStyles.PAGINATION.lineHeight
|
|
7524
8305
|
}
|
|
7525
8306
|
}, "\u0537\u057B")));
|
|
7526
8307
|
};
|
|
7527
8308
|
Pagination.propTypes = {
|
|
7528
8309
|
goTo: PropTypes__default["default"].bool,
|
|
7529
8310
|
offset: PropTypes__default["default"].number,
|
|
7530
|
-
|
|
8311
|
+
getOffset: PropTypes__default["default"].func,
|
|
8312
|
+
showOffset: PropTypes__default["default"].bool,
|
|
7531
8313
|
className: PropTypes__default["default"].string,
|
|
7532
|
-
|
|
8314
|
+
totalCount: PropTypes__default["default"].number,
|
|
8315
|
+
currentPage: PropTypes__default["default"].number,
|
|
8316
|
+
offsetCounts: PropTypes__default["default"].arrayOf(PropTypes__default["default"].number),
|
|
8317
|
+
color: PropTypes__default["default"].string,
|
|
8318
|
+
width: PropTypes__default["default"].string,
|
|
8319
|
+
height: PropTypes__default["default"].string,
|
|
8320
|
+
fontSize: PropTypes__default["default"].string,
|
|
8321
|
+
fontWeight: PropTypes__default["default"].string,
|
|
8322
|
+
fontFamily: PropTypes__default["default"].string,
|
|
8323
|
+
fontStyle: PropTypes__default["default"].string,
|
|
8324
|
+
lineHeight: PropTypes__default["default"].string,
|
|
8325
|
+
activeColor: PropTypes__default["default"].string,
|
|
8326
|
+
hoverColor: PropTypes__default["default"].string,
|
|
8327
|
+
backgroundColor: PropTypes__default["default"].string,
|
|
8328
|
+
hoverBackgroundColor: PropTypes__default["default"].string,
|
|
8329
|
+
activeBackgroundColor: PropTypes__default["default"].string,
|
|
8330
|
+
borderColor: PropTypes__default["default"].string,
|
|
8331
|
+
borderWidth: PropTypes__default["default"].string,
|
|
8332
|
+
borderRadius: PropTypes__default["default"].string
|
|
7533
8333
|
};
|
|
7534
8334
|
|
|
7535
8335
|
var css_248z = ".autocomplete-module_auto-complete__oUOv9{appearance:none!important;-webkit-appearance:none!important}";
|
|
@@ -7947,6 +8747,7 @@ Autocomplete.propTypes = {
|
|
|
7947
8747
|
backgroundDisableColor: PropTypes__default["default"].string
|
|
7948
8748
|
};
|
|
7949
8749
|
|
|
8750
|
+
exports.Accordion = Accordion;
|
|
7950
8751
|
exports.Autocomplete = Autocomplete;
|
|
7951
8752
|
exports.Button = Button;
|
|
7952
8753
|
exports.Captcha = Captcha;
|