@xaypay/tui 0.0.85 → 0.0.87
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +8 -5
- package/dist/index.js +8 -5
- package/package.json +1 -1
- package/src/components/newAutocomplete/index.js +4 -4
- package/src/components/select/index.js +3 -0
- package/src/components/select/select.module.css +1 -1
- package/src/stories/configuration.stories.mdx +2 -0
- package/tui.config.js +2 -3
package/dist/index.es.js
CHANGED
|
@@ -1198,7 +1198,7 @@ const SvgArrow = ({
|
|
|
1198
1198
|
fill: fillColor ? fillColor : '#3C393E'
|
|
1199
1199
|
}));
|
|
1200
1200
|
|
|
1201
|
-
var css_248z$9 = ".select-module_select-content__GCMDX{display:flex;flex-direction:column;position:relative}.select-module_select-content-top__Aw-fB{align-items:center;display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.select-module_select-content-bottom__ueZCR{animation:select-module_select-show__391hQ .64s linear forwards;-webkit-animation:select-module_select-show__391hQ .64s linear forwards;left:0;max-height:0;overflow:hidden;position:absolute;width:100%;z-index:
|
|
1201
|
+
var css_248z$9 = ".select-module_select-content__GCMDX{display:flex;flex-direction:column;position:relative}.select-module_select-content-top__Aw-fB{align-items:center;display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.select-module_select-content-bottom__ueZCR{animation:select-module_select-show__391hQ .64s linear forwards;-webkit-animation:select-module_select-show__391hQ .64s linear forwards;left:0;max-height:0;overflow:hidden;position:absolute;width:100%;z-index:10}.select-module_select-content-bottom-inner__NWy2X{display:flex;flex-direction:column;max-height:234px;overflow-x:hidden;overflow-y:auto}.select-module_select-content-top-icon__MBrGK{align-items:center;box-sizing:border-box;display:flex;flex:0 0 auto;padding:0 5px 0 20px}.select-module_select-content-top-icon__MBrGK>div{align-items:center;display:flex;height:14px;justify-content:center;width:14px}.select-module_close-icon__SFNaJ{border-right:1px solid #eee;box-sizing:content-box;padding-right:9px}.select-module_arrow-icon__rjHt-{margin-left:9px;transform-origin:center;transition:all .64s ease;-webkit-transition:all .64s ease;-moz-transition:all .64s ease;-ms-transition:all .64s ease;-o-transition:all .64s ease}.select-module_select-content-bottom-row__eKq5L{align-items:center;display:flex;transition:background-color .24s,color .24s;-webkit-transition:background-color .24s,color .24s;-moz-transition:background-color .24s,color .24s;-ms-transition:background-color .24s,color .24s;-o-transition:background-color .24s,color .24s}.select-module_select-content-bottom-row__eKq5L:last-child{margin-bottom:0}@keyframes select-module_select-show__391hQ{to{max-height:234px}}";
|
|
1202
1202
|
var styles$7 = {"select-content":"select-module_select-content__GCMDX","select-content-top":"select-module_select-content-top__Aw-fB","select-content-bottom":"select-module_select-content-bottom__ueZCR","select-show":"select-module_select-show__391hQ","select-content-bottom-inner":"select-module_select-content-bottom-inner__NWy2X","select-content-top-icon":"select-module_select-content-top-icon__MBrGK","close-icon":"select-module_close-icon__SFNaJ","arrow-icon":"select-module_arrow-icon__rjHt-","select-content-bottom-row":"select-module_select-content-bottom-row__eKq5L"};
|
|
1203
1203
|
styleInject(css_248z$9);
|
|
1204
1204
|
|
|
@@ -1407,6 +1407,9 @@ const Select = ({
|
|
|
1407
1407
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
1408
1408
|
className: `${styles$7['select-content-top-text']}`,
|
|
1409
1409
|
style: {
|
|
1410
|
+
whiteSpace: 'nowrap',
|
|
1411
|
+
overflow: 'hidden',
|
|
1412
|
+
textOverflow: 'ellipsis',
|
|
1410
1413
|
color: errorMessage ? errorColor ? errorColor : configStyles.SELECT.errorColor : isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selectedHoverColor : selectedColor ? selectedColor : configStyles.SELECT.selectedColor
|
|
1411
1414
|
}
|
|
1412
1415
|
}, !multiple && newSelected && newSelected[0] && newSelected[0][keyNames.name] ? newSelected[0][keyNames.name] : newSelected && newSelected.length > 0 ? newSelected.map((_, index) => {
|
|
@@ -3892,8 +3895,8 @@ const NewAutocomplete = ({
|
|
|
3892
3895
|
};
|
|
3893
3896
|
const handleClick = selectedValue => {
|
|
3894
3897
|
setShow(false);
|
|
3895
|
-
setId(selectedValue.id);
|
|
3896
|
-
setInnerValue(selectedValue.name);
|
|
3898
|
+
setId(selectedValue[keyNames.id]);
|
|
3899
|
+
setInnerValue(selectedValue[keyNames.name]);
|
|
3897
3900
|
getItem(selectedValue);
|
|
3898
3901
|
};
|
|
3899
3902
|
const optionList = /*#__PURE__*/React__default.createElement(React__default.Fragment, null, show && innerOptions && !disabled ? innerOptions.length > 0 ? /*#__PURE__*/React__default.createElement("div", {
|
|
@@ -3959,8 +3962,8 @@ const NewAutocomplete = ({
|
|
|
3959
3962
|
alert('Please add options prop');
|
|
3960
3963
|
}
|
|
3961
3964
|
options && options.length > 0 && options.map(item => {
|
|
3962
|
-
if (!item.hasOwnProperty(
|
|
3963
|
-
alert(
|
|
3965
|
+
if (!item.hasOwnProperty(keyNames.name)) {
|
|
3966
|
+
alert(`Please add ${keyNames.name} property in items of options array`);
|
|
3964
3967
|
}
|
|
3965
3968
|
});
|
|
3966
3969
|
if (!getItem) {
|
package/dist/index.js
CHANGED
|
@@ -1228,7 +1228,7 @@ const SvgArrow = ({
|
|
|
1228
1228
|
fill: fillColor ? fillColor : '#3C393E'
|
|
1229
1229
|
}));
|
|
1230
1230
|
|
|
1231
|
-
var css_248z$9 = ".select-module_select-content__GCMDX{display:flex;flex-direction:column;position:relative}.select-module_select-content-top__Aw-fB{align-items:center;display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.select-module_select-content-bottom__ueZCR{animation:select-module_select-show__391hQ .64s linear forwards;-webkit-animation:select-module_select-show__391hQ .64s linear forwards;left:0;max-height:0;overflow:hidden;position:absolute;width:100%;z-index:
|
|
1231
|
+
var css_248z$9 = ".select-module_select-content__GCMDX{display:flex;flex-direction:column;position:relative}.select-module_select-content-top__Aw-fB{align-items:center;display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.select-module_select-content-bottom__ueZCR{animation:select-module_select-show__391hQ .64s linear forwards;-webkit-animation:select-module_select-show__391hQ .64s linear forwards;left:0;max-height:0;overflow:hidden;position:absolute;width:100%;z-index:10}.select-module_select-content-bottom-inner__NWy2X{display:flex;flex-direction:column;max-height:234px;overflow-x:hidden;overflow-y:auto}.select-module_select-content-top-icon__MBrGK{align-items:center;box-sizing:border-box;display:flex;flex:0 0 auto;padding:0 5px 0 20px}.select-module_select-content-top-icon__MBrGK>div{align-items:center;display:flex;height:14px;justify-content:center;width:14px}.select-module_close-icon__SFNaJ{border-right:1px solid #eee;box-sizing:content-box;padding-right:9px}.select-module_arrow-icon__rjHt-{margin-left:9px;transform-origin:center;transition:all .64s ease;-webkit-transition:all .64s ease;-moz-transition:all .64s ease;-ms-transition:all .64s ease;-o-transition:all .64s ease}.select-module_select-content-bottom-row__eKq5L{align-items:center;display:flex;transition:background-color .24s,color .24s;-webkit-transition:background-color .24s,color .24s;-moz-transition:background-color .24s,color .24s;-ms-transition:background-color .24s,color .24s;-o-transition:background-color .24s,color .24s}.select-module_select-content-bottom-row__eKq5L:last-child{margin-bottom:0}@keyframes select-module_select-show__391hQ{to{max-height:234px}}";
|
|
1232
1232
|
var styles$7 = {"select-content":"select-module_select-content__GCMDX","select-content-top":"select-module_select-content-top__Aw-fB","select-content-bottom":"select-module_select-content-bottom__ueZCR","select-show":"select-module_select-show__391hQ","select-content-bottom-inner":"select-module_select-content-bottom-inner__NWy2X","select-content-top-icon":"select-module_select-content-top-icon__MBrGK","close-icon":"select-module_close-icon__SFNaJ","arrow-icon":"select-module_arrow-icon__rjHt-","select-content-bottom-row":"select-module_select-content-bottom-row__eKq5L"};
|
|
1233
1233
|
styleInject(css_248z$9);
|
|
1234
1234
|
|
|
@@ -1437,6 +1437,9 @@ const Select = ({
|
|
|
1437
1437
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1438
1438
|
className: `${styles$7['select-content-top-text']}`,
|
|
1439
1439
|
style: {
|
|
1440
|
+
whiteSpace: 'nowrap',
|
|
1441
|
+
overflow: 'hidden',
|
|
1442
|
+
textOverflow: 'ellipsis',
|
|
1440
1443
|
color: errorMessage ? errorColor ? errorColor : configStyles.SELECT.errorColor : isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selectedHoverColor : selectedColor ? selectedColor : configStyles.SELECT.selectedColor
|
|
1441
1444
|
}
|
|
1442
1445
|
}, !multiple && newSelected && newSelected[0] && newSelected[0][keyNames.name] ? newSelected[0][keyNames.name] : newSelected && newSelected.length > 0 ? newSelected.map((_, index) => {
|
|
@@ -3922,8 +3925,8 @@ const NewAutocomplete = ({
|
|
|
3922
3925
|
};
|
|
3923
3926
|
const handleClick = selectedValue => {
|
|
3924
3927
|
setShow(false);
|
|
3925
|
-
setId(selectedValue.id);
|
|
3926
|
-
setInnerValue(selectedValue.name);
|
|
3928
|
+
setId(selectedValue[keyNames.id]);
|
|
3929
|
+
setInnerValue(selectedValue[keyNames.name]);
|
|
3927
3930
|
getItem(selectedValue);
|
|
3928
3931
|
};
|
|
3929
3932
|
const optionList = /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, show && innerOptions && !disabled ? innerOptions.length > 0 ? /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -3989,8 +3992,8 @@ const NewAutocomplete = ({
|
|
|
3989
3992
|
alert('Please add options prop');
|
|
3990
3993
|
}
|
|
3991
3994
|
options && options.length > 0 && options.map(item => {
|
|
3992
|
-
if (!item.hasOwnProperty(
|
|
3993
|
-
alert(
|
|
3995
|
+
if (!item.hasOwnProperty(keyNames.name)) {
|
|
3996
|
+
alert(`Please add ${keyNames.name} property in items of options array`);
|
|
3994
3997
|
}
|
|
3995
3998
|
});
|
|
3996
3999
|
if (!getItem) {
|
package/package.json
CHANGED
|
@@ -137,8 +137,8 @@ export const NewAutocomplete = ({
|
|
|
137
137
|
|
|
138
138
|
const handleClick = (selectedValue) => {
|
|
139
139
|
setShow(false);
|
|
140
|
-
setId(selectedValue.id);
|
|
141
|
-
setInnerValue(selectedValue.name);
|
|
140
|
+
setId(selectedValue[keyNames.id]);
|
|
141
|
+
setInnerValue(selectedValue[keyNames.name]);
|
|
142
142
|
getItem(selectedValue);
|
|
143
143
|
};
|
|
144
144
|
|
|
@@ -244,8 +244,8 @@ export const NewAutocomplete = ({
|
|
|
244
244
|
}
|
|
245
245
|
|
|
246
246
|
options && options.length > 0 && options.map(item => {
|
|
247
|
-
if (!item.hasOwnProperty(
|
|
248
|
-
alert(
|
|
247
|
+
if (!item.hasOwnProperty(keyNames.name)) {
|
|
248
|
+
alert(`Please add ${keyNames.name} property in items of options array`);
|
|
249
249
|
}
|
|
250
250
|
});
|
|
251
251
|
|
|
@@ -243,6 +243,9 @@ export const Select = ({
|
|
|
243
243
|
<div
|
|
244
244
|
className={`${styles['select-content-top-text']}`}
|
|
245
245
|
style={{
|
|
246
|
+
whiteSpace: 'nowrap',
|
|
247
|
+
overflow: 'hidden',
|
|
248
|
+
textOverflow: 'ellipsis',
|
|
246
249
|
color: errorMessage ? errorColor ? errorColor : configStyles.SELECT.errorColor : isHover ? selectedHoverColor ? selectedHoverColor : configStyles.SELECT.selectedHoverColor : selectedColor ? selectedColor : configStyles.SELECT.selectedColor,
|
|
247
250
|
}}
|
|
248
251
|
>
|
|
@@ -422,9 +422,11 @@ import StackAlt from './assets/stackalt.svg';
|
|
|
422
422
|
minWidth: '200px', // for minimum width
|
|
423
423
|
maxWidth: '500px', // for maximum width
|
|
424
424
|
labelSize: '16px', // for label font size
|
|
425
|
+
errorSize: '12px', // for error font size
|
|
425
426
|
minHeight: '100px', // for minimum height
|
|
426
427
|
maxHeight: '300px', // for maximum height
|
|
427
428
|
padding: '12px 15px', // for padding
|
|
429
|
+
errorColor: '#E40E00', // for error color
|
|
428
430
|
labelColor: '#3C393E', // for label color
|
|
429
431
|
labelWeight: 'normal', // for label font weight
|
|
430
432
|
labelDisplay: 'block', // for label display
|
package/tui.config.js
CHANGED
|
@@ -337,12 +337,11 @@ module.exports = {
|
|
|
337
337
|
height: '200px', // for file choose place height
|
|
338
338
|
color: '#3C393E', // for file place color
|
|
339
339
|
upload: 'Բեռնել', // for file place text
|
|
340
|
-
maxWidth: '440px',
|
|
340
|
+
maxWidth: '440px', // for file width
|
|
341
341
|
labelSize: '16px', // for file font size
|
|
342
342
|
border: '2px dashed', // for file choose place border
|
|
343
|
-
errorColor: '#ee0000', // for file error message color
|
|
344
343
|
labelColor: '#4A4A4D', // for file color
|
|
345
|
-
errorColor: '#ee0000', // for file place error color
|
|
344
|
+
errorColor: '#ee0000', // for file place and error message error color
|
|
346
345
|
borderColor: '#D1D1D1', // for file choose place border color
|
|
347
346
|
listItemHeight: '70px', // for file list item height
|
|
348
347
|
uploadColor: '#0DA574', // for file place upload text color
|