@xaypay/tui 0.3.0 → 0.3.1
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/CHANGELOG.md +43 -0
- package/dist/index.es.js +647 -434
- package/dist/index.js +647 -434
- package/package.json +1 -1
- package/tui.config.js +15 -11
package/dist/index.js
CHANGED
|
@@ -655,6 +655,7 @@ var packageResult = {
|
|
|
655
655
|
marginTop: '10px',
|
|
656
656
|
iconMargin: '10px',
|
|
657
657
|
lineHeight: '19px',
|
|
658
|
+
inContent: false,
|
|
658
659
|
box: {
|
|
659
660
|
shadow: '0 0 0 1px #F20918'
|
|
660
661
|
},
|
|
@@ -858,6 +859,7 @@ var packageResult = {
|
|
|
858
859
|
colors: {
|
|
859
860
|
hover: '#373538',
|
|
860
861
|
background: presetColors.extraLight,
|
|
862
|
+
placeholderDisable: presetColors.dark,
|
|
861
863
|
backgroundDisable: presetColors.secondary
|
|
862
864
|
},
|
|
863
865
|
font: {
|
|
@@ -896,6 +898,7 @@ var packageResult = {
|
|
|
896
898
|
color: 'rgb(238, 0, 0)',
|
|
897
899
|
marginTop: '10px',
|
|
898
900
|
zIndex: 10,
|
|
901
|
+
inContent: false,
|
|
899
902
|
box: {
|
|
900
903
|
shadow: `0 0 0 2px ${presetColors.danger}`
|
|
901
904
|
},
|
|
@@ -926,7 +929,8 @@ var packageResult = {
|
|
|
926
929
|
sizing: boxSizing,
|
|
927
930
|
shadow: `0 0 0 2px ${presetColors.secondary}`,
|
|
928
931
|
// like border
|
|
929
|
-
|
|
932
|
+
width: '2px',
|
|
933
|
+
// like border width
|
|
930
934
|
colors: {
|
|
931
935
|
hover: `0 0 0 2px ${presetColors.dark}`,
|
|
932
936
|
// like border color
|
|
@@ -1079,6 +1083,7 @@ var packageResult = {
|
|
|
1079
1083
|
error: {
|
|
1080
1084
|
color: presetColors.danger,
|
|
1081
1085
|
marginTop: '10px',
|
|
1086
|
+
inContent: false,
|
|
1082
1087
|
font: {
|
|
1083
1088
|
...fontObject
|
|
1084
1089
|
},
|
|
@@ -1114,10 +1119,9 @@ var packageResult = {
|
|
|
1114
1119
|
width: '27.8rem',
|
|
1115
1120
|
height: 'auto'
|
|
1116
1121
|
},
|
|
1117
|
-
or: 'կամ',
|
|
1118
1122
|
upload: 'Բեռնել',
|
|
1119
1123
|
uploadColor: presetColors.success,
|
|
1120
|
-
putFileHere: 'Տեղադրել ֆայլը այստեղ',
|
|
1124
|
+
putFileHere: 'Տեղադրել ֆայլը այստեղ կամ',
|
|
1121
1125
|
sizeText: 'Առավելագույնը',
|
|
1122
1126
|
timeForRemoveError: 4000,
|
|
1123
1127
|
extentionsRowMarginTop: '40px',
|
|
@@ -1161,11 +1165,13 @@ var packageResult = {
|
|
|
1161
1165
|
},
|
|
1162
1166
|
error: {
|
|
1163
1167
|
color: presetColors.danger,
|
|
1168
|
+
marginTop: '6px',
|
|
1164
1169
|
font: {
|
|
1165
1170
|
...fontObject
|
|
1166
1171
|
},
|
|
1167
1172
|
format: 'ֆայլի սխալ ֆորմատ',
|
|
1168
1173
|
maxSize: 'Առավելագույն ծավալ',
|
|
1174
|
+
formatValidate: 'Վնասված ֆայլ',
|
|
1169
1175
|
noChoosenFile: 'Ֆայլը ընտրված չէ'
|
|
1170
1176
|
},
|
|
1171
1177
|
progress: {
|
|
@@ -1233,10 +1239,9 @@ var packageResult = {
|
|
|
1233
1239
|
height: '',
|
|
1234
1240
|
maxWidth: '95%',
|
|
1235
1241
|
minWidth: '320px',
|
|
1236
|
-
maxHeight: '
|
|
1242
|
+
maxHeight: '95dvh',
|
|
1237
1243
|
minHeight: '200px',
|
|
1238
|
-
|
|
1239
|
-
noScroll: false,
|
|
1244
|
+
underScroll: false,
|
|
1240
1245
|
padding: '20px 20px 20px',
|
|
1241
1246
|
className: '',
|
|
1242
1247
|
alignItems: 'center',
|
|
@@ -1246,7 +1251,8 @@ var packageResult = {
|
|
|
1246
1251
|
border: {
|
|
1247
1252
|
width: '20px',
|
|
1248
1253
|
style: 'solid',
|
|
1249
|
-
color: transparent
|
|
1254
|
+
color: transparent,
|
|
1255
|
+
radius: '14px'
|
|
1250
1256
|
},
|
|
1251
1257
|
colors: {
|
|
1252
1258
|
background: 'white',
|
|
@@ -1290,8 +1296,8 @@ var packageResult = {
|
|
|
1290
1296
|
// default properties for <SwipeModal /> component
|
|
1291
1297
|
SWIPEMODAL: {
|
|
1292
1298
|
width: '300px',
|
|
1293
|
-
height: '
|
|
1294
|
-
|
|
1299
|
+
height: '100dvh',
|
|
1300
|
+
underScroll: false,
|
|
1295
1301
|
titleStyle: {
|
|
1296
1302
|
color: '#1C212D',
|
|
1297
1303
|
textAlign: 'left',
|
|
@@ -1303,7 +1309,7 @@ var packageResult = {
|
|
|
1303
1309
|
},
|
|
1304
1310
|
parent: {
|
|
1305
1311
|
width: '100%',
|
|
1306
|
-
height: '
|
|
1312
|
+
height: '100dvh',
|
|
1307
1313
|
colors: {
|
|
1308
1314
|
background: 'rgba(60, 61, 70, 0.2)'
|
|
1309
1315
|
}
|
|
@@ -1876,16 +1882,15 @@ styleInject(css_248z$d);
|
|
|
1876
1882
|
|
|
1877
1883
|
// eslint-disable-next-line react/display-name
|
|
1878
1884
|
const File = /*#__PURE__*/React.forwardRef(({
|
|
1879
|
-
or,
|
|
1880
|
-
size,
|
|
1881
1885
|
name,
|
|
1882
1886
|
color,
|
|
1883
|
-
style,
|
|
1884
|
-
weight,
|
|
1885
|
-
family,
|
|
1886
1887
|
height,
|
|
1887
|
-
radius,
|
|
1888
1888
|
change,
|
|
1889
|
+
fontSize,
|
|
1890
|
+
fontStyle,
|
|
1891
|
+
fontFamily,
|
|
1892
|
+
fontWeight,
|
|
1893
|
+
borderRadius,
|
|
1889
1894
|
borderWidth,
|
|
1890
1895
|
borderStyle,
|
|
1891
1896
|
borderColor,
|
|
@@ -1895,17 +1900,18 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1895
1900
|
multiple,
|
|
1896
1901
|
required,
|
|
1897
1902
|
className,
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1903
|
+
errorFontSize,
|
|
1904
|
+
errorFontStyle,
|
|
1905
|
+
errorFontWeight,
|
|
1906
|
+
errorFontFamily,
|
|
1907
|
+
errorMarginTop,
|
|
1902
1908
|
label,
|
|
1903
|
-
labelSize,
|
|
1904
1909
|
labelColor,
|
|
1905
|
-
labelStyle,
|
|
1906
|
-
labelWeight,
|
|
1907
|
-
labelFamily,
|
|
1908
1910
|
lableShowMore,
|
|
1911
|
+
labelFontSize,
|
|
1912
|
+
labelFontStyle,
|
|
1913
|
+
labelFontWeight,
|
|
1914
|
+
labelFontFamily,
|
|
1909
1915
|
labelShowLessText,
|
|
1910
1916
|
labelShowMoreText,
|
|
1911
1917
|
showMoreTextColor,
|
|
@@ -1927,6 +1933,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
1927
1933
|
uploadColor,
|
|
1928
1934
|
defaultData,
|
|
1929
1935
|
formatError,
|
|
1936
|
+
formatValidateError,
|
|
1930
1937
|
errorIcon,
|
|
1931
1938
|
errorIconShow,
|
|
1932
1939
|
errorMessage,
|
|
@@ -2010,20 +2017,211 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2010
2017
|
const [tooltipElem, setTooltipElem] = React.useState(null);
|
|
2011
2018
|
const [choosenFileCount, setChoosenFileCount] = React.useState(0);
|
|
2012
2019
|
const [image, setImage] = React.useState(!multiple ? defaultData ? defaultData.type !== 'application/pdf' ? defaultData.url.startsWith('data:image/heif') || defaultData.url.startsWith('data:image/heic') || defaultData.url.startsWith('data:application/octet-stream') ? 'heic' : defaultData.url : 'pdf' : null : null);
|
|
2013
|
-
const
|
|
2020
|
+
const handleCheckFileFormat = async (file, type) => {
|
|
2014
2021
|
const buffer = await file.arrayBuffer();
|
|
2015
2022
|
const dataView = new DataView(buffer);
|
|
2016
|
-
if (
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2023
|
+
if (type === 'png') {
|
|
2024
|
+
if (dataView.byteLength < 8) {
|
|
2025
|
+
return Promise.reject();
|
|
2026
|
+
} else {
|
|
2027
|
+
if (dataView.getUint8(0) === 0x89 && dataView.getUint8(1) === 0x50 && dataView.getUint8(2) === 0x4E && dataView.getUint8(3) === 0x47 && dataView.getUint8(4) === 0x0D && dataView.getUint8(5) === 0x0A && dataView.getUint8(6) === 0x1A && dataView.getUint8(7) === 0x0A) {
|
|
2028
|
+
const end = dataView.byteLength - 12;
|
|
2029
|
+
if (dataView.getUint8(end) === 0x00 && dataView.getUint8(end + 1) === 0x00 && dataView.getUint8(end + 2) === 0x00 && dataView.getUint8(end + 3) === 0x00 && dataView.getUint8(end + 4) === 0x49 && dataView.getUint8(end + 5) === 0x45 && dataView.getUint8(end + 6) === 0x4E && dataView.getUint8(end + 7) === 0x44 && dataView.getUint8(end + 8) === 0xAE && dataView.getUint8(end + 9) === 0x42 && dataView.getUint8(end + 10) === 0x60 && dataView.getUint8(end + 11) === 0x82) {
|
|
2030
|
+
return Promise.resolve();
|
|
2031
|
+
} else {
|
|
2032
|
+
return Promise.reject();
|
|
2033
|
+
}
|
|
2034
|
+
} else {
|
|
2035
|
+
return Promise.reject();
|
|
2036
|
+
}
|
|
2037
|
+
}
|
|
2038
|
+
} else if (type === 'jpg') {
|
|
2039
|
+
if (dataView.byteLength < 2) {
|
|
2040
|
+
return Promise.reject();
|
|
2041
|
+
} else {
|
|
2042
|
+
if (dataView.getUint8(0) === 0xFF && dataView.getUint8(1) === 0xD8 && dataView.getUint8(dataView.byteLength - 2) === 0xFF && dataView.getUint8(dataView.byteLength - 1) === 0xD9) {
|
|
2022
2043
|
return Promise.resolve();
|
|
2044
|
+
} else {
|
|
2045
|
+
return Promise.reject();
|
|
2046
|
+
}
|
|
2047
|
+
}
|
|
2048
|
+
} else if (type === 'svg') {
|
|
2049
|
+
if (dataView.byteLength < 8) return Promise.reject();
|
|
2050
|
+
const len = dataView.byteLength;
|
|
2051
|
+
let start = 0;
|
|
2052
|
+
let end = len - 1;
|
|
2053
|
+
const isWS = b => b === 0x20 || b === 0x09 || b === 0x0A || b === 0x0D;
|
|
2054
|
+
while (start < len && isWS(dataView.getUint8(start))) start++;
|
|
2055
|
+
const scanLimit = Math.min(len, start + 4096);
|
|
2056
|
+
let foundSvgOpen = false;
|
|
2057
|
+
for (let i = start; i <= scanLimit - 4; i++) {
|
|
2058
|
+
if (dataView.getUint8(i) === 0x3C && (dataView.getUint8(i + 1) === 0x73 || dataView.getUint8(i + 1) === 0x53) && (dataView.getUint8(i + 2) === 0x76 || dataView.getUint8(i + 2) === 0x56) && (dataView.getUint8(i + 3) === 0x67 || dataView.getUint8(i + 3) === 0x47)) {
|
|
2059
|
+
foundSvgOpen = true;
|
|
2060
|
+
break;
|
|
2061
|
+
}
|
|
2062
|
+
}
|
|
2063
|
+
if (!foundSvgOpen) return Promise.reject();
|
|
2064
|
+
while (end >= 0 && isWS(dataView.getUint8(end))) end--;
|
|
2065
|
+
if (end >= 5 && dataView.getUint8(end - 5) === 0x3C && dataView.getUint8(end - 4) === 0x2F && (dataView.getUint8(end - 3) === 0x73 || dataView.getUint8(end - 3) === 0x53) && (dataView.getUint8(end - 2) === 0x76 || dataView.getUint8(end - 2) === 0x56) && (dataView.getUint8(end - 1) === 0x67 || dataView.getUint8(end - 1) === 0x47) && dataView.getUint8(end) === 0x3E) {
|
|
2066
|
+
return Promise.resolve();
|
|
2067
|
+
} else {
|
|
2068
|
+
return Promise.reject();
|
|
2069
|
+
}
|
|
2070
|
+
} else if (type === 'docx') {
|
|
2071
|
+
const len = dataView.byteLength;
|
|
2072
|
+
if (len < 22) return Promise.reject();
|
|
2073
|
+
const isZipHeader = dataView.getUint8(0) === 0x50 && dataView.getUint8(1) === 0x4B && dataView.getUint8(2) === 0x03 && dataView.getUint8(3) === 0x04;
|
|
2074
|
+
if (!isZipHeader) return Promise.reject();
|
|
2075
|
+
const EOCD = [0x50, 0x4B, 0x05, 0x06];
|
|
2076
|
+
const maxBack = Math.min(len - 4, 0xFFFF + 22);
|
|
2077
|
+
let eocdIndex = -1;
|
|
2078
|
+
for (let i = len - 4; i >= len - 4 - maxBack; i--) {
|
|
2079
|
+
if (i < 0) break;
|
|
2080
|
+
if (dataView.getUint8(i) === EOCD[0] && dataView.getUint8(i + 1) === EOCD[1] && dataView.getUint8(i + 2) === EOCD[2] && dataView.getUint8(i + 3) === EOCD[3]) {
|
|
2081
|
+
eocdIndex = i;
|
|
2082
|
+
break;
|
|
2083
|
+
}
|
|
2084
|
+
}
|
|
2085
|
+
if (eocdIndex === -1) return Promise.reject();
|
|
2086
|
+
const findAscii = needle => {
|
|
2087
|
+
const enc = new TextEncoder().encode(needle);
|
|
2088
|
+
for (let i = 0; i <= len - enc.length; i++) {
|
|
2089
|
+
let ok = true;
|
|
2090
|
+
for (let j = 0; j < enc.length; j++) {
|
|
2091
|
+
if (dataView.getUint8(i + j) !== enc[j]) {
|
|
2092
|
+
ok = false;
|
|
2093
|
+
break;
|
|
2094
|
+
}
|
|
2095
|
+
}
|
|
2096
|
+
if (ok) return true;
|
|
2097
|
+
}
|
|
2098
|
+
return false;
|
|
2099
|
+
};
|
|
2100
|
+
const hasContentTypes = findAscii('[Content_Types].xml');
|
|
2101
|
+
const hasRels = findAscii('_rels/.rels');
|
|
2102
|
+
const hasDocument = findAscii('word/document.xml');
|
|
2103
|
+
return hasContentTypes && hasRels && hasDocument ? Promise.resolve() : Promise.reject();
|
|
2104
|
+
} else if (type === 'doc') {
|
|
2105
|
+
const len = dataView.byteLength;
|
|
2106
|
+
if (len < 512) return Promise.reject();
|
|
2107
|
+
const FREESECT = 0xFFFFFFFF;
|
|
2108
|
+
const ENDOFCHAIN = 0xFFFFFFFE;
|
|
2109
|
+
const getU32 = off => dataView.getUint32(off, true);
|
|
2110
|
+
const getI32 = off => dataView.getInt32(off, true);
|
|
2111
|
+
const getU16 = off => dataView.getUint16(off, true);
|
|
2112
|
+
const sectorOffset = (sector, sectorSize) => (sector + 1) * sectorSize;
|
|
2113
|
+
const isOle = dataView.getUint8(0) === 0xD0 && dataView.getUint8(1) === 0xCF && dataView.getUint8(2) === 0x11 && dataView.getUint8(3) === 0xE0 && dataView.getUint8(4) === 0xA1 && dataView.getUint8(5) === 0xB1 && dataView.getUint8(6) === 0x1A && dataView.getUint8(7) === 0xE1;
|
|
2114
|
+
if (!isOle) return Promise.reject();
|
|
2115
|
+
if (dataView.getUint8(0x1C) !== 0xFE || dataView.getUint8(0x1D) !== 0xFF) {
|
|
2116
|
+
return Promise.reject();
|
|
2117
|
+
}
|
|
2118
|
+
const sectorShift = getU16(0x1E); // 9 => 512, 12 => 4096
|
|
2119
|
+
if (sectorShift !== 9 && sectorShift !== 12) return Promise.reject();
|
|
2120
|
+
const sectorSize = 1 << sectorShift;
|
|
2121
|
+
const firstDirSector = getI32(0x30);
|
|
2122
|
+
if (firstDirSector < 0) return Promise.reject();
|
|
2123
|
+
const dirStartOff = sectorOffset(firstDirSector, sectorSize);
|
|
2124
|
+
if (dirStartOff < 512 || dirStartOff + sectorSize > len) return Promise.reject();
|
|
2125
|
+
const numFATSectors = getU32(0x2C);
|
|
2126
|
+
let firstDIFATSector = getI32(0x44);
|
|
2127
|
+
let numDIFATSectors = getU32(0x48);
|
|
2128
|
+
const difat = [];
|
|
2129
|
+
for (let i = 0; i < 109; i++) {
|
|
2130
|
+
const sec = getU32(0x4C + i * 4);
|
|
2131
|
+
if (sec !== FREESECT) difat.push(sec);
|
|
2132
|
+
}
|
|
2133
|
+
const entriesPerDifatSector = sectorSize / 4 - 1;
|
|
2134
|
+
while (numDIFATSectors > 0 && firstDIFATSector !== -1 && firstDIFATSector !== ENDOFCHAIN) {
|
|
2135
|
+
const off = sectorOffset(firstDIFATSector, sectorSize);
|
|
2136
|
+
if (off < 512 || off + sectorSize > len) break;
|
|
2137
|
+
for (let i = 0; i < entriesPerDifatSector; i++) {
|
|
2138
|
+
const sec = dataView.getUint32(off + i * 4, true);
|
|
2139
|
+
if (sec !== FREESECT) difat.push(sec);
|
|
2023
2140
|
}
|
|
2141
|
+
firstDIFATSector = dataView.getInt32(off + entriesPerDifatSector * 4, true); // next DIFAT
|
|
2142
|
+
numDIFATSectors--;
|
|
2024
2143
|
}
|
|
2144
|
+
if (difat.length === 0 || numFATSectors === 0) return Promise.reject();
|
|
2145
|
+
const fat = [];
|
|
2146
|
+
for (let i = 0; i < difat.length; i++) {
|
|
2147
|
+
const fatSector = difat[i];
|
|
2148
|
+
const off = sectorOffset(fatSector, sectorSize);
|
|
2149
|
+
if (off < 512 || off + sectorSize > len) continue;
|
|
2150
|
+
for (let j = 0; j < sectorSize; j += 4) {
|
|
2151
|
+
fat.push(dataView.getUint32(off + j, true));
|
|
2152
|
+
}
|
|
2153
|
+
}
|
|
2154
|
+
if (fat.length === 0) return Promise.reject();
|
|
2155
|
+
const nextSector = s => s >= 0 && s < fat.length ? fat[s] : ENDOFCHAIN;
|
|
2156
|
+
const names = new Set();
|
|
2157
|
+
const td = new TextDecoder("utf-16le");
|
|
2158
|
+
let dirSector = firstDirSector;
|
|
2159
|
+
let safety = 0;
|
|
2160
|
+
while (dirSector !== ENDOFCHAIN && dirSector !== FREESECT && safety++ < 10000) {
|
|
2161
|
+
const off = sectorOffset(dirSector, sectorSize);
|
|
2162
|
+
if (off < 512 || off + sectorSize > len) break;
|
|
2163
|
+
for (let pos = 0; pos < sectorSize; pos += 128) {
|
|
2164
|
+
const entryOff = off + pos;
|
|
2165
|
+
const nameLen = getU16(entryOff + 64);
|
|
2166
|
+
const objType = dataView.getUint8(entryOff + 66);
|
|
2167
|
+
if (objType === 0 || nameLen < 2 || nameLen > 64) continue;
|
|
2168
|
+
const nameBytes = new Uint8Array(dataView.buffer, dataView.byteOffset + entryOff, 64);
|
|
2169
|
+
const realLen = Math.max(0, nameLen - 2);
|
|
2170
|
+
const name = td.decode(nameBytes.slice(0, realLen)).replace(/\0/g, "");
|
|
2171
|
+
if (name) names.add(name);
|
|
2172
|
+
}
|
|
2173
|
+
dirSector = nextSector(dirSector);
|
|
2174
|
+
}
|
|
2175
|
+
const hasWordDocument = names.has("WordDocument");
|
|
2176
|
+
const hasTable = names.has("1Table") || names.has("0Table");
|
|
2177
|
+
return hasWordDocument && hasTable ? Promise.resolve() : Promise.reject();
|
|
2178
|
+
} else if (type === 'pdf') {
|
|
2179
|
+
if (dataView.byteLength < 8) {
|
|
2180
|
+
return Promise.reject();
|
|
2181
|
+
} else {
|
|
2182
|
+
if (dataView.getUint8(0) === 0x25 && dataView.getUint8(1) === 0x50 && dataView.getUint8(2) === 0x44 && dataView.getUint8(3) === 0x46) {
|
|
2183
|
+
const len = dataView.byteLength;
|
|
2184
|
+
let end = len - 1;
|
|
2185
|
+
while (end >= 0 && (dataView.getUint8(end) === 0x0A ||
|
|
2186
|
+
// \n
|
|
2187
|
+
dataView.getUint8(end) === 0x0D ||
|
|
2188
|
+
// \r
|
|
2189
|
+
dataView.getUint8(end) === 0x20 ||
|
|
2190
|
+
// space
|
|
2191
|
+
dataView.getUint8(end) === 0x09 // tab
|
|
2192
|
+
)) {
|
|
2193
|
+
end--;
|
|
2194
|
+
}
|
|
2195
|
+
if (end >= 4 && dataView.getUint8(end - 4) === 0x25 && dataView.getUint8(end - 3) === 0x25 && dataView.getUint8(end - 2) === 0x45 && dataView.getUint8(end - 1) === 0x4F && dataView.getUint8(end) === 0x46) {
|
|
2196
|
+
return Promise.resolve();
|
|
2197
|
+
} else {
|
|
2198
|
+
return Promise.reject();
|
|
2199
|
+
}
|
|
2200
|
+
} else {
|
|
2201
|
+
return Promise.reject();
|
|
2202
|
+
}
|
|
2203
|
+
}
|
|
2204
|
+
} else if (type === 'heic') {
|
|
2205
|
+
if (dataView.byteLength < 12) {
|
|
2206
|
+
return Promise.reject();
|
|
2207
|
+
} else {
|
|
2208
|
+
if (dataView.getUint8(0) === 0x66 && dataView.getUint8(1) === 0x74 && dataView.getUint8(2) === 0x79 && dataView.getUint8(3) === 0x70) {
|
|
2209
|
+
if (dataView.getUint8(dataView.length - 4) === 0x6D && dataView.getUint8(dataView.length - 3) === 0x64 && dataView.getUint8(dataView.length - 2) === 0x61 && dataView.getUint8(dataView.length - 1) === 0x74) {
|
|
2210
|
+
const majorBrand = String.fromCharCode(dataView.getUint8(4), dataView.getUint8(5), dataView.getUint8(6), dataView.getUint8(7));
|
|
2211
|
+
const heicIdentifiers = ['heic', 'heix', 'mif1', 'msf1', 'heif'];
|
|
2212
|
+
if (heicIdentifiers.includes(majorBrand)) {
|
|
2213
|
+
return Promise.resolve();
|
|
2214
|
+
} else {
|
|
2215
|
+
return Promise.reject();
|
|
2216
|
+
}
|
|
2217
|
+
} else {
|
|
2218
|
+
return Promise.reject();
|
|
2219
|
+
}
|
|
2220
|
+
}
|
|
2221
|
+
}
|
|
2222
|
+
} else {
|
|
2223
|
+
return Promise.reject();
|
|
2025
2224
|
}
|
|
2026
|
-
return Promise.reject();
|
|
2027
2225
|
};
|
|
2028
2226
|
const handleRemoveComponent = () => {
|
|
2029
2227
|
if (!multiple) {
|
|
@@ -2037,6 +2235,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2037
2235
|
setImage(null);
|
|
2038
2236
|
setSingleFile(null);
|
|
2039
2237
|
removeFile && removeFile(singleFile);
|
|
2238
|
+
error && setError('');
|
|
2040
2239
|
};
|
|
2041
2240
|
const handleUploadFiles = file => {
|
|
2042
2241
|
if (maxCHoosenLength && choosenFileCount > 0) {
|
|
@@ -2053,43 +2252,24 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2053
2252
|
for (let ix = 0; ix < file.length; ix++) {
|
|
2054
2253
|
if (file[ix]) {
|
|
2055
2254
|
if (file[ix].size <= maxSize * Math.pow(2, 20)) {
|
|
2056
|
-
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif') ||
|
|
2255
|
+
if (fileExtensions.includes(file[ix].name.split('.')[file[ix].name.split('.').length - 1]) && ((fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[ix].type.split('/')[1] === 'heif' || file[ix].type.split('/')[1] === 'heic' || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) || fileExtensions.includes('doc') && file[ix].type.split('/')[1] === 'msword' || fileExtensions.includes('docx') && file[ix].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || fileExtensions.includes('svg') && file[ix].type.split('/')[1] === 'svg+xml' || fileExtensions.includes('png') && file[ix].type.split('/')[1] === 'png' || fileExtensions.includes('pdf') && file[ix].type.split('/')[1] === 'pdf' || (fileExtensions.includes('jpg') || fileExtensions.includes('jpeg')) && file[ix].type.split('/')[1] === 'jpeg')) {
|
|
2256
|
+
let typeOfFile = '';
|
|
2057
2257
|
if (file[ix].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
2058
|
-
|
|
2059
|
-
id: '',
|
|
2060
|
-
check: '',
|
|
2061
|
-
status: '',
|
|
2062
|
-
file: file[ix],
|
|
2063
|
-
uuid: v4()
|
|
2064
|
-
});
|
|
2065
|
-
setImage('docx');
|
|
2258
|
+
typeOfFile = 'docx';
|
|
2066
2259
|
} else if (file[ix].type === 'application/msword') {
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
handleCheckHeicFormat(file[ix]).then(() => {
|
|
2077
|
-
change({
|
|
2078
|
-
id: '',
|
|
2079
|
-
check: '',
|
|
2080
|
-
status: '',
|
|
2081
|
-
file: file[ix],
|
|
2082
|
-
uuid: v4()
|
|
2083
|
-
});
|
|
2084
|
-
setImage('heic');
|
|
2085
|
-
}).catch(() => {
|
|
2086
|
-
change({
|
|
2087
|
-
file: file[ix],
|
|
2088
|
-
uuid: v4(),
|
|
2089
|
-
check: formatError ?? configStyles.FILE.error.format
|
|
2090
|
-
});
|
|
2091
|
-
});
|
|
2260
|
+
typeOfFile = 'doc';
|
|
2261
|
+
} else if (file[ix].type === 'application/pdf') {
|
|
2262
|
+
typeOfFile = 'pdf';
|
|
2263
|
+
} else if (file[ix].type === 'image/heif' || file[ix].type === 'image/heic' || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) {
|
|
2264
|
+
typeOfFile = 'heic';
|
|
2265
|
+
} else if (file[ix].type === 'image/jpeg') {
|
|
2266
|
+
typeOfFile = 'jpg';
|
|
2267
|
+
} else if (file[ix].type === 'image/png') {
|
|
2268
|
+
typeOfFile = 'png';
|
|
2092
2269
|
} else if (file[ix].type === 'image/svg+xml') {
|
|
2270
|
+
typeOfFile = 'svg';
|
|
2271
|
+
}
|
|
2272
|
+
handleCheckFileFormat(file[ix], typeOfFile).then(() => {
|
|
2093
2273
|
change({
|
|
2094
2274
|
id: '',
|
|
2095
2275
|
check: '',
|
|
@@ -2097,16 +2277,14 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2097
2277
|
file: file[ix],
|
|
2098
2278
|
uuid: v4()
|
|
2099
2279
|
});
|
|
2100
|
-
setImage(
|
|
2101
|
-
}
|
|
2280
|
+
setImage(typeOfFile);
|
|
2281
|
+
}).catch(() => {
|
|
2102
2282
|
change({
|
|
2103
|
-
id: '',
|
|
2104
|
-
check: '',
|
|
2105
|
-
status: '',
|
|
2106
2283
|
file: file[ix],
|
|
2107
|
-
uuid: v4()
|
|
2284
|
+
uuid: v4(),
|
|
2285
|
+
check: formatValidateError ?? configStyles.FILE.error.formatValidate
|
|
2108
2286
|
});
|
|
2109
|
-
}
|
|
2287
|
+
});
|
|
2110
2288
|
} else {
|
|
2111
2289
|
change({
|
|
2112
2290
|
file: file[ix],
|
|
@@ -2128,43 +2306,24 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2128
2306
|
for (let ix = 0; ix < file.length; ix++) {
|
|
2129
2307
|
if (file[ix]) {
|
|
2130
2308
|
if (file[ix].size <= maxSize * Math.pow(2, 20)) {
|
|
2131
|
-
if (fileExtensions.includes(file[ix].type.split('/')[1]) || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif') ||
|
|
2309
|
+
if (fileExtensions.includes(file[ix].name.split('.')[file[ix].name.split('.').length - 1]) && ((fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[ix].type.split('/')[1] === 'heif' || file[ix].type.split('/')[1] === 'heic' || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) || fileExtensions.includes('doc') && file[ix].type.split('/')[1] === 'msword' || fileExtensions.includes('docx') && file[ix].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || fileExtensions.includes('svg') && file[ix].type.split('/')[1] === 'svg+xml' || fileExtensions.includes('png') && file[ix].type.split('/')[1] === 'png' || fileExtensions.includes('pdf') && file[ix].type.split('/')[1] === 'pdf' || (fileExtensions.includes('jpg') || fileExtensions.includes('jpeg')) && file[ix].type.split('/')[1] === 'jpeg')) {
|
|
2310
|
+
let typeOfFile = '';
|
|
2132
2311
|
if (file[ix].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
2133
|
-
|
|
2134
|
-
id: '',
|
|
2135
|
-
check: '',
|
|
2136
|
-
status: '',
|
|
2137
|
-
file: file[ix],
|
|
2138
|
-
uuid: v4()
|
|
2139
|
-
});
|
|
2140
|
-
setImage('docx');
|
|
2312
|
+
typeOfFile = 'docx';
|
|
2141
2313
|
} else if (file[ix].type === 'application/msword') {
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
handleCheckHeicFormat(file[ix]).then(() => {
|
|
2152
|
-
change({
|
|
2153
|
-
id: '',
|
|
2154
|
-
check: '',
|
|
2155
|
-
status: '',
|
|
2156
|
-
file: file[ix],
|
|
2157
|
-
uuid: v4()
|
|
2158
|
-
});
|
|
2159
|
-
setImage('heic');
|
|
2160
|
-
}).catch(() => {
|
|
2161
|
-
change({
|
|
2162
|
-
file: file[ix],
|
|
2163
|
-
uuid: v4(),
|
|
2164
|
-
check: formatError ?? configStyles.FILE.error.format
|
|
2165
|
-
});
|
|
2166
|
-
});
|
|
2314
|
+
typeOfFile = 'doc';
|
|
2315
|
+
} else if (file[ix].type === 'application/pdf') {
|
|
2316
|
+
typeOfFile = 'pdf';
|
|
2317
|
+
} else if (file[ix].type === 'image/heif' || file[ix].type === 'image/heic' || file[ix].name.toLowerCase().endsWith('.heic') || file[ix].name.toLowerCase().endsWith('.heif')) {
|
|
2318
|
+
typeOfFile = 'heic';
|
|
2319
|
+
} else if (file[ix].type === 'image/jpeg') {
|
|
2320
|
+
typeOfFile = 'jpg';
|
|
2321
|
+
} else if (file[ix].type === 'image/png') {
|
|
2322
|
+
typeOfFile = 'png';
|
|
2167
2323
|
} else if (file[ix].type === 'image/svg+xml') {
|
|
2324
|
+
typeOfFile = 'svg';
|
|
2325
|
+
}
|
|
2326
|
+
handleCheckFileFormat(file[ix], typeOfFile).then(() => {
|
|
2168
2327
|
change({
|
|
2169
2328
|
id: '',
|
|
2170
2329
|
check: '',
|
|
@@ -2172,16 +2331,14 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2172
2331
|
file: file[ix],
|
|
2173
2332
|
uuid: v4()
|
|
2174
2333
|
});
|
|
2175
|
-
setImage(
|
|
2176
|
-
}
|
|
2334
|
+
setImage(typeOfFile);
|
|
2335
|
+
}).catch(() => {
|
|
2177
2336
|
change({
|
|
2178
|
-
id: '',
|
|
2179
|
-
check: '',
|
|
2180
|
-
status: '',
|
|
2181
2337
|
file: file[ix],
|
|
2182
|
-
uuid: v4()
|
|
2338
|
+
uuid: v4(),
|
|
2339
|
+
check: formatValidateError ?? configStyles.FILE.error.formatValidate
|
|
2183
2340
|
});
|
|
2184
|
-
}
|
|
2341
|
+
});
|
|
2185
2342
|
} else {
|
|
2186
2343
|
change({
|
|
2187
2344
|
file: file[ix],
|
|
@@ -2212,34 +2369,36 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2212
2369
|
} else {
|
|
2213
2370
|
if (file[0]) {
|
|
2214
2371
|
if (file[0].size <= maxSize * Math.pow(2, 20)) {
|
|
2215
|
-
if (fileExtensions.includes(file[0].
|
|
2372
|
+
if (fileExtensions.includes(file[0].name.split('.')[file[0].name.split('.').length - 1]) && ((fileExtensions.includes('heic') || fileExtensions.includes('heif')) && (file[0].type.split('/')[1] === 'heif' || file[0].type.split('/')[1] === 'heic' || file[0].name.toLowerCase().endsWith('.heic') || file[0].name.toLowerCase().endsWith('.heif')) || fileExtensions.includes('doc') && file[0].type.split('/')[1] === 'msword' || fileExtensions.includes('docx') && file[0].type.split('/')[1] === 'vnd.openxmlformats-officedocument.wordprocessingml.document' || fileExtensions.includes('svg') && file[0].type.split('/')[1] === 'svg+xml' || fileExtensions.includes('png') && file[0].type.split('/')[1] === 'png' || fileExtensions.includes('pdf') && file[0].type.split('/')[1] === 'pdf' || (fileExtensions.includes('jpg') || fileExtensions.includes('jpeg')) && file[0].type.split('/')[1] === 'jpeg')) {
|
|
2216
2373
|
setError('');
|
|
2374
|
+
let typeOfFile = '';
|
|
2217
2375
|
if (file[0].type === 'application/vnd.openxmlformats-officedocument.wordprocessingml.document') {
|
|
2218
|
-
|
|
2219
|
-
change(file);
|
|
2220
|
-
setSingleFile(file);
|
|
2376
|
+
typeOfFile = 'docx';
|
|
2221
2377
|
} else if (file[0].type === 'application/msword') {
|
|
2222
|
-
|
|
2223
|
-
change(file);
|
|
2224
|
-
setSingleFile(file);
|
|
2378
|
+
typeOfFile = 'doc';
|
|
2225
2379
|
} else if (file[0].type === 'application/pdf') {
|
|
2226
|
-
|
|
2227
|
-
change(file);
|
|
2228
|
-
setSingleFile(file);
|
|
2380
|
+
typeOfFile = 'pdf';
|
|
2229
2381
|
} else if (file[0].type === 'image/heif' || file[0].type === 'image/heic' || file[0].name.toLowerCase().endsWith('.heic') || file[0].name.toLowerCase().endsWith('.heif')) {
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2382
|
+
typeOfFile = 'heic';
|
|
2383
|
+
} else if (file[0].type === 'image/jpeg') {
|
|
2384
|
+
typeOfFile = 'jpg';
|
|
2385
|
+
} else if (file[0].type === 'image/png') {
|
|
2386
|
+
typeOfFile = 'png';
|
|
2387
|
+
} else if (file[0].type === 'image/svg+xml') {
|
|
2388
|
+
typeOfFile = 'svg';
|
|
2389
|
+
}
|
|
2390
|
+
handleCheckFileFormat(file[0], typeOfFile).then(() => {
|
|
2391
|
+
if (typeOfFile === 'svg' || typeOfFile === 'png' || typeOfFile === 'jpg') {
|
|
2392
|
+
setImage(URL.createObjectURL(file[0]));
|
|
2393
|
+
} else {
|
|
2394
|
+
setImage(typeOfFile);
|
|
2395
|
+
}
|
|
2239
2396
|
change(file);
|
|
2240
2397
|
setSingleFile(file);
|
|
2241
|
-
|
|
2242
|
-
|
|
2398
|
+
}).catch(() => {
|
|
2399
|
+
setImage(null);
|
|
2400
|
+
setError(formatValidateError ?? configStyles.FILE.error.formatValidate);
|
|
2401
|
+
});
|
|
2243
2402
|
} else {
|
|
2244
2403
|
setImage(null);
|
|
2245
2404
|
setError(formatError ?? configStyles.FILE.error.format);
|
|
@@ -2496,10 +2655,10 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2496
2655
|
style: {
|
|
2497
2656
|
width: '100%',
|
|
2498
2657
|
color: labelColor ?? configStyles.FILE.label.color,
|
|
2499
|
-
fontSize:
|
|
2500
|
-
fontStyle:
|
|
2501
|
-
fontWeight:
|
|
2502
|
-
fontFamily:
|
|
2658
|
+
fontSize: labelFontSize ?? configStyles.FILE.label.font.size,
|
|
2659
|
+
fontStyle: labelFontStyle ?? configStyles.FILE.label.font.style,
|
|
2660
|
+
fontWeight: labelFontWeight ?? configStyles.FILE.label.font.weight,
|
|
2661
|
+
fontFamily: labelFontFamily ?? configStyles.FILE.label.font.family,
|
|
2503
2662
|
whiteSpace: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.FILE.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.FILE.label.showMore) && !showMore ? 'nowrap' : 'normal',
|
|
2504
2663
|
overflow: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.FILE.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.FILE.label.showMore) && !showMore ? 'hidden' : 'visible',
|
|
2505
2664
|
textOverflow: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.FILE.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.FILE.label.showMore) && !showMore ? 'ellipsis' : '',
|
|
@@ -2510,20 +2669,20 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2510
2669
|
}, label, handleCheckTextWidth('label') === 'more' && showMore && (lableShowMore || configStyles.FILE.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2511
2670
|
className: styles$c['show-more-text'],
|
|
2512
2671
|
style: {
|
|
2513
|
-
fontSize:
|
|
2514
|
-
fontStyle:
|
|
2515
|
-
fontWeight:
|
|
2516
|
-
fontFamily:
|
|
2672
|
+
fontSize: labelFontSize ?? configStyles.FILE.label.font.size,
|
|
2673
|
+
fontStyle: labelFontStyle ?? configStyles.FILE.label.font.style,
|
|
2674
|
+
fontWeight: labelFontWeight ?? configStyles.FILE.label.font.weight,
|
|
2675
|
+
fontFamily: labelFontFamily ?? configStyles.FILE.label.font.family,
|
|
2517
2676
|
color: showMoreTextColor ?? configStyles.FILE.label.showMoreTextColor
|
|
2518
2677
|
},
|
|
2519
2678
|
onClick: handleChangeShowMore
|
|
2520
2679
|
}, ' ', " ", labelShowLessText ?? configStyles.FILE.label.showLessText) : ''), required && /*#__PURE__*/React__default["default"].createElement("sup", null, iconRequired ? iconRequired : configStyles.FILE.icon.required ? configStyles.FILE.icon.required : /*#__PURE__*/React__default["default"].createElement(SvgRequired, null)), handleCheckTextWidth('label') === 'more' && !showMore && (lableShowMore || configStyles.FILE.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2521
2680
|
className: styles$c['show-more-text'],
|
|
2522
2681
|
style: {
|
|
2523
|
-
fontSize:
|
|
2524
|
-
fontStyle:
|
|
2525
|
-
fontWeight:
|
|
2526
|
-
fontFamily:
|
|
2682
|
+
fontSize: labelFontSize ?? configStyles.FILE.label.font.size,
|
|
2683
|
+
fontStyle: labelFontStyle ?? configStyles.FILE.label.font.style,
|
|
2684
|
+
fontWeight: labelFontWeight ?? configStyles.FILE.label.font.weight,
|
|
2685
|
+
fontFamily: labelFontFamily ?? configStyles.FILE.label.font.family,
|
|
2527
2686
|
color: showMoreTextColor ?? configStyles.FILE.label.showMoreTextColor
|
|
2528
2687
|
},
|
|
2529
2688
|
onClick: handleChangeShowMore
|
|
@@ -2544,9 +2703,9 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2544
2703
|
height: height ?? configStyles.FILE.height,
|
|
2545
2704
|
borderWidth: borderWidth ?? configStyles.FILE.border.width,
|
|
2546
2705
|
borderStyle: borderStyle ?? configStyles.FILE.border.style,
|
|
2547
|
-
borderRadius:
|
|
2706
|
+
borderRadius: borderRadius ?? configStyles.FILE.radius,
|
|
2548
2707
|
backgroundColor: backgroundColor ?? configStyles.FILE.colors.background,
|
|
2549
|
-
borderColor: error ? errorColor ? errorColor : configStyles.FILE.error.color : disabled ? borderColor ? borderColor : configStyles.FILE.border.color : isHover ? borderHoverColor ? borderHoverColor : configStyles.FILE.border.colors.hover : borderColor ? borderColor : configStyles.FILE.border.color
|
|
2708
|
+
borderColor: !multiple && error ? errorColor ? errorColor : configStyles.FILE.error.color : disabled ? borderColor ? borderColor : configStyles.FILE.border.color : isHover ? borderHoverColor ? borderHoverColor : configStyles.FILE.border.colors.hover : borderColor ? borderColor : configStyles.FILE.border.color
|
|
2550
2709
|
},
|
|
2551
2710
|
onDrop: handleDrop,
|
|
2552
2711
|
onClick: handleClick,
|
|
@@ -2571,10 +2730,10 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2571
2730
|
flexDirection: 'column',
|
|
2572
2731
|
justifyContent: 'center',
|
|
2573
2732
|
color: color ?? configStyles.FILE.color,
|
|
2574
|
-
fontSize:
|
|
2575
|
-
fontStyle:
|
|
2576
|
-
fontFamily:
|
|
2577
|
-
fontWeight:
|
|
2733
|
+
fontSize: fontSize ?? configStyles.FILE.font.size,
|
|
2734
|
+
fontStyle: fontStyle ?? configStyles.FILE.font.style,
|
|
2735
|
+
fontFamily: fontFamily ?? configStyles.FILE.font.family,
|
|
2736
|
+
fontWeight: fontWeight ?? configStyles.FILE.font.weight
|
|
2578
2737
|
}
|
|
2579
2738
|
}, !multiple && image && preview ? image === 'svg' ? iconSvg ? iconSvg : configStyles.FILE.icon.svg ? configStyles.FILE.icon.svg : /*#__PURE__*/React__default["default"].createElement(SvgSvg, null) : 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", {
|
|
2580
2739
|
src: image,
|
|
@@ -2591,7 +2750,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2591
2750
|
style: {
|
|
2592
2751
|
margin: '0px'
|
|
2593
2752
|
}
|
|
2594
|
-
}, putFileHere ?? configStyles.FILE.putFileHere,
|
|
2753
|
+
}, putFileHere ?? configStyles.FILE.putFileHere, ' ', /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2595
2754
|
style: {
|
|
2596
2755
|
color: uploadColor ?? configStyles.FILE.uploadColor
|
|
2597
2756
|
}
|
|
@@ -2626,11 +2785,11 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2626
2785
|
}, showPreviewIconInSmallComponent ? !image ? /*#__PURE__*/React__default["default"].createElement(Button, {
|
|
2627
2786
|
contentWidth: true,
|
|
2628
2787
|
onClick: _ => _,
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
2632
|
-
|
|
2633
|
-
|
|
2788
|
+
fontFamily: uploadBtnFont ?? configStyles.FILE.uploadBtn.font.family,
|
|
2789
|
+
fontSize: uploadBtnSize ?? configStyles.FILE.uploadBtn.font.size,
|
|
2790
|
+
fontStyle: uploadBtnStyle ?? configStyles.FILE.uploadBtn.font.style,
|
|
2791
|
+
fontWeight: uploadBtnWeight ?? configStyles.FILE.uploadBtn.font.weight,
|
|
2792
|
+
text: uploadBtnLabel ?? configStyles.FILE.uploadBtn.label,
|
|
2634
2793
|
color: uploadBtnColor ?? configStyles.FILE.uploadBtn.color,
|
|
2635
2794
|
height: uploadBtnHeight ?? configStyles.FILE.uploadBtn.height,
|
|
2636
2795
|
hoverColor: uploadBtnHoverColor ?? configStyles.FILE.uploadBtn.colors.hover,
|
|
@@ -2639,11 +2798,11 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2639
2798
|
}) : image === 'svg' ? iconSvg ? iconSvg : configStyles.FILE.icon.svg ? configStyles.FILE.icon.svg : /*#__PURE__*/React__default["default"].createElement(SvgSvg, null) : 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) : singleFile[0].type === 'image/jpeg' ? iconJpeg ? iconJpeg : configStyles.FILE.icon.jpeg ? configStyles.FILE.icon.jpeg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpeg, null) : singleFile[0].type === 'image/png' ? iconPng ? iconPng : configStyles.FILE.icon.png ? configStyles.FILE.icon.png : /*#__PURE__*/React__default["default"].createElement(SvgListItemPng, null) : singleFile[0].type === 'image/jpg' ? iconJpeg ? iconJpg : configStyles.FILE.icon.jpg ? configStyles.FILE.icon.jpg : /*#__PURE__*/React__default["default"].createElement(SvgListItemJpg, null) : '' : /*#__PURE__*/React__default["default"].createElement(Button, {
|
|
2640
2799
|
contentWidth: true,
|
|
2641
2800
|
onClick: _ => _,
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
|
|
2646
|
-
|
|
2801
|
+
fontFamily: uploadBtnFont ?? configStyles.FILE.uploadBtn.font.family,
|
|
2802
|
+
fontSize: uploadBtnSize ?? configStyles.FILE.uploadBtn.font.size,
|
|
2803
|
+
fontStyle: uploadBtnStyle ?? configStyles.FILE.uploadBtn.font.style,
|
|
2804
|
+
fontWeight: uploadBtnWeight ?? configStyles.FILE.uploadBtn.font.weight,
|
|
2805
|
+
text: uploadBtnLabel ?? configStyles.FILE.uploadBtn.label,
|
|
2647
2806
|
color: uploadBtnColor ?? configStyles.FILE.uploadBtn.color,
|
|
2648
2807
|
height: uploadBtnHeight ?? configStyles.FILE.uploadBtn.height,
|
|
2649
2808
|
hoverColor: uploadBtnHoverColor ?? configStyles.FILE.uploadBtn.colors.hover,
|
|
@@ -2688,8 +2847,8 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2688
2847
|
boxSizing: 'border-box',
|
|
2689
2848
|
alignItems: 'flex-start',
|
|
2690
2849
|
justifyContent: 'flex-end',
|
|
2691
|
-
borderRadius:
|
|
2692
|
-
display: !multiple && !disabled && image &&
|
|
2850
|
+
borderRadius: borderRadius ?? configStyles.FILE.radius,
|
|
2851
|
+
display: !multiple && !disabled && image && isHover ? 'flex' : 'none',
|
|
2693
2852
|
backgroundColor: hiddenBackgroundColor ?? configStyles.FILE.colors.backgroundHidden
|
|
2694
2853
|
},
|
|
2695
2854
|
onClick: handleStopPropagation
|
|
@@ -2698,16 +2857,16 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2698
2857
|
cursor: 'pointer'
|
|
2699
2858
|
},
|
|
2700
2859
|
onClick: handleRemoveFile
|
|
2701
|
-
}, iconRemoveFile ? iconRemoveFile : configStyles.FILE.icon.removeFile ? configStyles.FILE.icon.removeFile : /*#__PURE__*/React__default["default"].createElement(SvgRemoveFile, null)))), error ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2860
|
+
}, iconRemoveFile ? iconRemoveFile : configStyles.FILE.icon.removeFile ? configStyles.FILE.icon.removeFile : /*#__PURE__*/React__default["default"].createElement(SvgRemoveFile, null)))), !multiple && error ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2702
2861
|
style: {
|
|
2703
|
-
marginTop: '6px',
|
|
2704
|
-
color: errorColor ?? configStyles.FILE.error.color,
|
|
2705
|
-
fontSize: errorSize ?? configStyles.FILE.error.font.size,
|
|
2706
|
-
fontStyle: errorStyle ?? configStyles.FILE.error.font.style,
|
|
2707
|
-
fontWeight: errorWeight ?? configStyles.FILE.error.font.weight,
|
|
2708
|
-
fontFamily: errorFamily ?? configStyles.FILE.error.font.family,
|
|
2709
|
-
alignItems: 'center',
|
|
2710
2862
|
columnGap: '5px',
|
|
2863
|
+
alignItems: 'center',
|
|
2864
|
+
color: errorColor ?? configStyles.FILE.error.color,
|
|
2865
|
+
fontSize: errorFontSize ?? configStyles.FILE.error.font.size,
|
|
2866
|
+
marginTop: errorMarginTop ?? configStyles.FILE.error.marginTop,
|
|
2867
|
+
fontStyle: errorFontStyle ?? configStyles.FILE.error.font.style,
|
|
2868
|
+
fontWeight: errorFontWeight ?? configStyles.FILE.error.font.weight,
|
|
2869
|
+
fontFamily: errorFontFamily ?? configStyles.FILE.error.font.family,
|
|
2711
2870
|
display: errorIconShow && (errorIcon || configStyles.FILE.error?.icon) ? 'inline-flex' : 'inline-block'
|
|
2712
2871
|
}
|
|
2713
2872
|
}, errorIconShow ? errorIcon ? errorIcon : configStyles.FILE.error?.icon ? configStyles.FILE.error?.icon : '' : '', error) : '', multiple && memoizedItems && memoizedItems.length > 0 && memoizedItems.map(item => {
|
|
@@ -2730,7 +2889,7 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2730
2889
|
iconDelItem: iconDeleteItem ?? configStyles.FILE.icon.deleteItem,
|
|
2731
2890
|
timeForRemoveError: timeForRemoveError,
|
|
2732
2891
|
removeFile: removeFile ? removeFile : _ => _,
|
|
2733
|
-
radius:
|
|
2892
|
+
radius: borderRadius ?? configStyles.FILE.radius,
|
|
2734
2893
|
fileFormat: item?.file?.type.split('/')[1]?.toLowerCase(),
|
|
2735
2894
|
progressColor: progressColor ?? configStyles.FILE.progress.color,
|
|
2736
2895
|
listItemHeight: listItemHeight ?? configStyles.FILE.listItem.height,
|
|
@@ -2754,34 +2913,33 @@ const File = /*#__PURE__*/React.forwardRef(({
|
|
|
2754
2913
|
}));
|
|
2755
2914
|
});
|
|
2756
2915
|
File.propTypes = {
|
|
2757
|
-
or: PropTypes__default["default"].string,
|
|
2758
|
-
size: PropTypes__default["default"].string,
|
|
2759
2916
|
preview: PropTypes__default["default"].bool,
|
|
2760
2917
|
label: PropTypes__default["default"].string,
|
|
2761
2918
|
color: PropTypes__default["default"].string,
|
|
2762
2919
|
height: PropTypes__default["default"].string,
|
|
2763
2920
|
disabled: PropTypes__default["default"].bool,
|
|
2764
|
-
|
|
2921
|
+
borderRadius: PropTypes__default["default"].string,
|
|
2765
2922
|
borderWidth: PropTypes__default["default"].string,
|
|
2766
2923
|
borderStyle: PropTypes__default["default"].string,
|
|
2767
2924
|
borderColor: PropTypes__default["default"].string,
|
|
2768
2925
|
required: PropTypes__default["default"].bool,
|
|
2769
2926
|
upload: PropTypes__default["default"].string,
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2927
|
+
fontSize: PropTypes__default["default"].string,
|
|
2928
|
+
fontWeight: PropTypes__default["default"].number,
|
|
2929
|
+
fontStyle: PropTypes__default["default"].string,
|
|
2930
|
+
fontFamily: PropTypes__default["default"].string,
|
|
2773
2931
|
maxSize: PropTypes__default["default"].number,
|
|
2774
2932
|
maxWidth: PropTypes__default["default"].string,
|
|
2775
2933
|
removeFile: PropTypes__default["default"].func,
|
|
2776
2934
|
className: PropTypes__default["default"].string,
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2935
|
+
errorFontSize: PropTypes__default["default"].string,
|
|
2936
|
+
errorFontStyle: PropTypes__default["default"].string,
|
|
2937
|
+
errorFontWeight: PropTypes__default["default"].string,
|
|
2938
|
+
errorFontFamily: PropTypes__default["default"].string,
|
|
2939
|
+
labelFontSize: PropTypes__default["default"].string,
|
|
2940
|
+
labelFontStyle: PropTypes__default["default"].string,
|
|
2941
|
+
labelFontWeight: PropTypes__default["default"].string,
|
|
2942
|
+
labelFontFamily: PropTypes__default["default"].string,
|
|
2785
2943
|
labelColor: PropTypes__default["default"].string,
|
|
2786
2944
|
lableShowMore: PropTypes__default["default"].bool,
|
|
2787
2945
|
labelShowLessText: PropTypes__default["default"].string,
|
|
@@ -2799,6 +2957,7 @@ File.propTypes = {
|
|
|
2799
2957
|
labelTooltipBackgroundColor: PropTypes__default["default"].string,
|
|
2800
2958
|
errorColor: PropTypes__default["default"].string,
|
|
2801
2959
|
formatError: PropTypes__default["default"].string,
|
|
2960
|
+
formatValidateError: PropTypes__default["default"].string,
|
|
2802
2961
|
putFileHere: PropTypes__default["default"].string,
|
|
2803
2962
|
uploadColor: PropTypes__default["default"].string,
|
|
2804
2963
|
defaultData: PropTypes__default["default"].object,
|
|
@@ -2806,6 +2965,7 @@ File.propTypes = {
|
|
|
2806
2965
|
maxSizeError: PropTypes__default["default"].string,
|
|
2807
2966
|
errorIcon: PropTypes__default["default"].element,
|
|
2808
2967
|
errorIconShow: PropTypes__default["default"].bool,
|
|
2968
|
+
errorMarginTop: PropTypes__default["default"].string,
|
|
2809
2969
|
errorMessage: PropTypes__default["default"].string,
|
|
2810
2970
|
fileSizeText: PropTypes__default["default"].string,
|
|
2811
2971
|
noChoosenFile: PropTypes__default["default"].string,
|
|
@@ -3219,6 +3379,7 @@ const TD = ({
|
|
|
3219
3379
|
orderFontSize,
|
|
3220
3380
|
tBodyFontSize,
|
|
3221
3381
|
openListColor,
|
|
3382
|
+
tBodyFontStyle,
|
|
3222
3383
|
orderFontStyle,
|
|
3223
3384
|
tBodyTextAlign,
|
|
3224
3385
|
orderFontFamily,
|
|
@@ -3312,6 +3473,7 @@ const TD = ({
|
|
|
3312
3473
|
padding: tBodyPadding,
|
|
3313
3474
|
fontSize: tBodyFontSize,
|
|
3314
3475
|
borderRight: borderRight,
|
|
3476
|
+
fontStyle: tBodyFontStyle,
|
|
3315
3477
|
textAlign: tBodyTextAlign,
|
|
3316
3478
|
fontFamily: tBodyFontFamily,
|
|
3317
3479
|
fontWeight: tBodyFontWeight,
|
|
@@ -3605,7 +3767,7 @@ const Table = ({
|
|
|
3605
3767
|
tableColumnMaxWidth,
|
|
3606
3768
|
tableColumnMinWidth,
|
|
3607
3769
|
tHeadColor,
|
|
3608
|
-
|
|
3770
|
+
tHeadFontFamily,
|
|
3609
3771
|
tHeadPadding,
|
|
3610
3772
|
tHeadFontSize,
|
|
3611
3773
|
tHeadFontStyle,
|
|
@@ -3616,6 +3778,7 @@ const Table = ({
|
|
|
3616
3778
|
tBodyColor,
|
|
3617
3779
|
tBodyPadding,
|
|
3618
3780
|
tBodyFontSize,
|
|
3781
|
+
tBodyFontStyle,
|
|
3619
3782
|
tBodyTextAlign,
|
|
3620
3783
|
tBodyRowBorder,
|
|
3621
3784
|
tBodyBoxShadow,
|
|
@@ -4402,7 +4565,7 @@ const Table = ({
|
|
|
4402
4565
|
handleCheckedHeader: handleCheckedHeader,
|
|
4403
4566
|
handleHeaderItemClick: handleHeaderItemClick,
|
|
4404
4567
|
handleCheckArrowActionHeader: handleCheckArrowActionHeader,
|
|
4405
|
-
tHeadFamily:
|
|
4568
|
+
tHeadFamily: tHeadFontFamily ?? configStyles.TABLE.head.font.family,
|
|
4406
4569
|
tHeadPadding: tHeadPadding ?? configStyles.TABLE.head.padding,
|
|
4407
4570
|
tHeadFontSize: tHeadFontSize ?? configStyles.TABLE.head.font.size,
|
|
4408
4571
|
tHeadFontStyle: tHeadFontStyle ?? configStyles.TABLE.head.font.style,
|
|
@@ -4464,6 +4627,7 @@ const Table = ({
|
|
|
4464
4627
|
rowRadius: tableRowRadius ?? configStyles.TABLE.body.row.radius,
|
|
4465
4628
|
tBodyPadding: tBodyPadding ?? configStyles.TABLE.body.padding,
|
|
4466
4629
|
tBodyFontSize: tBodyFontSize ?? configStyles.TABLE.body.font.size,
|
|
4630
|
+
tBodyFontStyle: tBodyFontStyle ?? configStyles.TABLE.body.font.style,
|
|
4467
4631
|
tBodyTextAlign: tBodyTextAlign ?? configStyles.TABLE.textAlign,
|
|
4468
4632
|
tBodyFontFamily: tBodyFontFamily ?? configStyles.TABLE.body.font.family,
|
|
4469
4633
|
tBodyFontWeight: tBodyFontWeight ?? configStyles.TABLE.body.font.weight,
|
|
@@ -4540,7 +4704,7 @@ Table.propTypes = {
|
|
|
4540
4704
|
tableColumnMaxWidth: PropTypes__default["default"].string,
|
|
4541
4705
|
tableColumnMinWidth: PropTypes__default["default"].string,
|
|
4542
4706
|
tHeadColor: PropTypes__default["default"].string,
|
|
4543
|
-
|
|
4707
|
+
tHeadFontFamily: PropTypes__default["default"].string,
|
|
4544
4708
|
tHeadPadding: PropTypes__default["default"].string,
|
|
4545
4709
|
tHeadFontSize: PropTypes__default["default"].string,
|
|
4546
4710
|
tHeadFontStyle: PropTypes__default["default"].string,
|
|
@@ -4551,6 +4715,7 @@ Table.propTypes = {
|
|
|
4551
4715
|
tBodyColor: PropTypes__default["default"].string,
|
|
4552
4716
|
tBodyPadding: PropTypes__default["default"].string,
|
|
4553
4717
|
tBodyFontSize: PropTypes__default["default"].string,
|
|
4718
|
+
tBodyFontStyle: PropTypes__default["default"].string,
|
|
4554
4719
|
tBodyBoxShadow: PropTypes__default["default"].string,
|
|
4555
4720
|
tBodyTextAlign: PropTypes__default["default"].string,
|
|
4556
4721
|
tBodyFontWeight: PropTypes__default["default"].string,
|
|
@@ -4686,15 +4851,16 @@ const Modal = ({
|
|
|
4686
4851
|
data,
|
|
4687
4852
|
width,
|
|
4688
4853
|
loader,
|
|
4689
|
-
radius,
|
|
4690
4854
|
height,
|
|
4691
4855
|
padding,
|
|
4692
4856
|
setShow,
|
|
4857
|
+
underScroll,
|
|
4693
4858
|
zoomIcon,
|
|
4694
4859
|
prevIcon,
|
|
4695
4860
|
nextIcon,
|
|
4696
4861
|
closeIcon,
|
|
4697
4862
|
closeIconFix,
|
|
4863
|
+
borderRadius,
|
|
4698
4864
|
showCloseIcon,
|
|
4699
4865
|
closeIconClass,
|
|
4700
4866
|
closeSlideIcon,
|
|
@@ -4705,15 +4871,12 @@ const Modal = ({
|
|
|
4705
4871
|
minWidth,
|
|
4706
4872
|
minHeight,
|
|
4707
4873
|
className,
|
|
4708
|
-
|
|
4874
|
+
maxWidth,
|
|
4709
4875
|
alignItems,
|
|
4710
|
-
|
|
4876
|
+
maxHeight,
|
|
4711
4877
|
headerText,
|
|
4712
4878
|
imageWidth,
|
|
4713
|
-
headerSize,
|
|
4714
4879
|
headerIcon,
|
|
4715
|
-
headerStyle,
|
|
4716
|
-
headerFamily,
|
|
4717
4880
|
imageHeight,
|
|
4718
4881
|
headerColor,
|
|
4719
4882
|
borderStyle,
|
|
@@ -4722,13 +4885,16 @@ const Modal = ({
|
|
|
4722
4885
|
imageMargin,
|
|
4723
4886
|
showZoomIcon,
|
|
4724
4887
|
outsideClose,
|
|
4725
|
-
headerWeight,
|
|
4726
4888
|
headerHeight,
|
|
4727
4889
|
justifyContent,
|
|
4890
|
+
headerFontSize,
|
|
4728
4891
|
headerTextAlign,
|
|
4729
4892
|
backgroundColor,
|
|
4730
4893
|
imageWrapHeight,
|
|
4731
4894
|
grayDecorHeight,
|
|
4895
|
+
headerFontStyle,
|
|
4896
|
+
headerFontFamily,
|
|
4897
|
+
headerFontWeight,
|
|
4732
4898
|
headerIconMaxWidth,
|
|
4733
4899
|
headerIconMaxHeight,
|
|
4734
4900
|
layerBackgroundColor,
|
|
@@ -4836,7 +5002,17 @@ const Modal = ({
|
|
|
4836
5002
|
newConfigStyles = {
|
|
4837
5003
|
...data
|
|
4838
5004
|
};
|
|
4839
|
-
if (
|
|
5005
|
+
if (underScroll === undefined) {
|
|
5006
|
+
if (newConfigStyles.MODAL && hasOwnerProperty(newConfigStyles.MODAL, 'underScroll') && newConfigStyles.MODAL.underScroll === false) {
|
|
5007
|
+
style.textContent = `.tui-no-srcoll-class{overflow:hidden!important;}`;
|
|
5008
|
+
document.head.appendChild(style);
|
|
5009
|
+
document.body.classList.add('tui-no-srcoll-class');
|
|
5010
|
+
document.documentElement.classList.add('tui-no-srcoll-class');
|
|
5011
|
+
document.documentElement.addEventListener('touchmove', ResetTouchRemove, {
|
|
5012
|
+
passive: false
|
|
5013
|
+
});
|
|
5014
|
+
}
|
|
5015
|
+
} else if (underScroll === false) {
|
|
4840
5016
|
style.textContent = `.tui-no-srcoll-class{overflow:hidden!important;}`;
|
|
4841
5017
|
document.head.appendChild(style);
|
|
4842
5018
|
document.body.classList.add('tui-no-srcoll-class');
|
|
@@ -4857,7 +5033,17 @@ const Modal = ({
|
|
|
4857
5033
|
return () => {
|
|
4858
5034
|
setSelect(0);
|
|
4859
5035
|
setInnerData([]);
|
|
4860
|
-
if (
|
|
5036
|
+
if (underScroll === undefined) {
|
|
5037
|
+
if (newConfigStyles.MODAL && hasOwnerProperty(newConfigStyles.MODAL, 'underScroll') && newConfigStyles.MODAL.underScroll === false) {
|
|
5038
|
+
const noScrllable = document.getElementsByClassName('tui-no-srcoll-class');
|
|
5039
|
+
if (noScrllable) {
|
|
5040
|
+
style.remove();
|
|
5041
|
+
document.body.classList.remove('tui-no-srcoll-class');
|
|
5042
|
+
document.documentElement.classList.remove('tui-no-srcoll-class');
|
|
5043
|
+
document.documentElement.removeEventListener('touchmove', ResetTouchRemove);
|
|
5044
|
+
}
|
|
5045
|
+
}
|
|
5046
|
+
} else if (underScroll === false) {
|
|
4861
5047
|
const noScrllable = document.getElementsByClassName('tui-no-srcoll-class');
|
|
4862
5048
|
if (noScrllable) {
|
|
4863
5049
|
style.remove();
|
|
@@ -4881,7 +5067,7 @@ const Modal = ({
|
|
|
4881
5067
|
left: '0px',
|
|
4882
5068
|
zIndex: 999,
|
|
4883
5069
|
width: '100%',
|
|
4884
|
-
height: '
|
|
5070
|
+
height: '100dvh',
|
|
4885
5071
|
position: 'fixed',
|
|
4886
5072
|
backgroundColor: layerBackgroundColor ?? configStyles.MODAL.colors.backgroundLayer
|
|
4887
5073
|
}
|
|
@@ -4890,7 +5076,7 @@ const Modal = ({
|
|
|
4890
5076
|
position: 'relative',
|
|
4891
5077
|
display: 'flex',
|
|
4892
5078
|
width: '100%',
|
|
4893
|
-
height: '
|
|
5079
|
+
height: '100dvh',
|
|
4894
5080
|
alignItems: alignItems ?? configStyles.MODAL.alignItems,
|
|
4895
5081
|
justifyContent: justifyContent ?? configStyles.MODAL.justifyContent
|
|
4896
5082
|
}
|
|
@@ -4904,10 +5090,10 @@ const Modal = ({
|
|
|
4904
5090
|
height: height ?? configStyles.MODAL.height,
|
|
4905
5091
|
display: type === 'content' ? 'grid' : 'block',
|
|
4906
5092
|
overflow: type === 'content' ? 'auto' : 'hidden',
|
|
4907
|
-
|
|
4908
|
-
|
|
4909
|
-
maxHeight: mMaxHeight ?? configStyles.MODAL.maxHeight,
|
|
5093
|
+
maxWidth: maxWidth ?? configStyles.MODAL.maxWidth,
|
|
5094
|
+
maxHeight: maxHeight ?? configStyles.MODAL.maxHeight,
|
|
4910
5095
|
gridTemplateRows: type === 'content' ? 'auto 10fr' : '',
|
|
5096
|
+
borderRadius: borderRadius ?? configStyles.MODAL.border.radius,
|
|
4911
5097
|
minWidth: type === 'content' ? minWidth ?? configStyles.MODAL.minWidth : '',
|
|
4912
5098
|
backgroundColor: backgroundColor ?? configStyles.MODAL.colors.background,
|
|
4913
5099
|
minHeight: type === 'content' ? minHeight ?? configStyles.MODAL.minHeight : ''
|
|
@@ -4944,11 +5130,11 @@ const Modal = ({
|
|
|
4944
5130
|
textOverflow: 'ellipsis',
|
|
4945
5131
|
margin: '0px 16px 0px 0px',
|
|
4946
5132
|
color: headerColor ?? configStyles.MODAL.header.color,
|
|
4947
|
-
fontSize:
|
|
5133
|
+
fontSize: headerFontSize ?? configStyles.MODAL.header.font.size,
|
|
4948
5134
|
textAlign: headerTextAlign ?? configStyles.MODAL.header.align,
|
|
4949
|
-
fontStyle:
|
|
4950
|
-
fontFamily:
|
|
4951
|
-
fontWeight:
|
|
5135
|
+
fontStyle: headerFontStyle ?? configStyles.MODAL.header.font.style,
|
|
5136
|
+
fontFamily: headerFontFamily ?? configStyles.MODAL.header.font.family,
|
|
5137
|
+
fontWeight: headerFontWeight ?? configStyles.MODAL.header.font.weight
|
|
4952
5138
|
}
|
|
4953
5139
|
}, headerText), showCloseIcon ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4954
5140
|
onClick: () => setShow(false),
|
|
@@ -5040,7 +5226,7 @@ const Modal = ({
|
|
|
5040
5226
|
display: 'block',
|
|
5041
5227
|
objectFit: 'contain',
|
|
5042
5228
|
margin: imageMargin ?? configStyles.MODAL.image.margin,
|
|
5043
|
-
borderRadius:
|
|
5229
|
+
borderRadius: borderRadius ?? configStyles.MODAL.border.radius,
|
|
5044
5230
|
width: imageWidth ?? configStyles.MODAL.image.width,
|
|
5045
5231
|
height: imageHeight ?? configStyles.MODAL.image.height
|
|
5046
5232
|
},
|
|
@@ -5103,12 +5289,12 @@ Modal.propTypes = {
|
|
|
5103
5289
|
type: PropTypes__default["default"].string,
|
|
5104
5290
|
setShow: PropTypes__default["default"].func,
|
|
5105
5291
|
width: PropTypes__default["default"].string,
|
|
5106
|
-
radius: PropTypes__default["default"].string,
|
|
5107
5292
|
height: PropTypes__default["default"].string,
|
|
5108
5293
|
padding: PropTypes__default["default"].string,
|
|
5109
5294
|
selected: PropTypes__default["default"].number,
|
|
5110
5295
|
minWidth: PropTypes__default["default"].string,
|
|
5111
|
-
|
|
5296
|
+
maxWidth: PropTypes__default["default"].string,
|
|
5297
|
+
underScroll: PropTypes__default["default"].bool,
|
|
5112
5298
|
minHeight: PropTypes__default["default"].string,
|
|
5113
5299
|
className: PropTypes__default["default"].string,
|
|
5114
5300
|
zoomIcon: PropTypes__default["default"].element,
|
|
@@ -5117,21 +5303,22 @@ Modal.propTypes = {
|
|
|
5117
5303
|
closeIcon: PropTypes__default["default"].element,
|
|
5118
5304
|
closeIconFix: PropTypes__default["default"].bool,
|
|
5119
5305
|
showCloseIcon: PropTypes__default["default"].bool,
|
|
5306
|
+
borderRadius: PropTypes__default["default"].string,
|
|
5120
5307
|
closeIconClass: PropTypes__default["default"].string,
|
|
5121
5308
|
closeSlideIcon: PropTypes__default["default"].element,
|
|
5122
5309
|
closeIconTopPosition: PropTypes__default["default"].string,
|
|
5123
5310
|
closeIconRightPosition: PropTypes__default["default"].string,
|
|
5124
5311
|
headerText: PropTypes__default["default"].string,
|
|
5125
|
-
|
|
5126
|
-
|
|
5312
|
+
headerFontSize: PropTypes__default["default"].string,
|
|
5313
|
+
headerFontStyle: PropTypes__default["default"].string,
|
|
5127
5314
|
headerIcon: PropTypes__default["default"].element,
|
|
5128
|
-
|
|
5315
|
+
headerFontFamily: PropTypes__default["default"].string,
|
|
5129
5316
|
headerTextAlign: PropTypes__default["default"].string,
|
|
5130
5317
|
headerIconMaxWidth: PropTypes__default["default"].string,
|
|
5131
5318
|
headerIconMaxHeight: PropTypes__default["default"].string,
|
|
5132
5319
|
headerIconMarginRight: PropTypes__default["default"].string,
|
|
5133
5320
|
alignItems: PropTypes__default["default"].string,
|
|
5134
|
-
|
|
5321
|
+
maxHeight: PropTypes__default["default"].string,
|
|
5135
5322
|
imageWidth: PropTypes__default["default"].string,
|
|
5136
5323
|
outsideClose: PropTypes__default["default"].bool,
|
|
5137
5324
|
showZoomIcon: PropTypes__default["default"].bool,
|
|
@@ -5140,7 +5327,7 @@ Modal.propTypes = {
|
|
|
5140
5327
|
borderWidth: PropTypes__default["default"].string,
|
|
5141
5328
|
headerColor: PropTypes__default["default"].string,
|
|
5142
5329
|
imageHeight: PropTypes__default["default"].string,
|
|
5143
|
-
|
|
5330
|
+
headerFontWeight: PropTypes__default["default"].string,
|
|
5144
5331
|
headerHeight: PropTypes__default["default"].string,
|
|
5145
5332
|
justifyContent: PropTypes__default["default"].string,
|
|
5146
5333
|
backgroundColor: PropTypes__default["default"].string,
|
|
@@ -5478,7 +5665,7 @@ const NumberInput = ({
|
|
|
5478
5665
|
});
|
|
5479
5666
|
};
|
|
5480
5667
|
|
|
5481
|
-
var css_248z$a = ".input-module_input-wrap__NunrE{
|
|
5668
|
+
var css_248z$a = ".input-module_input-wrap__NunrE{width:100%}.input-module_input-content__kP7lZ{appearance:none!important;-webkit-appearance:none!important;display:flex;width:100%}.input-module_show-more-text__PQC9x{align-self:self-end;cursor:pointer}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)}}";
|
|
5482
5669
|
var styles$9 = {"input-wrap":"input-module_input-wrap__NunrE","input-content":"input-module_input-content__kP7lZ","show-more-text":"input-module_show-more-text__PQC9x","error-message-show":"input-module_error-message-show__OrVSo","error-show":"input-module_error-show__9MP6k","inp-num":"input-module_inp-num__vH7HL"};
|
|
5483
5670
|
styleInject(css_248z$a);
|
|
5484
5671
|
|
|
@@ -5497,60 +5684,61 @@ const P = styled__default["default"].span`
|
|
|
5497
5684
|
`;
|
|
5498
5685
|
const Input = ({
|
|
5499
5686
|
ssn,
|
|
5500
|
-
size,
|
|
5501
5687
|
name,
|
|
5502
|
-
|
|
5688
|
+
fontSize,
|
|
5689
|
+
fontStyle,
|
|
5690
|
+
fontWeight,
|
|
5691
|
+
fontFamily,
|
|
5692
|
+
borderRadius,
|
|
5503
5693
|
color,
|
|
5504
5694
|
value,
|
|
5505
5695
|
width,
|
|
5506
5696
|
regexp,
|
|
5507
5697
|
height,
|
|
5508
|
-
radius,
|
|
5509
5698
|
change,
|
|
5510
|
-
weight,
|
|
5511
|
-
family,
|
|
5512
5699
|
padding,
|
|
5513
5700
|
telClass,
|
|
5514
5701
|
leftIcon,
|
|
5515
5702
|
required,
|
|
5516
5703
|
disabled,
|
|
5517
|
-
errorDots,
|
|
5518
|
-
errorIcon,
|
|
5519
5704
|
iconWidth,
|
|
5520
5705
|
rightIcon,
|
|
5521
5706
|
className,
|
|
5522
5707
|
boxSizing,
|
|
5523
5708
|
boxShadow,
|
|
5524
|
-
errorLeft,
|
|
5525
|
-
errorSize,
|
|
5526
5709
|
maxLength,
|
|
5527
5710
|
floatToFix,
|
|
5528
5711
|
minNumSize,
|
|
5529
5712
|
maxNumSize,
|
|
5530
|
-
errorColor,
|
|
5531
5713
|
withoutDot,
|
|
5532
|
-
errorStyle,
|
|
5533
5714
|
iconPadding,
|
|
5534
|
-
errorAction,
|
|
5535
5715
|
placeholder,
|
|
5536
|
-
errorZindex,
|
|
5537
|
-
errorWeight,
|
|
5538
|
-
errorFamily,
|
|
5539
5716
|
phoneDisplay,
|
|
5540
|
-
errorMessage,
|
|
5541
5717
|
autoComplete,
|
|
5542
5718
|
showLabelIcon,
|
|
5719
|
+
boxShadowHover,
|
|
5720
|
+
errorLeft,
|
|
5721
|
+
errorDots,
|
|
5722
|
+
errorIcon,
|
|
5723
|
+
errorColor,
|
|
5724
|
+
errorAction,
|
|
5725
|
+
errorZindex,
|
|
5726
|
+
errorMessage,
|
|
5543
5727
|
errorIconSide,
|
|
5544
5728
|
showErrorIcon,
|
|
5729
|
+
errorFontSize,
|
|
5545
5730
|
errorMarginTop,
|
|
5546
5731
|
errorBoxShadow,
|
|
5547
|
-
boxShadowHover,
|
|
5548
5732
|
errorClassName,
|
|
5549
|
-
|
|
5733
|
+
errorFontStyle,
|
|
5550
5734
|
errorLineHeight,
|
|
5735
|
+
errorIconMargin,
|
|
5736
|
+
errorFontWeight,
|
|
5737
|
+
errorFontFamily,
|
|
5738
|
+
errorInContent,
|
|
5739
|
+
phoneAlignItems,
|
|
5551
5740
|
numberMaxLength,
|
|
5552
5741
|
backgroundColor,
|
|
5553
|
-
errorIconMargin,
|
|
5554
5742
|
placeholderColor,
|
|
5555
5743
|
withZero = false,
|
|
5556
5744
|
regexpErrorMessage,
|
|
@@ -5562,19 +5750,19 @@ const Input = ({
|
|
|
5562
5750
|
backgroundDisableColor,
|
|
5563
5751
|
telBorderRightColorHover,
|
|
5564
5752
|
label,
|
|
5565
|
-
labelSize,
|
|
5566
5753
|
labelIcon,
|
|
5567
|
-
labelStyle,
|
|
5568
5754
|
labelColor,
|
|
5569
5755
|
labelAction,
|
|
5570
|
-
labelWeight,
|
|
5571
5756
|
labelDisplay,
|
|
5757
|
+
lableShowMore,
|
|
5572
5758
|
labelIconSide,
|
|
5759
|
+
labelFontSize,
|
|
5760
|
+
labelFontStyle,
|
|
5573
5761
|
labelIconMargin,
|
|
5762
|
+
labelFontWeight,
|
|
5574
5763
|
labelFontFamily,
|
|
5575
5764
|
labelLineHeight,
|
|
5576
5765
|
labelMarginBottom,
|
|
5577
|
-
lableShowMore,
|
|
5578
5766
|
labelShowLessText,
|
|
5579
5767
|
labelShowMoreText,
|
|
5580
5768
|
showMoreTextColor,
|
|
@@ -5611,10 +5799,10 @@ const Input = ({
|
|
|
5611
5799
|
cursor: disabled ? 'not-allowed' : 'auto',
|
|
5612
5800
|
height: height ?? configStyles.INPUT.height,
|
|
5613
5801
|
padding: padding ?? configStyles.INPUT.padding,
|
|
5614
|
-
fontSize:
|
|
5615
|
-
fontStyle:
|
|
5616
|
-
fontWeight:
|
|
5617
|
-
fontFamily:
|
|
5802
|
+
fontSize: fontSize ?? configStyles.INPUT.font.size,
|
|
5803
|
+
fontStyle: fontStyle ?? configStyles.INPUT.font.style,
|
|
5804
|
+
fontWeight: fontWeight ?? configStyles.INPUT.font.weight,
|
|
5805
|
+
fontFamily: fontFamily ?? configStyles.INPUT.font.family,
|
|
5618
5806
|
boxSizing: boxSizing ?? configStyles.INPUT.box.sizing,
|
|
5619
5807
|
color: innerErrorMessage && errorColor ? errorColor : color ? color : configStyles.INPUT.color,
|
|
5620
5808
|
backgroundColor: disabled ? backgroundDisableColor ? backgroundDisableColor : configStyles.INPUT.colors.backgroundDisable : backgroundColor ? backgroundColor : configStyles.INPUT.colors.background
|
|
@@ -5794,7 +5982,10 @@ const Input = ({
|
|
|
5794
5982
|
}, []);
|
|
5795
5983
|
return configStyles.INPUT && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5796
5984
|
ref: parentRef,
|
|
5797
|
-
className: classProps
|
|
5985
|
+
className: classProps,
|
|
5986
|
+
style: {
|
|
5987
|
+
position: (errorInContent ? errorInContent : configStyles.INPUT.error.inContent) ? 'static' : 'relative'
|
|
5988
|
+
}
|
|
5798
5989
|
}, /*#__PURE__*/React__default["default"].createElement("style", null, `.tui-color-placeholder::placeholder {
|
|
5799
5990
|
color: ${placeholderColor ?? configStyles.INPUT.colors.placeholder};
|
|
5800
5991
|
}`), label && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -5819,13 +6010,13 @@ const Input = ({
|
|
|
5819
6010
|
ref: labelRef,
|
|
5820
6011
|
style: {
|
|
5821
6012
|
color: labelColor ?? configStyles.INPUT.label.color,
|
|
5822
|
-
fontSize: labelSize ?? configStyles.INPUT.label.font.size,
|
|
5823
|
-
fontStyle: labelStyle ?? configStyles.INPUT.label.font.style,
|
|
5824
6013
|
display: labelDisplay ?? configStyles.INPUT.label.display,
|
|
5825
|
-
|
|
6014
|
+
fontSize: labelFontSize ?? configStyles.INPUT.label.font.size,
|
|
6015
|
+
fontStyle: labelFontStyle ?? configStyles.INPUT.label.font.style,
|
|
5826
6016
|
lineHeight: labelLineHeight ?? configStyles.INPUT.label.lineHeight,
|
|
5827
|
-
|
|
6017
|
+
fontWeight: labelFontWeight ?? configStyles.INPUT.label.font.weight,
|
|
5828
6018
|
fontFamily: labelFontFamily ?? configStyles.INPUT.label.font.family,
|
|
6019
|
+
marginBottom: labelMarginBottom ?? configStyles.INPUT.label.marginBottom,
|
|
5829
6020
|
whiteSpace: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.INPUT.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.INPUT.label.showMore) && !showMore ? 'nowrap' : 'normal',
|
|
5830
6021
|
overflow: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.INPUT.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.INPUT.label.showMore) && !showMore ? 'hidden' : 'visible',
|
|
5831
6022
|
textOverflow: (useLabelTooltip ? useLabelTooltip : (useLabelTooltip === null || useLabelTooltip === undefined) && configStyles.INPUT.label.useTooltip) || (lableShowMore ? lableShowMore : (lableShowMore === null || lableShowMore === undefined) && configStyles.INPUT.label.showMore) && !showMore ? 'ellipsis' : '',
|
|
@@ -5836,9 +6027,9 @@ const Input = ({
|
|
|
5836
6027
|
}, label, handleCheckTextWidth() === 'more' && showMore && (lableShowMore || configStyles.INPUT.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
5837
6028
|
className: styles$9['show-more-text'],
|
|
5838
6029
|
style: {
|
|
5839
|
-
fontSize:
|
|
5840
|
-
fontStyle:
|
|
5841
|
-
fontWeight:
|
|
6030
|
+
fontSize: labelFontSize ?? configStyles.INPUT.label.font.size,
|
|
6031
|
+
fontStyle: labelFontStyle ?? configStyles.INPUT.label.font.style,
|
|
6032
|
+
fontWeight: labelFontWeight ?? configStyles.INPUT.label.font.weight,
|
|
5842
6033
|
fontFamily: labelFontFamily ?? configStyles.INPUT.label.font.family,
|
|
5843
6034
|
color: showMoreTextColor ?? configStyles.INPUT.label.showMoreTextColor
|
|
5844
6035
|
},
|
|
@@ -5856,9 +6047,9 @@ const Input = ({
|
|
|
5856
6047
|
}) : '', handleCheckTextWidth() === 'more' && !showMore && (lableShowMore || configStyles.INPUT.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
5857
6048
|
className: styles$9['show-more-text'],
|
|
5858
6049
|
style: {
|
|
5859
|
-
fontSize:
|
|
5860
|
-
fontStyle:
|
|
5861
|
-
fontWeight:
|
|
6050
|
+
fontSize: labelFontSize ?? configStyles.INPUT.label.font.size,
|
|
6051
|
+
fontStyle: labelFontStyle ?? configStyles.INPUT.label.font.style,
|
|
6052
|
+
fontWeight: labelFontWeight ?? configStyles.INPUT.label.font.weight,
|
|
5862
6053
|
fontFamily: labelFontFamily ?? configStyles.INPUT.label.font.family,
|
|
5863
6054
|
color: showMoreTextColor ?? configStyles.INPUT.label.showMoreTextColor,
|
|
5864
6055
|
marginBottom: labelMarginBottom ?? configStyles.INPUT.label.marginBottom
|
|
@@ -5868,7 +6059,7 @@ const Input = ({
|
|
|
5868
6059
|
className: `${styles$9['input-content']}`,
|
|
5869
6060
|
style: {
|
|
5870
6061
|
width: width ?? configStyles.INPUT.width,
|
|
5871
|
-
borderRadius:
|
|
6062
|
+
borderRadius: borderRadius ?? configStyles.INPUT.radius,
|
|
5872
6063
|
boxShadow: innerErrorMessage ? errorBoxShadow ? errorBoxShadow : configStyles.INPUT.error.box.shadow : isHover && !disabled ? boxShadowHover ? boxShadowHover : configStyles.INPUT.box.shadowHover : boxShadow ? boxShadow : configStyles.INPUT.box.shadow
|
|
5873
6064
|
},
|
|
5874
6065
|
onMouseEnter: handleMouseEnter,
|
|
@@ -5884,8 +6075,8 @@ const Input = ({
|
|
|
5884
6075
|
width: iconWidth ?? configStyles.INPUT.iconWidth,
|
|
5885
6076
|
boxSizing: boxSizing ?? configStyles.INPUT.box.sizing,
|
|
5886
6077
|
padding: iconPadding ?? configStyles.INPUT.iconPadding,
|
|
5887
|
-
borderTopLeftRadius:
|
|
5888
|
-
borderBottomLeftRadius:
|
|
6078
|
+
borderTopLeftRadius: borderRadius ?? configStyles.INPUT.radius,
|
|
6079
|
+
borderBottomLeftRadius: borderRadius ?? configStyles.INPUT.radius,
|
|
5889
6080
|
backgroundColor: disabled ? backgroundDisableColor ? backgroundDisableColor : configStyles.INPUT.colors.backgroundDisable : backgroundColor ? backgroundColor : configStyles.INPUT.colors.background
|
|
5890
6081
|
}
|
|
5891
6082
|
}, type === 'password' ? show ? leftIcon[1] : leftIcon[0] : leftIcon[0]) : '', type === 'tel' ? /*#__PURE__*/React__default["default"].createElement(TelInput, {
|
|
@@ -5896,7 +6087,7 @@ const Input = ({
|
|
|
5896
6087
|
disabled: disabled,
|
|
5897
6088
|
inpStyles: inpStyles,
|
|
5898
6089
|
inpAttributes: inpAttributes,
|
|
5899
|
-
radius:
|
|
6090
|
+
radius: borderRadius ?? configStyles.INPUT.radius,
|
|
5900
6091
|
telClass: telClass ?? configStyles.INPUT.tel.className,
|
|
5901
6092
|
phoneDisplay: phoneDisplay ?? configStyles.INPUT.tel.display,
|
|
5902
6093
|
phoneAlignItems: phoneAlignItems ?? configStyles.INPUT.tel.alignItems,
|
|
@@ -5921,7 +6112,7 @@ const Input = ({
|
|
|
5921
6112
|
minNumSize: minNumSize ? minNumSize : '',
|
|
5922
6113
|
maxNumSize: maxNumSize ? maxNumSize : '',
|
|
5923
6114
|
setInnerErrorMessage: setInnerErrorMessage,
|
|
5924
|
-
radius:
|
|
6115
|
+
radius: borderRadius ?? configStyles.INPUT.radius,
|
|
5925
6116
|
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5926
6117
|
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
5927
6118
|
}) : type === 'password' ? /*#__PURE__*/React__default["default"].createElement(PassInput, {
|
|
@@ -5932,7 +6123,7 @@ const Input = ({
|
|
|
5932
6123
|
inputChange: change,
|
|
5933
6124
|
inpStyles: inpStyles,
|
|
5934
6125
|
inpAttributes: inpAttributes,
|
|
5935
|
-
radius:
|
|
6126
|
+
radius: borderRadius ?? configStyles.INPUT.radius,
|
|
5936
6127
|
maxLength: maxLength ?? configStyles.INPUT.maxLength,
|
|
5937
6128
|
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5938
6129
|
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
@@ -5943,7 +6134,7 @@ const Input = ({
|
|
|
5943
6134
|
inputChange: change,
|
|
5944
6135
|
inpStyles: inpStyles,
|
|
5945
6136
|
inpAttributes: inpAttributes,
|
|
5946
|
-
radius:
|
|
6137
|
+
radius: borderRadius ?? configStyles.INPUT.radius,
|
|
5947
6138
|
maxLength: maxLength ?? configStyles.INPUT.maxLength,
|
|
5948
6139
|
checkLeftIcon: leftIcon && leftIcon.length > 0 ? true : false,
|
|
5949
6140
|
checkRightIcon: rightIcon && rightIcon.length > 0 ? true : false
|
|
@@ -5958,8 +6149,8 @@ const Input = ({
|
|
|
5958
6149
|
width: iconWidth ?? configStyles.INPUT.iconWidth,
|
|
5959
6150
|
boxSizing: boxSizing ?? configStyles.INPUT.box.sizing,
|
|
5960
6151
|
padding: iconPadding ?? configStyles.INPUT.iconPadding,
|
|
5961
|
-
borderTopRightRadius:
|
|
5962
|
-
borderBottomRightRadius:
|
|
6152
|
+
borderTopRightRadius: borderRadius ?? configStyles.INPUT.radius,
|
|
6153
|
+
borderBottomRightRadius: borderRadius ?? configStyles.INPUT.radius,
|
|
5963
6154
|
backgroundColor: disabled ? backgroundDisableColor ? backgroundDisableColor : configStyles.INPUT.colors.backgroundDisable : backgroundColor ? backgroundColor : configStyles.INPUT.colors.background
|
|
5964
6155
|
}
|
|
5965
6156
|
}, type === 'password' ? show ? rightIcon[1] : rightIcon[0] : rightIcon[0]) : ''), innerErrorMessage ? /*#__PURE__*/React__default["default"].createElement(P
|
|
@@ -5969,16 +6160,17 @@ const Input = ({
|
|
|
5969
6160
|
margin: '0px',
|
|
5970
6161
|
display: 'flex',
|
|
5971
6162
|
alignItems: 'center',
|
|
5972
|
-
position: 'absolute',
|
|
6163
|
+
position: (errorInContent ? errorInContent : configStyles.INPUT.error.inContent) ? 'static' : 'absolute',
|
|
5973
6164
|
width: width ?? configStyles.INPUT.width,
|
|
5974
6165
|
left: errorLeft ?? configStyles.INPUT.error.left,
|
|
5975
6166
|
color: errorColor ?? configStyles.INPUT.error.color,
|
|
5976
6167
|
zIndex: errorZindex ?? configStyles.INPUT.error.zIndex,
|
|
5977
|
-
fontSize:
|
|
5978
|
-
fontStyle:
|
|
5979
|
-
fontFamily:
|
|
5980
|
-
fontWeight:
|
|
6168
|
+
fontSize: errorFontSize ?? configStyles.INPUT.error.font.size,
|
|
6169
|
+
fontStyle: errorFontStyle ?? configStyles.INPUT.error.font.style,
|
|
6170
|
+
fontFamily: errorFontFamily ?? configStyles.INPUT.error.font.family,
|
|
6171
|
+
fontWeight: errorFontWeight ?? configStyles.INPUT.error.font.weight,
|
|
5981
6172
|
lineHeight: errorLineHeight ?? configStyles.INPUT.error.lineHeight,
|
|
6173
|
+
marginTop: (errorInContent ? errorInContent : configStyles.INPUT.error.inContent) ? errorMarginTop ?? configStyles.INPUT.error.marginTop : '0px',
|
|
5982
6174
|
top: errorMarginTop ? `calc(100% + ${errorMarginTop})` : `calc(100% + ${configStyles.INPUT.error.marginTop})`,
|
|
5983
6175
|
transform: 'scale3d(1,1,1)'
|
|
5984
6176
|
},
|
|
@@ -6015,55 +6207,54 @@ const Input = ({
|
|
|
6015
6207
|
};
|
|
6016
6208
|
Input.propTypes = {
|
|
6017
6209
|
ssn: PropTypes__default["default"].bool,
|
|
6018
|
-
size: PropTypes__default["default"].string,
|
|
6019
6210
|
name: PropTypes__default["default"].string,
|
|
6020
6211
|
change: PropTypes__default["default"].func,
|
|
6021
|
-
|
|
6212
|
+
fontSize: PropTypes__default["default"].string,
|
|
6213
|
+
fontStyle: PropTypes__default["default"].string,
|
|
6214
|
+
fontWeight: PropTypes__default["default"].string,
|
|
6215
|
+
fontFamily: PropTypes__default["default"].string,
|
|
6022
6216
|
color: PropTypes__default["default"].string,
|
|
6023
6217
|
width: PropTypes__default["default"].string,
|
|
6024
6218
|
withZero: PropTypes__default["default"].bool,
|
|
6025
|
-
weight: PropTypes__default["default"].string,
|
|
6026
|
-
family: PropTypes__default["default"].string,
|
|
6027
6219
|
required: PropTypes__default["default"].bool,
|
|
6028
6220
|
disabled: PropTypes__default["default"].bool,
|
|
6029
6221
|
height: PropTypes__default["default"].string,
|
|
6030
|
-
radius: PropTypes__default["default"].string,
|
|
6031
6222
|
padding: PropTypes__default["default"].string,
|
|
6032
6223
|
cardNumber: PropTypes__default["default"].bool,
|
|
6033
6224
|
withoutDot: PropTypes__default["default"].bool,
|
|
6034
6225
|
className: PropTypes__default["default"].string,
|
|
6035
6226
|
iconWidth: PropTypes__default["default"].string,
|
|
6036
|
-
iconPadding: PropTypes__default["default"].string,
|
|
6037
6227
|
maxLength: PropTypes__default["default"].number,
|
|
6038
6228
|
floatToFix: PropTypes__default["default"].number,
|
|
6039
6229
|
minNumSize: PropTypes__default["default"].number,
|
|
6040
6230
|
maxNumSize: PropTypes__default["default"].number,
|
|
6041
|
-
|
|
6231
|
+
iconPadding: PropTypes__default["default"].string,
|
|
6042
6232
|
placeholder: PropTypes__default["default"].string,
|
|
6233
|
+
borderRadius: PropTypes__default["default"].string,
|
|
6043
6234
|
placeholderColor: PropTypes__default["default"].string,
|
|
6044
6235
|
phoneDisplay: PropTypes__default["default"].string,
|
|
6045
6236
|
autoComplete: PropTypes__default["default"].string,
|
|
6046
6237
|
errorDots: PropTypes__default["default"].bool,
|
|
6047
6238
|
errorLeft: PropTypes__default["default"].string,
|
|
6048
|
-
errorSize: PropTypes__default["default"].string,
|
|
6049
6239
|
errorIcon: PropTypes__default["default"].string,
|
|
6050
6240
|
errorAction: PropTypes__default["default"].func,
|
|
6051
6241
|
errorColor: PropTypes__default["default"].string,
|
|
6052
|
-
errorStyle: PropTypes__default["default"].string,
|
|
6053
6242
|
showErrorIcon: PropTypes__default["default"].bool,
|
|
6054
|
-
|
|
6055
|
-
|
|
6243
|
+
errorFontSize: PropTypes__default["default"].string,
|
|
6244
|
+
errorFontStyle: PropTypes__default["default"].string,
|
|
6245
|
+
errorFontWeight: PropTypes__default["default"].string,
|
|
6246
|
+
errorFontFamily: PropTypes__default["default"].string,
|
|
6056
6247
|
errorZindex: PropTypes__default["default"].string,
|
|
6057
|
-
errorIconSide: PropTypes__default["default"].oneOf(Object.values(IconSides)),
|
|
6058
6248
|
errorMessage: PropTypes__default["default"].string,
|
|
6059
|
-
|
|
6249
|
+
errorInContent: PropTypes__default["default"].bool,
|
|
6060
6250
|
errorMarginTop: PropTypes__default["default"].string,
|
|
6061
6251
|
errorClassName: PropTypes__default["default"].string,
|
|
6252
|
+
errorBoxShadow: PropTypes__default["default"].string,
|
|
6062
6253
|
errorIconMargin: PropTypes__default["default"].string,
|
|
6063
6254
|
errorLineHeight: PropTypes__default["default"].string,
|
|
6255
|
+
errorIconSide: PropTypes__default["default"].oneOf(Object.values(IconSides)),
|
|
6064
6256
|
boxSizing: PropTypes__default["default"].string,
|
|
6065
6257
|
boxShadow: PropTypes__default["default"].string,
|
|
6066
|
-
errorBoxShadow: PropTypes__default["default"].string,
|
|
6067
6258
|
boxShadowHover: PropTypes__default["default"].string,
|
|
6068
6259
|
phoneAlignItems: PropTypes__default["default"].string,
|
|
6069
6260
|
numberMaxLength: PropTypes__default["default"].number,
|
|
@@ -6086,14 +6277,14 @@ Input.propTypes = {
|
|
|
6086
6277
|
label: PropTypes__default["default"].string,
|
|
6087
6278
|
labelAction: PropTypes__default["default"].func,
|
|
6088
6279
|
labelIcon: PropTypes__default["default"].string,
|
|
6089
|
-
labelSize: PropTypes__default["default"].string,
|
|
6090
6280
|
labelColor: PropTypes__default["default"].string,
|
|
6091
|
-
labelStyle: PropTypes__default["default"].string,
|
|
6092
6281
|
showLabelIcon: PropTypes__default["default"].bool,
|
|
6093
|
-
labelWeight: PropTypes__default["default"].string,
|
|
6094
6282
|
labelDisplay: PropTypes__default["default"].string,
|
|
6095
6283
|
labelIconSide: PropTypes__default["default"].oneOf(Object.values(IconSides)),
|
|
6096
6284
|
labelLineHeight: PropTypes__default["default"].string,
|
|
6285
|
+
labelFontSize: PropTypes__default["default"].string,
|
|
6286
|
+
labelFontStyle: PropTypes__default["default"].string,
|
|
6287
|
+
labelFontWeight: PropTypes__default["default"].string,
|
|
6097
6288
|
labelFontFamily: PropTypes__default["default"].string,
|
|
6098
6289
|
labelIconMargin: PropTypes__default["default"].string,
|
|
6099
6290
|
labelMarginBottom: PropTypes__default["default"].string,
|
|
@@ -6336,23 +6527,20 @@ const Select = ({
|
|
|
6336
6527
|
keyNames,
|
|
6337
6528
|
selected,
|
|
6338
6529
|
className,
|
|
6339
|
-
marginTop,
|
|
6340
6530
|
arrowIcon,
|
|
6341
6531
|
closeIcon,
|
|
6342
|
-
errorZindex,
|
|
6343
|
-
errorMessage,
|
|
6344
6532
|
arrowNoRotate,
|
|
6345
6533
|
showCloseIcon,
|
|
6346
6534
|
defaultOption,
|
|
6347
6535
|
multipleCheckbox,
|
|
6348
6536
|
label,
|
|
6349
6537
|
labelColor,
|
|
6350
|
-
labelWeight,
|
|
6351
6538
|
labelDisplay,
|
|
6352
6539
|
labelFontSize,
|
|
6353
6540
|
labelFontStyle,
|
|
6354
6541
|
labelLineHeight,
|
|
6355
6542
|
labelFontFamily,
|
|
6543
|
+
labelFontWeight,
|
|
6356
6544
|
labelMarginBottom,
|
|
6357
6545
|
labelTextTransform,
|
|
6358
6546
|
lableShowMore,
|
|
@@ -6371,12 +6559,16 @@ const Select = ({
|
|
|
6371
6559
|
labelTooltipBackgroundColor,
|
|
6372
6560
|
cursor,
|
|
6373
6561
|
errorIcon,
|
|
6374
|
-
errorSize,
|
|
6375
6562
|
errorColor,
|
|
6376
|
-
|
|
6377
|
-
|
|
6378
|
-
errorWeight,
|
|
6563
|
+
errorZindex,
|
|
6564
|
+
errorMessage,
|
|
6379
6565
|
showErrorIcon,
|
|
6566
|
+
errorFontSize,
|
|
6567
|
+
errorInContent,
|
|
6568
|
+
errorMarginTop,
|
|
6569
|
+
errorFontStyle,
|
|
6570
|
+
errorFontFamily,
|
|
6571
|
+
errorFontWeight,
|
|
6380
6572
|
selectedColor,
|
|
6381
6573
|
selectedRadius,
|
|
6382
6574
|
selectedPadding,
|
|
@@ -6391,6 +6583,7 @@ const Select = ({
|
|
|
6391
6583
|
selectedTransition,
|
|
6392
6584
|
selectedBackgroundColor,
|
|
6393
6585
|
selectedDisableBackgroundColor,
|
|
6586
|
+
selectedDisablePlaceholderColor,
|
|
6394
6587
|
optionsBoxShadow,
|
|
6395
6588
|
optionsBorderRadius,
|
|
6396
6589
|
optionsBackgroundColor,
|
|
@@ -6642,8 +6835,8 @@ const Select = ({
|
|
|
6642
6835
|
ref: parentRef,
|
|
6643
6836
|
className: classProps,
|
|
6644
6837
|
style: {
|
|
6645
|
-
|
|
6646
|
-
|
|
6838
|
+
width: '100%',
|
|
6839
|
+
position: (errorInContent ? errorInContent : configStyles.SELECT.error.inContent) ? 'static' : 'relative'
|
|
6647
6840
|
}
|
|
6648
6841
|
}, label && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
6649
6842
|
style: {
|
|
@@ -6657,7 +6850,7 @@ const Select = ({
|
|
|
6657
6850
|
ref: labelRef,
|
|
6658
6851
|
style: {
|
|
6659
6852
|
color: labelColor ?? configStyles.SELECT.label.color,
|
|
6660
|
-
fontWeight:
|
|
6853
|
+
fontWeight: labelFontWeight ?? configStyles.SELECT.label.font.weight,
|
|
6661
6854
|
display: labelDisplay ?? configStyles.SELECT.label.display,
|
|
6662
6855
|
fontSize: labelFontSize ?? configStyles.SELECT.label.font.size,
|
|
6663
6856
|
fontStyle: labelFontStyle ?? configStyles.SELECT.label.font.style,
|
|
@@ -6677,7 +6870,7 @@ const Select = ({
|
|
|
6677
6870
|
style: {
|
|
6678
6871
|
fontSize: labelFontSize ?? configStyles.SELECT.label.font.size,
|
|
6679
6872
|
fontStyle: labelFontStyle ?? configStyles.SELECT.label.font.style,
|
|
6680
|
-
fontWeight:
|
|
6873
|
+
fontWeight: labelFontWeight ?? configStyles.SELECT.label.font.weight,
|
|
6681
6874
|
fontFamily: labelFontFamily ?? configStyles.SELECT.label.font.family,
|
|
6682
6875
|
color: showMoreTextColor ?? configStyles.SELECT.label.showMoreTextColor
|
|
6683
6876
|
},
|
|
@@ -6687,7 +6880,7 @@ const Select = ({
|
|
|
6687
6880
|
style: {
|
|
6688
6881
|
fontSize: labelFontSize ?? configStyles.SELECT.label.font.size,
|
|
6689
6882
|
fontStyle: labelFontStyle ?? configStyles.SELECT.label.font.style,
|
|
6690
|
-
fontWeight:
|
|
6883
|
+
fontWeight: labelFontWeight ?? configStyles.SELECT.label.font.weight,
|
|
6691
6884
|
fontFamily: labelFontFamily ?? configStyles.SELECT.label.font.family,
|
|
6692
6885
|
color: showMoreTextColor ?? configStyles.SELECT.label.showMoreTextColor,
|
|
6693
6886
|
marginBottom: labelMarginBottom ?? configStyles.INPUT.label.marginBottom
|
|
@@ -6724,7 +6917,7 @@ const Select = ({
|
|
|
6724
6917
|
whiteSpace: disabled ? 'pre-wrap' : 'nowrap',
|
|
6725
6918
|
overflow: insidePagination ? 'visible' : 'hidden',
|
|
6726
6919
|
textOverflow: insidePagination ? 'initial' : 'ellipsis',
|
|
6727
|
-
color: placeholderColor && !newSelected.length ? placeholderColor : isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selected.colors.hover : selectedColor ? selectedColor : configStyles.SELECT.selected.color
|
|
6920
|
+
color: disabled ? selectedDisablePlaceholderColor ? selectedDisablePlaceholderColor : configStyles.SELECT.selected.colors.placeholderDisable : placeholderColor && !newSelected.length ? placeholderColor : isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selected.colors.hover : selectedColor ? selectedColor : configStyles.SELECT.selected.color
|
|
6728
6921
|
}
|
|
6729
6922
|
}, !multiple && newSelected && newSelected[0] && newSelected[0][keyNames.name] ? newSelected[0][keyNames.name] : newSelected && newSelected.length > 0 ? newSelected.map((_, index) => {
|
|
6730
6923
|
if (newSelected[index][keyNames.name]) {
|
|
@@ -6791,16 +6984,17 @@ const Select = ({
|
|
|
6791
6984
|
}) : '', option[keyNames.name]);
|
|
6792
6985
|
}))) : null)), errorMessage ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
6793
6986
|
style: {
|
|
6794
|
-
position: 'absolute',
|
|
6987
|
+
position: (errorInContent ? errorInContent : configStyles.SELECT.error.inContent) ? 'static' : 'absolute',
|
|
6795
6988
|
columnGap: '4px',
|
|
6796
6989
|
color: errorColor ?? configStyles.SELECT.error.color,
|
|
6797
|
-
fontSize:
|
|
6798
|
-
fontStyle:
|
|
6799
|
-
display: errorIcon && showErrorIcon ? 'inline-flex' : 'inline',
|
|
6800
|
-
fontFamily:
|
|
6801
|
-
fontWeight:
|
|
6990
|
+
fontSize: errorFontSize ?? configStyles.SELECT.error.font.size,
|
|
6991
|
+
fontStyle: errorFontStyle ?? configStyles.SELECT.error.font.style,
|
|
6992
|
+
display: errorIcon && showErrorIcon ? 'inline-flex' : 'inline-block',
|
|
6993
|
+
fontFamily: errorFontFamily ?? configStyles.SELECT.error.font.family,
|
|
6994
|
+
fontWeight: errorFontWeight ?? configStyles.SELECT.error.font.weight,
|
|
6802
6995
|
zIndex: errorZindex ?? configStyles.SELECT.error.zIndex,
|
|
6803
|
-
|
|
6996
|
+
marginTop: (errorInContent ? errorInContent : configStyles.SELECT.error.inContent) ? errorMarginTop ?? configStyles.SELECT.error.marginTop : '0px',
|
|
6997
|
+
top: errorMarginTop ? `calc(100% + ${errorMarginTop})` : `calc(100% + ${configStyles.SELECT.error.marginTop})`
|
|
6804
6998
|
}
|
|
6805
6999
|
}, showErrorIcon ? errorIcon ? errorIcon : configStyles.SELECT.error?.icon ? configStyles.SELECT.error?.icon : '' : '', errorMessage) : '');
|
|
6806
7000
|
};
|
|
@@ -6814,24 +7008,21 @@ Select.propTypes = {
|
|
|
6814
7008
|
disabled: PropTypes__default["default"].bool,
|
|
6815
7009
|
selected: PropTypes__default["default"].array,
|
|
6816
7010
|
keyNames: PropTypes__default["default"].object,
|
|
6817
|
-
marginTop: PropTypes__default["default"].string,
|
|
6818
7011
|
className: PropTypes__default["default"].string,
|
|
6819
7012
|
arrowIcon: PropTypes__default["default"].element,
|
|
6820
7013
|
closeIcon: PropTypes__default["default"].element,
|
|
6821
7014
|
arrowNoRotate: PropTypes__default["default"].bool,
|
|
6822
7015
|
showCloseIcon: PropTypes__default["default"].bool,
|
|
6823
|
-
errorZindex: PropTypes__default["default"].number,
|
|
6824
|
-
errorMessage: PropTypes__default["default"].string,
|
|
6825
7016
|
defaultOption: PropTypes__default["default"].string,
|
|
6826
7017
|
multipleCheckbox: PropTypes__default["default"].bool,
|
|
6827
7018
|
label: PropTypes__default["default"].string,
|
|
6828
7019
|
labelColor: PropTypes__default["default"].string,
|
|
6829
|
-
labelWeight: PropTypes__default["default"].string,
|
|
6830
7020
|
labelDisplay: PropTypes__default["default"].string,
|
|
6831
7021
|
labelFontSize: PropTypes__default["default"].string,
|
|
6832
7022
|
labelFontStyle: PropTypes__default["default"].string,
|
|
6833
7023
|
labelLineHeight: PropTypes__default["default"].string,
|
|
6834
7024
|
labelFontFamily: PropTypes__default["default"].string,
|
|
7025
|
+
labelFontWeight: PropTypes__default["default"].string,
|
|
6835
7026
|
labelMarginBottom: PropTypes__default["default"].string,
|
|
6836
7027
|
labelTextTransform: PropTypes__default["default"].string,
|
|
6837
7028
|
lableShowMore: PropTypes__default["default"].bool,
|
|
@@ -6839,10 +7030,17 @@ Select.propTypes = {
|
|
|
6839
7030
|
labelShowMoreText: PropTypes__default["default"].string,
|
|
6840
7031
|
showMoreTextColor: PropTypes__default["default"].string,
|
|
6841
7032
|
cursor: PropTypes__default["default"].string,
|
|
6842
|
-
errorSize: PropTypes__default["default"].string,
|
|
6843
7033
|
errorColor: PropTypes__default["default"].string,
|
|
6844
7034
|
errorIcon: PropTypes__default["default"].element,
|
|
6845
7035
|
showErrorIcon: PropTypes__default["default"].bool,
|
|
7036
|
+
errorZindex: PropTypes__default["default"].number,
|
|
7037
|
+
errorInContent: PropTypes__default["default"].bool,
|
|
7038
|
+
errorMessage: PropTypes__default["default"].string,
|
|
7039
|
+
errorFontSize: PropTypes__default["default"].string,
|
|
7040
|
+
errorMarginTop: PropTypes__default["default"].string,
|
|
7041
|
+
errorFontStyle: PropTypes__default["default"].string,
|
|
7042
|
+
errorFontFamily: PropTypes__default["default"].string,
|
|
7043
|
+
errorFontWeight: PropTypes__default["default"].string,
|
|
6846
7044
|
selectedColor: PropTypes__default["default"].string,
|
|
6847
7045
|
selectedRadius: PropTypes__default["default"].string,
|
|
6848
7046
|
selectedMinHeight: PropTypes__default["default"].string,
|
|
@@ -6857,6 +7055,7 @@ Select.propTypes = {
|
|
|
6857
7055
|
selectedTransition: PropTypes__default["default"].string,
|
|
6858
7056
|
selectedBackgroundColor: PropTypes__default["default"].string,
|
|
6859
7057
|
selectedDisableBackgroundColor: PropTypes__default["default"].string,
|
|
7058
|
+
selectedDisablePlaceholderColor: PropTypes__default["default"].string,
|
|
6860
7059
|
optionsBoxShadow: PropTypes__default["default"].string,
|
|
6861
7060
|
optionsBorderRadius: PropTypes__default["default"].string,
|
|
6862
7061
|
optionsBackgroundColor: PropTypes__default["default"].string,
|
|
@@ -7187,9 +7386,9 @@ Toast.propTypes = {
|
|
|
7187
7386
|
type: PropTypes__default["default"].oneOf(Object.values(ToasterType)).isRequired
|
|
7188
7387
|
};
|
|
7189
7388
|
|
|
7190
|
-
let toastify = document.getElementById('toastify');
|
|
7191
7389
|
let path = window.location.href;
|
|
7192
7390
|
const removeToast = ref => {
|
|
7391
|
+
let toastify = document.getElementById('toastify');
|
|
7193
7392
|
if (ref.current) {
|
|
7194
7393
|
const node = ref.current;
|
|
7195
7394
|
const removeElem = node.parentNode;
|
|
@@ -7263,6 +7462,7 @@ const createToast = ({
|
|
|
7263
7462
|
styleProps,
|
|
7264
7463
|
description
|
|
7265
7464
|
}) => {
|
|
7465
|
+
let toastify = document.getElementById('toastify');
|
|
7266
7466
|
let innerConfigStyles = {};
|
|
7267
7467
|
let toastParentBlock;
|
|
7268
7468
|
if (!toastify) {
|
|
@@ -7362,6 +7562,7 @@ const Toaster = () => {
|
|
|
7362
7562
|
const [configStyles, setConfigStyles] = React.useState({});
|
|
7363
7563
|
window.addEventListener('popstate', () => {
|
|
7364
7564
|
if (path !== window.location.href) {
|
|
7565
|
+
let toastify = document.getElementById('toastify');
|
|
7365
7566
|
if (!toastify) {
|
|
7366
7567
|
toastify = document.createElement('div');
|
|
7367
7568
|
toastify.setAttribute('id', 'toastify');
|
|
@@ -7434,7 +7635,6 @@ const Tooltip = ({
|
|
|
7434
7635
|
width,
|
|
7435
7636
|
color,
|
|
7436
7637
|
height,
|
|
7437
|
-
radius,
|
|
7438
7638
|
fontSize,
|
|
7439
7639
|
hoverOpen,
|
|
7440
7640
|
className,
|
|
@@ -7442,9 +7642,10 @@ const Tooltip = ({
|
|
|
7442
7642
|
fontFamily,
|
|
7443
7643
|
fontWeight,
|
|
7444
7644
|
tooltipIcon,
|
|
7645
|
+
borderRadius,
|
|
7445
7646
|
tooltipWidth,
|
|
7446
|
-
tooltipRadius,
|
|
7447
7647
|
backgroundColor,
|
|
7648
|
+
tooltipBorderRadius,
|
|
7448
7649
|
tooltipBackgroundColor,
|
|
7449
7650
|
direction = 'top'
|
|
7450
7651
|
}) => {
|
|
@@ -7517,7 +7718,7 @@ const Tooltip = ({
|
|
|
7517
7718
|
style: {
|
|
7518
7719
|
width: width ?? configStyles.TOOLTIP.parent.width,
|
|
7519
7720
|
height: height ?? configStyles.TOOLTIP.parent.height,
|
|
7520
|
-
borderRadius:
|
|
7721
|
+
borderRadius: borderRadius ?? configStyles.TOOLTIP.parent.radius,
|
|
7521
7722
|
backgroundColor: backgroundColor ?? configStyles.TOOLTIP.parent.colors.background
|
|
7522
7723
|
},
|
|
7523
7724
|
onClick: e => e.stopPropagation()
|
|
@@ -7526,7 +7727,7 @@ const Tooltip = ({
|
|
|
7526
7727
|
className: `${styles$6['tooltip']}`,
|
|
7527
7728
|
style: {
|
|
7528
7729
|
width: tooltipWidth ?? configStyles.TOOLTIP.width,
|
|
7529
|
-
borderRadius:
|
|
7730
|
+
borderRadius: tooltipBorderRadius ?? configStyles.TOOLTIP.radius,
|
|
7530
7731
|
backgroundColor: tooltipBackgroundColor ?? configStyles.TOOLTIP.colors.background,
|
|
7531
7732
|
top: direction === 'top' || direction === 'top-left' || direction === 'top-right' ? `calc(-${checkTooltipHeight + 7}px)` : direction === 'bottom' || direction === 'bottom-left' || direction === 'bottom-right' ? 'calc(100% + 7px)' : direction === 'left' || direction === 'right' ? `calc(50% - ${checkTooltipHeight / 2}px)` : direction === 'left-top' || direction === 'right-top' ? '0px' : direction === 'left-bottom' || direction === 'right-bottom' ? `calc(-${checkTooltipHeight - tooltipIconParentHeight}px)` : '0px',
|
|
7532
7733
|
left: direction === 'top' || direction === 'bottom' ? `calc(50% - ${checkTooltipWidth / 2}px)` : direction === 'left' || direction === 'left-top' || direction === 'left-bottom' ? `-${checkTooltipWidth + 7}px` : direction === 'top-left' || direction === 'bottom-left' ? `0px` : direction === 'top-right' || direction === 'bottom-right' ? `-${checkTooltipWidth - tooltipIconParentWidth}px` : direction === 'right' || direction === 'right-top' || direction === 'right-bottom' ? 'calc(100% + 7px)' : '0px'
|
|
@@ -7563,16 +7764,16 @@ Tooltip.propTypes = {
|
|
|
7563
7764
|
width: PropTypes__default["default"].string,
|
|
7564
7765
|
color: PropTypes__default["default"].string,
|
|
7565
7766
|
height: PropTypes__default["default"].string,
|
|
7566
|
-
radius: PropTypes__default["default"].string,
|
|
7567
7767
|
hoverOpen: PropTypes__default["default"].bool,
|
|
7568
7768
|
fontSize: PropTypes__default["default"].string,
|
|
7569
7769
|
fontStyle: PropTypes__default["default"].string,
|
|
7570
7770
|
className: PropTypes__default["default"].string,
|
|
7571
7771
|
fontFamily: PropTypes__default["default"].string,
|
|
7572
7772
|
fontWeight: PropTypes__default["default"].string,
|
|
7773
|
+
borderRadius: PropTypes__default["default"].string,
|
|
7573
7774
|
tooltipWidth: PropTypes__default["default"].string,
|
|
7574
7775
|
tooltipIcon: PropTypes__default["default"].element,
|
|
7575
|
-
|
|
7776
|
+
tooltipBorderRadius: PropTypes__default["default"].string,
|
|
7576
7777
|
text: PropTypes__default["default"].string.isRequired,
|
|
7577
7778
|
backgroundColor: PropTypes__default["default"].string,
|
|
7578
7779
|
tooltipBackgroundColor: PropTypes__default["default"].string,
|
|
@@ -7938,16 +8139,11 @@ const PositionSide = {
|
|
|
7938
8139
|
BOTTOM: 'bottom'
|
|
7939
8140
|
};
|
|
7940
8141
|
const Textarea = ({
|
|
7941
|
-
size,
|
|
7942
8142
|
name,
|
|
7943
|
-
style,
|
|
7944
|
-
family,
|
|
7945
|
-
weight,
|
|
7946
8143
|
width,
|
|
7947
8144
|
value,
|
|
7948
8145
|
height,
|
|
7949
8146
|
resize,
|
|
7950
|
-
radius,
|
|
7951
8147
|
padding,
|
|
7952
8148
|
disabled,
|
|
7953
8149
|
required,
|
|
@@ -7959,25 +8155,31 @@ const Textarea = ({
|
|
|
7959
8155
|
maxHeight,
|
|
7960
8156
|
boxSizing,
|
|
7961
8157
|
maxLength,
|
|
7962
|
-
|
|
7963
|
-
|
|
7964
|
-
|
|
7965
|
-
|
|
7966
|
-
|
|
8158
|
+
fontSize,
|
|
8159
|
+
fontStyle,
|
|
8160
|
+
fontFamily,
|
|
8161
|
+
fontWeight,
|
|
8162
|
+
placeholder,
|
|
8163
|
+
borderRadius,
|
|
8164
|
+
errorMarginTop,
|
|
7967
8165
|
className,
|
|
7968
8166
|
errorColor,
|
|
7969
|
-
placeholder,
|
|
7970
8167
|
errorMessage,
|
|
8168
|
+
errorFontSize,
|
|
8169
|
+
errorFontStyle,
|
|
8170
|
+
errorFontWeight,
|
|
8171
|
+
errorFontFamily,
|
|
8172
|
+
borderWidth,
|
|
7971
8173
|
backgroundColor,
|
|
7972
8174
|
borderFocusColor,
|
|
7973
8175
|
borderHoverColor,
|
|
7974
8176
|
showCharacterCount,
|
|
7975
8177
|
label,
|
|
7976
|
-
labelSize,
|
|
7977
8178
|
labelColor,
|
|
7978
|
-
labelStyle,
|
|
7979
|
-
labelWeight,
|
|
7980
8179
|
labelDisplay,
|
|
8180
|
+
labelFontSize,
|
|
8181
|
+
labelFontStyle,
|
|
8182
|
+
labelFontWeight,
|
|
7981
8183
|
labelFontFamily,
|
|
7982
8184
|
labelMarginBottom,
|
|
7983
8185
|
lableShowMore,
|
|
@@ -8176,9 +8378,10 @@ const Textarea = ({
|
|
|
8176
8378
|
alignItems: 'center',
|
|
8177
8379
|
justifyContent: label ? 'space-between' : 'flex-end',
|
|
8178
8380
|
color: labelColor ?? configStyles.TEXTAREA.label.color,
|
|
8179
|
-
fontSize:
|
|
8381
|
+
fontSize: labelFontSize ?? configStyles.TEXTAREA.label.font.size,
|
|
8382
|
+
fontStyle: labelFontStyle ?? configStyles.TEXTAREA.label.font.style,
|
|
8180
8383
|
fontFamily: labelFontFamily ?? configStyles.TEXTAREA.label.font.family,
|
|
8181
|
-
fontWeight:
|
|
8384
|
+
fontWeight: labelFontWeight ?? configStyles.TEXTAREA.label.font.weight,
|
|
8182
8385
|
marginBottom: labelMarginBottom ?? configStyles.TEXTAREA.label.marginBottom
|
|
8183
8386
|
}
|
|
8184
8387
|
}, label && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -8203,9 +8406,9 @@ const Textarea = ({
|
|
|
8203
8406
|
}, label, handleCheckTextWidth() === 'more' && showMore && (lableShowMore || configStyles.TEXTAREA.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
8204
8407
|
className: styles$3['show-more-text'],
|
|
8205
8408
|
style: {
|
|
8206
|
-
fontSize:
|
|
8207
|
-
fontStyle:
|
|
8208
|
-
fontWeight:
|
|
8409
|
+
fontSize: labelFontSize ?? configStyles.TEXTAREA.label.font.size,
|
|
8410
|
+
fontStyle: labelFontStyle ?? configStyles.TEXTAREA.label.font.style,
|
|
8411
|
+
fontWeight: labelFontWeight ?? configStyles.TEXTAREA.label.font.weight,
|
|
8209
8412
|
fontFamily: labelFontFamily ?? configStyles.TEXTAREA.label.font.family,
|
|
8210
8413
|
color: showMoreTextColor ?? configStyles.TEXTAREA.label.showMoreTextColor
|
|
8211
8414
|
},
|
|
@@ -8213,9 +8416,9 @@ const Textarea = ({
|
|
|
8213
8416
|
}, ' ', " ", labelShowLessText ?? configStyles.TEXTAREA.label.showLessText) : ''), required && /*#__PURE__*/React__default["default"].createElement("sup", null, iconRequired ? iconRequired : configStyles.TEXTAREA.icon.required ? configStyles.TEXTAREA.icon.required : /*#__PURE__*/React__default["default"].createElement(SvgRequired, null)), handleCheckTextWidth() === 'more' && !showMore && (lableShowMore || configStyles.TEXTAREA.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
8214
8417
|
className: styles$3['show-more-text'],
|
|
8215
8418
|
style: {
|
|
8216
|
-
fontSize:
|
|
8217
|
-
fontStyle:
|
|
8218
|
-
fontWeight:
|
|
8419
|
+
fontSize: labelFontSize ?? configStyles.TEXTAREA.label.font.size,
|
|
8420
|
+
fontStyle: labelFontStyle ?? configStyles.TEXTAREA.label.font.style,
|
|
8421
|
+
fontWeight: labelFontWeight ?? configStyles.TEXTAREA.label.font.weight,
|
|
8219
8422
|
fontFamily: labelFontFamily ?? configStyles.TEXTAREA.label.font.family,
|
|
8220
8423
|
color: showMoreTextColor ?? configStyles.TEXTAREA.label.showMoreTextColor
|
|
8221
8424
|
},
|
|
@@ -8232,20 +8435,20 @@ const Textarea = ({
|
|
|
8232
8435
|
outline: 'none',
|
|
8233
8436
|
overflow: 'auto',
|
|
8234
8437
|
cursor: disabled ? 'not-allowed' : 'auto',
|
|
8235
|
-
fontSize: size ?? configStyles.TEXTAREA.font.size,
|
|
8236
|
-
fontStyle: style ?? configStyles.TEXTAREA.font.style,
|
|
8237
|
-
fontFamily: family ?? configStyles.TEXTAREA.font.family,
|
|
8238
|
-
fontWeight: weight ?? configStyles.TEXTAREA.font.weight,
|
|
8239
8438
|
height: height ?? configStyles.TEXTAREA.height,
|
|
8240
8439
|
padding: padding ?? configStyles.TEXTAREA.padding,
|
|
8241
|
-
borderRadius: radius ?? configStyles.TEXTAREA.radius,
|
|
8242
8440
|
minWidth: minWidth ?? configStyles.TEXTAREA.minWidth,
|
|
8243
8441
|
maxWidth: maxWidth ?? configStyles.TEXTAREA.maxWidth,
|
|
8442
|
+
fontSize: fontSize ?? configStyles.TEXTAREA.font.size,
|
|
8244
8443
|
minHeight: minHeight ?? configStyles.TEXTAREA.minHeight,
|
|
8245
8444
|
maxHeight: maxHeight ?? configStyles.TEXTAREA.maxHeight,
|
|
8246
8445
|
boxSizing: boxSizing ?? configStyles.TEXTAREA.box.sizing,
|
|
8446
|
+
fontStyle: fontStyle ?? configStyles.TEXTAREA.font.style,
|
|
8447
|
+
borderRadius: borderRadius ?? configStyles.TEXTAREA.radius,
|
|
8448
|
+
fontFamily: fontFamily ?? configStyles.TEXTAREA.font.family,
|
|
8449
|
+
fontWeight: fontWeight ?? configStyles.TEXTAREA.font.weight,
|
|
8247
8450
|
backgroundColor: backgroundColor ?? configStyles.TEXTAREA.colors.background,
|
|
8248
|
-
boxShadow: error ? errorColor ? `0 0 0
|
|
8451
|
+
boxShadow: error ? errorColor ? `0 0 0 ${borderWidth ? borderWidth : configStyles.TEXTAREA.box.width} ${errorColor}` : configStyles.TEXTAREA.error.box.shadow : isFocus ? borderFocusColor ? `0 0 0 ${borderWidth ? borderWidth : configStyles.TEXTAREA.box.width} ${borderFocusColor}` : configStyles.TEXTAREA.box.colors.focus : isHover ? borderHoverColor ? `0 0 0 ${borderWidth ? borderWidth : configStyles.TEXTAREA.box.width} ${borderHoverColor}` : configStyles.TEXTAREA.box.colors.hover : boxShadow ? boxShadow : configStyles.INPUT.box.shadow,
|
|
8249
8452
|
resize: resize ? resize : configStyles.TEXTAREA.resize
|
|
8250
8453
|
},
|
|
8251
8454
|
name: name,
|
|
@@ -8264,8 +8467,9 @@ const Textarea = ({
|
|
|
8264
8467
|
}, /*#__PURE__*/React__default["default"].createElement("span", {
|
|
8265
8468
|
style: {
|
|
8266
8469
|
color: labelColor ?? configStyles.TEXTAREA.label.color,
|
|
8267
|
-
fontSize:
|
|
8268
|
-
|
|
8470
|
+
fontSize: labelFontSize ?? configStyles.TEXTAREA.label.font.size,
|
|
8471
|
+
fontStyle: labelFontStyle ?? configStyles.TEXTAREA.label.font.style,
|
|
8472
|
+
fontWeight: labelFontWeight ?? configStyles.TEXTAREA.label.font.weight,
|
|
8269
8473
|
fontFamily: labelFontFamily ?? configStyles.TEXTAREA.label.font.family
|
|
8270
8474
|
}
|
|
8271
8475
|
}, maxLength - value.length, " \u0576\u056B\u0577")), error ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -8278,11 +8482,11 @@ const Textarea = ({
|
|
|
8278
8482
|
style: {
|
|
8279
8483
|
display: 'inline-block',
|
|
8280
8484
|
color: errorColor ?? configStyles.TEXTAREA.error.color,
|
|
8281
|
-
fontSize:
|
|
8282
|
-
fontStyle:
|
|
8283
|
-
fontWeight:
|
|
8284
|
-
fontFamily:
|
|
8285
|
-
marginTop:
|
|
8485
|
+
fontSize: errorFontSize ?? configStyles.TEXTAREA.error.font.size,
|
|
8486
|
+
fontStyle: errorFontStyle ?? configStyles.TEXTAREA.error.font.style,
|
|
8487
|
+
fontWeight: errorFontWeight ?? configStyles.TEXTAREA.error.font.weight,
|
|
8488
|
+
fontFamily: errorFontFamily ?? configStyles.TEXTAREA.error.font.family,
|
|
8489
|
+
marginTop: errorMarginTop ?? configStyles.TEXTAREA.error.marginTop
|
|
8286
8490
|
}
|
|
8287
8491
|
}, error)) : '');
|
|
8288
8492
|
};
|
|
@@ -8303,15 +8507,15 @@ Textarea.propTypes = {
|
|
|
8303
8507
|
minWidth: PropTypes__default["default"].string,
|
|
8304
8508
|
maxWidth: PropTypes__default["default"].string,
|
|
8305
8509
|
boxShadow: PropTypes__default["default"].string,
|
|
8306
|
-
marginTop: PropTypes__default["default"].string,
|
|
8307
8510
|
boxSizing: PropTypes__default["default"].string,
|
|
8308
8511
|
minHeight: PropTypes__default["default"].string,
|
|
8309
8512
|
maxHeight: PropTypes__default["default"].string,
|
|
8310
8513
|
maxLength: PropTypes__default["default"].number,
|
|
8311
|
-
|
|
8312
|
-
|
|
8313
|
-
|
|
8314
|
-
|
|
8514
|
+
errorFontSize: PropTypes__default["default"].string,
|
|
8515
|
+
errorMarginTop: PropTypes__default["default"].string,
|
|
8516
|
+
errorFontStyle: PropTypes__default["default"].string,
|
|
8517
|
+
errorFontWeight: PropTypes__default["default"].string,
|
|
8518
|
+
errorFontFamily: PropTypes__default["default"].string,
|
|
8315
8519
|
className: PropTypes__default["default"].string,
|
|
8316
8520
|
errorColor: PropTypes__default["default"].string,
|
|
8317
8521
|
placeholder: PropTypes__default["default"].string,
|
|
@@ -8322,10 +8526,10 @@ Textarea.propTypes = {
|
|
|
8322
8526
|
borderFocusColor: PropTypes__default["default"].string,
|
|
8323
8527
|
borderHoverColor: PropTypes__default["default"].string,
|
|
8324
8528
|
label: PropTypes__default["default"].string,
|
|
8325
|
-
|
|
8326
|
-
|
|
8529
|
+
labelFontSize: PropTypes__default["default"].string,
|
|
8530
|
+
labelFontStyle: PropTypes__default["default"].string,
|
|
8327
8531
|
labelColor: PropTypes__default["default"].string,
|
|
8328
|
-
|
|
8532
|
+
labelFontWeight: PropTypes__default["default"].string,
|
|
8329
8533
|
labelDisplay: PropTypes__default["default"].string,
|
|
8330
8534
|
labelFontFamily: PropTypes__default["default"].string,
|
|
8331
8535
|
labelMarginBottom: PropTypes__default["default"].string,
|
|
@@ -8674,7 +8878,7 @@ const Swipe = ({
|
|
|
8674
8878
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
8675
8879
|
style: {
|
|
8676
8880
|
width: position === 'left' || position === 'right' ? width ?? SWIPEMODAL.width : '100%',
|
|
8677
|
-
height: position === 'top' || position === 'bottom' ? height ?? SWIPEMODAL.height : '
|
|
8881
|
+
height: position === 'top' || position === 'bottom' ? height ?? SWIPEMODAL.height : '100dvh'
|
|
8678
8882
|
}
|
|
8679
8883
|
}, (title || showCloseIcon) && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
8680
8884
|
style: {
|
|
@@ -8748,7 +8952,7 @@ const createElem = (id, title, child, props, swipeBlock, innerConfigStyles) => {
|
|
|
8748
8952
|
swipeBlock.style.zIndex = swipeCount;
|
|
8749
8953
|
swipeBlock.style.backgroundColor = backgroundColor ?? innerConfigStyles.SWIPEMODAL.colors.background;
|
|
8750
8954
|
swipeBlock.style.width = position === 'left' || position === 'right' ? width ?? innerConfigStyles.SWIPEMODAL.width : '100%';
|
|
8751
|
-
swipeBlock.style.height = position === 'top' || position === 'bottom' ? height ?? innerConfigStyles.SWIPEMODAL.height : '
|
|
8955
|
+
swipeBlock.style.height = position === 'top' || position === 'bottom' ? height ?? innerConfigStyles.SWIPEMODAL.height : '100dvh';
|
|
8752
8956
|
swipeBlock.style.borderTopLeftRadius = position === 'right' || position === 'bottom' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
8753
8957
|
swipeBlock.style.borderTopRightRadius = position === 'left' || position === 'bottom' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
8754
8958
|
swipeBlock.style.borderBottomLeftRadius = position === 'right' || position === 'top' ? '0px' : borderRadius ?? innerConfigStyles.SWIPEMODAL.border.radius;
|
|
@@ -8790,10 +8994,10 @@ const createSwipe = (id, title, child, props, swipable) => {
|
|
|
8790
8994
|
swipable.style.left = '0px';
|
|
8791
8995
|
swipable.style.zIndex = 99999;
|
|
8792
8996
|
swipable.style.maxWidth = '100%';
|
|
8793
|
-
swipable.style.maxHeight = '
|
|
8997
|
+
swipable.style.maxHeight = '100dvh';
|
|
8794
8998
|
swipable.style.visibility = 'hidden';
|
|
8795
8999
|
swipable.style.width = widthParent ? '100%' : '0px';
|
|
8796
|
-
swipable.style.height = widthParent ? '
|
|
9000
|
+
swipable.style.height = widthParent ? '100dvh' : '0px';
|
|
8797
9001
|
swipable.style.backgroundColor = props?.parent?.backgroundColor ?? innerConfigStyles.SWIPEMODAL.parent.colors.background;
|
|
8798
9002
|
swipable.classList.add(styles$2['visible']);
|
|
8799
9003
|
if (props.outSideClose || innerConfigStyles.SWIPEMODAL.outSideClose) {
|
|
@@ -8849,7 +9053,17 @@ const swipe = {
|
|
|
8849
9053
|
return;
|
|
8850
9054
|
}
|
|
8851
9055
|
if (swipeCount === 0) {
|
|
8852
|
-
if (
|
|
9056
|
+
if (!hasOwnerProperty(props, 'underScroll')) {
|
|
9057
|
+
if (newConfigStyles.SWIPEMODAL && hasOwnerProperty(newConfigStyles.SWIPEMODAL, 'underScroll') && newConfigStyles.SWIPEMODAL.underScroll === false) {
|
|
9058
|
+
style.textContent = `.tui-no-srcoll-class{overflow:hidden!important;}`;
|
|
9059
|
+
document.head.appendChild(style);
|
|
9060
|
+
document.body.classList.add('tui-no-srcoll-class');
|
|
9061
|
+
document.documentElement.classList.add('tui-no-srcoll-class');
|
|
9062
|
+
document.documentElement.addEventListener('touchmove', ResetTouchRemove, {
|
|
9063
|
+
passive: false
|
|
9064
|
+
});
|
|
9065
|
+
}
|
|
9066
|
+
} else if (hasOwnerProperty(props, 'underScroll') && props.underScroll === false) {
|
|
8853
9067
|
style.textContent = `.tui-no-srcoll-class{overflow:hidden!important;}`;
|
|
8854
9068
|
document.head.appendChild(style);
|
|
8855
9069
|
document.body.classList.add('tui-no-srcoll-class');
|
|
@@ -8870,11 +9084,10 @@ const swipe = {
|
|
|
8870
9084
|
});
|
|
8871
9085
|
},
|
|
8872
9086
|
close: id => {
|
|
8873
|
-
let newConfigStyles = {};
|
|
8874
9087
|
configStylesPromise.then(data => {
|
|
8875
|
-
|
|
9088
|
+
({
|
|
8876
9089
|
...data
|
|
8877
|
-
};
|
|
9090
|
+
});
|
|
8878
9091
|
}, error => {
|
|
8879
9092
|
console.error(error);
|
|
8880
9093
|
});
|
|
@@ -8896,14 +9109,12 @@ const swipe = {
|
|
|
8896
9109
|
window.removeEventListener('popstate', handleNavigationChange);
|
|
8897
9110
|
window.removeEventListener('navigationchange', handleNavigationChange);
|
|
8898
9111
|
document.body.removeChild(swipable);
|
|
8899
|
-
|
|
8900
|
-
|
|
8901
|
-
|
|
8902
|
-
|
|
8903
|
-
|
|
8904
|
-
|
|
8905
|
-
document.documentElement.removeEventListener('touchmove', ResetTouchRemove);
|
|
8906
|
-
}
|
|
9112
|
+
const noScrllable = document.getElementsByClassName('tui-no-srcoll-class');
|
|
9113
|
+
if (noScrllable) {
|
|
9114
|
+
style.remove();
|
|
9115
|
+
document.body.classList.remove('tui-no-srcoll-class');
|
|
9116
|
+
document.documentElement.classList.remove('tui-no-srcoll-class');
|
|
9117
|
+
document.documentElement.removeEventListener('touchmove', ResetTouchRemove);
|
|
8907
9118
|
}
|
|
8908
9119
|
}
|
|
8909
9120
|
}, 200);
|
|
@@ -8913,14 +9124,12 @@ const swipe = {
|
|
|
8913
9124
|
window.removeEventListener('popstate', handleNavigationChange);
|
|
8914
9125
|
window.removeEventListener('navigationchange', handleNavigationChange);
|
|
8915
9126
|
document.body.removeChild(swipable);
|
|
8916
|
-
|
|
8917
|
-
|
|
8918
|
-
|
|
8919
|
-
|
|
8920
|
-
|
|
8921
|
-
|
|
8922
|
-
document.documentElement.removeEventListener('touchmove', ResetTouchRemove);
|
|
8923
|
-
}
|
|
9127
|
+
const noScrllable = document.getElementsByClassName('tui-no-srcoll-class');
|
|
9128
|
+
if (noScrllable) {
|
|
9129
|
+
style.remove();
|
|
9130
|
+
document.body.classList.remove('tui-no-srcoll-class');
|
|
9131
|
+
document.documentElement.classList.remove('tui-no-srcoll-class');
|
|
9132
|
+
document.documentElement.removeEventListener('touchmove', ResetTouchRemove);
|
|
8924
9133
|
}
|
|
8925
9134
|
}
|
|
8926
9135
|
}
|
|
@@ -8953,21 +9162,21 @@ const TypographyType = {
|
|
|
8953
9162
|
span: 'span'
|
|
8954
9163
|
};
|
|
8955
9164
|
const Typography = ({
|
|
8956
|
-
size,
|
|
8957
9165
|
color,
|
|
8958
|
-
weight,
|
|
8959
|
-
radius,
|
|
8960
9166
|
border,
|
|
8961
9167
|
cursor,
|
|
8962
9168
|
onClick,
|
|
8963
9169
|
children,
|
|
9170
|
+
fontSize,
|
|
8964
9171
|
textAlign,
|
|
8965
9172
|
fontStyle,
|
|
8966
9173
|
className,
|
|
8967
9174
|
textShadow,
|
|
8968
9175
|
lineHeight,
|
|
8969
9176
|
colorHover,
|
|
9177
|
+
fontWeight,
|
|
8970
9178
|
fontFamily,
|
|
9179
|
+
borderRadius,
|
|
8971
9180
|
textTransform,
|
|
8972
9181
|
textDecoration,
|
|
8973
9182
|
backgroundColor,
|
|
@@ -8988,9 +9197,9 @@ const Typography = ({
|
|
|
8988
9197
|
style: {
|
|
8989
9198
|
border: border ?? configStyles.TYPOGRAPHY.border,
|
|
8990
9199
|
cursor: cursor ?? configStyles.TYPOGRAPHY.cursor,
|
|
8991
|
-
borderRadius:
|
|
8992
|
-
fontSize:
|
|
8993
|
-
fontWeight:
|
|
9200
|
+
borderRadius: borderRadius ?? configStyles.TYPOGRAPHY.radius,
|
|
9201
|
+
fontSize: fontSize ?? configStyles.TYPOGRAPHY.font['size' + variant],
|
|
9202
|
+
fontWeight: fontWeight ?? configStyles.TYPOGRAPHY.font['weight' + variant],
|
|
8994
9203
|
textShadow: textShadow ?? configStyles.TYPOGRAPHY.text['shadow' + variant],
|
|
8995
9204
|
textAlign: textAlign ?? configStyles.TYPOGRAPHY.text['align' + variant],
|
|
8996
9205
|
fontStyle: fontStyle ?? configStyles.TYPOGRAPHY.font['style' + variant],
|
|
@@ -9032,10 +9241,8 @@ const Typography = ({
|
|
|
9032
9241
|
Typography.propTypes = {
|
|
9033
9242
|
color: PropTypes__default["default"].string,
|
|
9034
9243
|
onClick: PropTypes__default["default"].func,
|
|
9035
|
-
weight: PropTypes__default["default"].string,
|
|
9036
9244
|
border: PropTypes__default["default"].string,
|
|
9037
9245
|
cursor: PropTypes__default["default"].string,
|
|
9038
|
-
radius: PropTypes__default["default"].string,
|
|
9039
9246
|
textAlign: PropTypes__default["default"].string,
|
|
9040
9247
|
className: PropTypes__default["default"].string,
|
|
9041
9248
|
fontStyle: PropTypes__default["default"].string,
|
|
@@ -9043,11 +9250,13 @@ Typography.propTypes = {
|
|
|
9043
9250
|
textShadow: PropTypes__default["default"].string,
|
|
9044
9251
|
fontFamily: PropTypes__default["default"].string,
|
|
9045
9252
|
colorHover: PropTypes__default["default"].string,
|
|
9253
|
+
fontWeight: PropTypes__default["default"].string,
|
|
9254
|
+
borderRadius: PropTypes__default["default"].string,
|
|
9046
9255
|
textTransform: PropTypes__default["default"].string,
|
|
9047
9256
|
textDecoration: PropTypes__default["default"].string,
|
|
9048
9257
|
backgroundColor: PropTypes__default["default"].string,
|
|
9049
9258
|
variant: PropTypes__default["default"].oneOf(Object.values(TypographyType)),
|
|
9050
|
-
|
|
9259
|
+
fontSize: PropTypes__default["default"].oneOfType([PropTypes__default["default"].string, PropTypes__default["default"].number])
|
|
9051
9260
|
};
|
|
9052
9261
|
|
|
9053
9262
|
const Dots = '...';
|
|
@@ -9511,12 +9720,13 @@ const Autocomplete = ({
|
|
|
9511
9720
|
required,
|
|
9512
9721
|
selected,
|
|
9513
9722
|
className,
|
|
9514
|
-
|
|
9515
|
-
|
|
9516
|
-
|
|
9517
|
-
|
|
9518
|
-
|
|
9723
|
+
errorFontSize,
|
|
9724
|
+
errorFontStyle,
|
|
9725
|
+
errorFontWeight,
|
|
9726
|
+
errorFontFamily,
|
|
9727
|
+
errorMarginTop,
|
|
9519
9728
|
errorColor,
|
|
9729
|
+
errorInContent,
|
|
9520
9730
|
placeHolder,
|
|
9521
9731
|
errorMessage,
|
|
9522
9732
|
autoComplete,
|
|
@@ -9574,11 +9784,11 @@ const Autocomplete = ({
|
|
|
9574
9784
|
contentBottomRowHoverBackgroundColor,
|
|
9575
9785
|
backgroundDisableColor,
|
|
9576
9786
|
label,
|
|
9577
|
-
labelSize,
|
|
9578
|
-
labelStyle,
|
|
9579
9787
|
labelColor,
|
|
9580
|
-
labelWeight,
|
|
9581
9788
|
labelDisplay,
|
|
9789
|
+
labelFontSize,
|
|
9790
|
+
labelFontStyle,
|
|
9791
|
+
labelFontWeight,
|
|
9582
9792
|
labelLineHeight,
|
|
9583
9793
|
labelFontFamily,
|
|
9584
9794
|
labelMarginBottom,
|
|
@@ -9718,14 +9928,15 @@ const Autocomplete = ({
|
|
|
9718
9928
|
}, item[keyNames.name]);
|
|
9719
9929
|
}))) : innerError ? '' : innerValue.length <= 0 ? '' : /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9720
9930
|
style: {
|
|
9721
|
-
position: 'absolute',
|
|
9931
|
+
position: (errorInContent ? errorInContent : configStyles.AUTOCOMPLETE.error.inContent) ? 'static' : 'absolute',
|
|
9722
9932
|
zIndex: '1',
|
|
9723
9933
|
color: errorColor ?? configStyles.AUTOCOMPLETE.error.color,
|
|
9724
|
-
fontSize:
|
|
9725
|
-
fontStyle:
|
|
9726
|
-
fontWeight:
|
|
9727
|
-
fontFamily:
|
|
9728
|
-
|
|
9934
|
+
fontSize: errorFontSize ?? configStyles.AUTOCOMPLETE.error.font.size,
|
|
9935
|
+
fontStyle: errorFontStyle ?? configStyles.AUTOCOMPLETE.error.font.style,
|
|
9936
|
+
fontWeight: errorFontWeight ?? configStyles.AUTOCOMPLETE.error.font.weight,
|
|
9937
|
+
fontFamily: errorFontFamily ?? configStyles.AUTOCOMPLETE.error.font.family,
|
|
9938
|
+
marginTop: (errorInContent ? errorInContent : configStyles.AUTOCOMPLETE.error.inContent) ? errorMarginTop ?? configStyles.AUTOCOMPLETE.error.marginTop : '0px',
|
|
9939
|
+
top: errorMarginTop ? `calc(100% + ${errorMarginTop})` : `calc(100% + ${configStyles.AUTOCOMPLETE.error.marginTop})`,
|
|
9729
9940
|
padding: innerErrorPadding ?? configStyles.AUTOCOMPLETE.innerError.padding,
|
|
9730
9941
|
height: contentBottomRowHeight ?? configStyles.AUTOCOMPLETE.contentBottom.row.height,
|
|
9731
9942
|
lineHeight: contentBottomRowLineHeight ?? configStyles.AUTOCOMPLETE.contentBottom.row.lineHeight,
|
|
@@ -9894,9 +10105,9 @@ const Autocomplete = ({
|
|
|
9894
10105
|
style: {
|
|
9895
10106
|
color: labelColor ?? configStyles.AUTOCOMPLETE.label.color,
|
|
9896
10107
|
display: labelDisplay ?? configStyles.AUTOCOMPLETE.label.display,
|
|
9897
|
-
fontSize:
|
|
9898
|
-
fontStyle:
|
|
9899
|
-
fontWeight:
|
|
10108
|
+
fontSize: labelFontSize ?? configStyles.AUTOCOMPLETE.label.font.size,
|
|
10109
|
+
fontStyle: labelFontStyle ?? configStyles.AUTOCOMPLETE.label.font.style,
|
|
10110
|
+
fontWeight: labelFontWeight ?? configStyles.AUTOCOMPLETE.label.font.weight,
|
|
9900
10111
|
fontFamily: labelFontFamily ?? configStyles.AUTOCOMPLETE.label.font.family,
|
|
9901
10112
|
lineHeight: labelLineHeight ?? configStyles.AUTOCOMPLETE.label.lineHeight,
|
|
9902
10113
|
marginBottom: labelMarginBottom ?? configStyles.AUTOCOMPLETE.label.marginBottom,
|
|
@@ -9911,9 +10122,9 @@ const Autocomplete = ({
|
|
|
9911
10122
|
}, label, handleCheckTextWidth() === 'more' && showMore && (lableShowMore || configStyles.AUTOCOMPLETE.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9912
10123
|
className: styles['show-more-text'],
|
|
9913
10124
|
style: {
|
|
9914
|
-
fontSize:
|
|
9915
|
-
fontStyle:
|
|
9916
|
-
fontWeight:
|
|
10125
|
+
fontSize: labelFontSize ?? configStyles.AUTOCOMPLETE.label.font.size,
|
|
10126
|
+
fontStyle: labelFontStyle ?? configStyles.AUTOCOMPLETE.label.font.style,
|
|
10127
|
+
fontWeight: labelFontWeight ?? configStyles.AUTOCOMPLETE.label.font.weight,
|
|
9917
10128
|
fontFamily: labelFontFamily ?? configStyles.AUTOCOMPLETE.label.font.family,
|
|
9918
10129
|
color: showMoreTextColor ?? configStyles.AUTOCOMPLETE.label.showMoreTextColor
|
|
9919
10130
|
},
|
|
@@ -9921,9 +10132,9 @@ const Autocomplete = ({
|
|
|
9921
10132
|
}, ' ', " ", labelShowLessText ?? configStyles.AUTOCOMPLETE.label.showLessText) : ''), required && /*#__PURE__*/React__default["default"].createElement("sup", null, iconRequired ? iconRequired : configStyles.FILE.icon.required ? configStyles.FILE.icon.required : /*#__PURE__*/React__default["default"].createElement(SvgRequired, null)), handleCheckTextWidth() === 'more' && !showMore && (lableShowMore || configStyles.AUTOCOMPLETE.label.showMore) ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9922
10133
|
className: styles['show-more-text'],
|
|
9923
10134
|
style: {
|
|
9924
|
-
fontSize:
|
|
9925
|
-
fontStyle:
|
|
9926
|
-
fontWeight:
|
|
10135
|
+
fontSize: labelFontSize ?? configStyles.AUTOCOMPLETE.label.font.size,
|
|
10136
|
+
fontStyle: labelFontStyle ?? configStyles.AUTOCOMPLETE.label.font.style,
|
|
10137
|
+
fontWeight: labelFontWeight ?? configStyles.AUTOCOMPLETE.label.font.weight,
|
|
9927
10138
|
fontFamily: labelFontFamily ?? configStyles.AUTOCOMPLETE.label.font.family,
|
|
9928
10139
|
color: showMoreTextColor ?? configStyles.AUTOCOMPLETE.label.showMoreTextColor,
|
|
9929
10140
|
marginBottom: labelMarginBottom ?? configStyles.AUTOCOMPLETE.label.marginBottom
|
|
@@ -9972,13 +10183,14 @@ const Autocomplete = ({
|
|
|
9972
10183
|
}, props)), innerError ? /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9973
10184
|
style: {
|
|
9974
10185
|
left: '0px',
|
|
9975
|
-
position: 'absolute',
|
|
10186
|
+
position: (errorInContent ? errorInContent : configStyles.AUTOCOMPLETE.error.inContent) ? 'static' : 'absolute',
|
|
9976
10187
|
color: errorColor ?? configStyles.AUTOCOMPLETE.error.color,
|
|
9977
|
-
fontSize:
|
|
9978
|
-
fontStyle:
|
|
9979
|
-
fontWeight:
|
|
9980
|
-
fontFamily:
|
|
9981
|
-
|
|
10188
|
+
fontSize: errorFontSize ?? configStyles.AUTOCOMPLETE.error.font.size,
|
|
10189
|
+
fontStyle: errorFontStyle ?? configStyles.AUTOCOMPLETE.error.font.style,
|
|
10190
|
+
fontWeight: errorFontWeight ?? configStyles.AUTOCOMPLETE.error.font.weight,
|
|
10191
|
+
fontFamily: errorFontFamily ?? configStyles.AUTOCOMPLETE.error.font.family,
|
|
10192
|
+
marginTop: (errorInContent ? errorInContent : configStyles.AUTOCOMPLETE.error.inContent) ? errorMarginTop ?? configStyles.AUTOCOMPLETE.error.marginTop : '0px',
|
|
10193
|
+
top: errorMarginTop ? `calc(100% + ${errorMarginTop})` : `calc(100% + ${configStyles.AUTOCOMPLETE.error.marginTop})`,
|
|
9982
10194
|
maxWidth: contentTopMaxWidth ?? configStyles.AUTOCOMPLETE.maxWidth
|
|
9983
10195
|
}
|
|
9984
10196
|
}, innerError) : '', optionList));
|
|
@@ -9990,18 +10202,19 @@ Autocomplete.propTypes = {
|
|
|
9990
10202
|
keyNames: PropTypes__default["default"].object,
|
|
9991
10203
|
selected: PropTypes__default["default"].object,
|
|
9992
10204
|
className: PropTypes__default["default"].string,
|
|
9993
|
-
|
|
9994
|
-
|
|
9995
|
-
|
|
9996
|
-
|
|
9997
|
-
|
|
9998
|
-
labelSize: PropTypes__default["default"].string,
|
|
9999
|
-
labelStyle: PropTypes__default["default"].string,
|
|
10205
|
+
errorFontSize: PropTypes__default["default"].string,
|
|
10206
|
+
errorFontStyle: PropTypes__default["default"].string,
|
|
10207
|
+
errorFontWeight: PropTypes__default["default"].string,
|
|
10208
|
+
errorFontFamily: PropTypes__default["default"].string,
|
|
10209
|
+
errorMarginTop: PropTypes__default["default"].string,
|
|
10000
10210
|
errorColor: PropTypes__default["default"].string,
|
|
10001
10211
|
labelColor: PropTypes__default["default"].string,
|
|
10002
10212
|
searchCount: PropTypes__default["default"].number,
|
|
10003
10213
|
placeHolder: PropTypes__default["default"].string,
|
|
10004
|
-
|
|
10214
|
+
labelFontSize: PropTypes__default["default"].string,
|
|
10215
|
+
labelFontStyle: PropTypes__default["default"].string,
|
|
10216
|
+
labelFontWeight: PropTypes__default["default"].number,
|
|
10217
|
+
errorInContent: PropTypes__default["default"].bool,
|
|
10005
10218
|
errorMessage: PropTypes__default["default"].string,
|
|
10006
10219
|
labelDisplay: PropTypes__default["default"].string,
|
|
10007
10220
|
autoComplete: PropTypes__default["default"].string,
|