@xaypay/tui 0.0.73 → 0.0.75
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 +433 -187
- package/dist/index.js +433 -187
- package/package.json +1 -1
- package/src/components/icon/Close.js +19 -0
- package/src/components/icon/CloseSlide.js +19 -0
- package/src/components/icon/Next.js +21 -0
- package/src/components/icon/Prev.js +21 -0
- package/src/components/icon/index.js +1 -2
- package/src/components/modal/index.js +296 -69
- package/src/components/modal/modal.module.css +14 -65
- package/src/components/modal/modal.stories.js +26 -7
- package/src/components/newAutocomplete/NewAutocomplete.stories.js +3 -2
- package/src/components/newAutocomplete/index.js +12 -2
- package/src/components/select/index.js +1 -1
- package/src/stories/configuration.stories.mdx +16 -0
- package/src/stories/static/modal-usage.png +0 -0
- package/src/stories/usage.stories.mdx +5 -1
- package/tui.config.js +13 -0
package/dist/index.es.js
CHANGED
|
@@ -369,13 +369,6 @@ Table.defaultProps = {
|
|
|
369
369
|
hearderData: []
|
|
370
370
|
};
|
|
371
371
|
|
|
372
|
-
var css_248z$b = ".modal-module_modal-wrap__IsXXf{background:rgba(0,0,0,.4);height:100%;left:0;position:fixed;top:0;width:100%;z-index:9}.modal-module_modal-top__ntDBi{background:#fbfbfb;box-sizing:border-box;display:flex;flex-direction:row;height:44px;padding:4px 10px 4px 0;width:100%}.modal-module_modal-title__r-WKl{align-items:center;color:#3c393e;display:flex;flex:1 1;font-size:20px;font-weight:500;line-height:24px;padding-right:20px}.modal-module_close-btn__Qf2UD{cursor:pointer;flex:0 0 auto;width:24px}.modal-module_close-btn__Qf2UD,.modal-module_modal-section__Bp8jN{align-items:center;display:flex;height:100%;justify-content:center}.modal-module_modal-section__Bp8jN{flex:1 1;padding:10px 0;width:100%}.modal-module_modal-content__1F-uE{align-items:center;animation:modal-module_show-popup__WrH7a .24s;background:#fff;border-radius:8px;display:flex;flex-direction:column;height:auto;left:0;margin:auto;min-height:130px;overflow:hidden;padding:10px;position:absolute;right:0;top:110px;width:fit-content}@keyframes modal-module_show-popup__WrH7a{0%{transform:translate3d(0,-30%,0)}to{opacity:1;transform:translateZ(0)}}";
|
|
373
|
-
var styles$9 = {"modal-wrap":"modal-module_modal-wrap__IsXXf","modal-top":"modal-module_modal-top__ntDBi","modal-title":"modal-module_modal-title__r-WKl","close-btn":"modal-module_close-btn__Qf2UD","modal-section":"modal-module_modal-section__Bp8jN","modal-content":"modal-module_modal-content__1F-uE","show-popup":"modal-module_show-popup__WrH7a"};
|
|
374
|
-
styleInject(css_248z$b);
|
|
375
|
-
|
|
376
|
-
var css_248z$a = "";
|
|
377
|
-
styleInject(css_248z$a);
|
|
378
|
-
|
|
379
372
|
const _ = require('lodash');
|
|
380
373
|
const compereConfigs = () => {
|
|
381
374
|
let projectConfig = {};
|
|
@@ -399,175 +392,338 @@ const compereConfigs = () => {
|
|
|
399
392
|
return _.merge(packageConfig, projectConfig);
|
|
400
393
|
};
|
|
401
394
|
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
395
|
+
var css_248z$b = ".modal-module_animation__modal__3mt48{animation:modal-module_show-popup__WrH7a .15s;-webkit-animation:modal-module_show-popup__WrH7a .15s}@keyframes modal-module_show-popup__WrH7a{0%{transform:translate3d(0,-50%,0);-webkit-transform:translate3d(0,-50%,0);-moz-transform:translate3d(0,-50%,0);-ms-transform:translate3d(0,-50%,0);-o-transform:translate3d(0,-50%,0)}to{opacity:1;transform:translateZ(0);-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0)}}";
|
|
396
|
+
var styles$9 = {"animation__modal":"modal-module_animation__modal__3mt48","show-popup":"modal-module_show-popup__WrH7a"};
|
|
397
|
+
styleInject(css_248z$b);
|
|
398
|
+
|
|
399
|
+
const SvgNext = ({
|
|
400
|
+
title,
|
|
401
|
+
titleId,
|
|
402
|
+
...props
|
|
403
|
+
}) => /*#__PURE__*/React.createElement("svg", _extends({
|
|
404
|
+
width: "24",
|
|
405
|
+
height: "24",
|
|
406
|
+
viewBox: "0 0 24 24",
|
|
407
|
+
fill: "none",
|
|
408
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
409
|
+
"aria-labelledby": titleId
|
|
410
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
411
|
+
id: titleId
|
|
412
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
413
|
+
fillRule: "evenodd",
|
|
414
|
+
clipRule: "evenodd",
|
|
415
|
+
d: "M12 24c6.627 0 12-5.373 12-12S18.627 0 12 0 0 5.373 0 12s5.373 12 12 12Zm3.4-11.443a.854.854 0 0 0 .198-.548.855.855 0 0 0-.146-.539l-4.137-5.134a.857.857 0 0 0-1.251-.12.856.856 0 0 0-.129 1.207l3.701 4.586-3.838 4.587a.856.856 0 0 0 .739 1.4.858.858 0 0 0 .58-.305l4.284-5.134Z",
|
|
416
|
+
fill: "#fff"
|
|
417
|
+
}));
|
|
418
|
+
|
|
419
|
+
const SvgPrev = ({
|
|
420
|
+
title,
|
|
421
|
+
titleId,
|
|
422
|
+
...props
|
|
423
|
+
}) => /*#__PURE__*/React.createElement("svg", _extends({
|
|
424
|
+
width: "24",
|
|
425
|
+
height: "24",
|
|
426
|
+
viewBox: "0 0 24 24",
|
|
427
|
+
fill: "none",
|
|
428
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
429
|
+
"aria-labelledby": titleId
|
|
430
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
431
|
+
id: titleId
|
|
432
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
433
|
+
fillRule: "evenodd",
|
|
434
|
+
clipRule: "evenodd",
|
|
435
|
+
d: "M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12 12-5.373 12-12S18.627 0 12 0ZM8.6 11.443a.855.855 0 0 0-.198.548c-.013.19.038.38.146.539l4.137 5.133a.857.857 0 0 0 1.251.12.856.856 0 0 0 .129-1.206l-3.701-4.586 3.838-4.587a.856.856 0 0 0-.739-1.4.858.858 0 0 0-.58.305l-4.284 5.134Z",
|
|
436
|
+
fill: "#fff"
|
|
437
|
+
}));
|
|
438
|
+
|
|
439
|
+
const SvgCloseIcon = ({
|
|
440
|
+
title,
|
|
441
|
+
titleId,
|
|
442
|
+
...props
|
|
443
|
+
}) => /*#__PURE__*/React.createElement("svg", _extends({
|
|
444
|
+
width: "14",
|
|
445
|
+
height: "14",
|
|
446
|
+
viewBox: "0 0 14 14",
|
|
447
|
+
fill: "none",
|
|
448
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
449
|
+
"aria-labelledby": titleId
|
|
450
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
451
|
+
id: titleId
|
|
452
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
453
|
+
d: "m12.425.241.006-.005a.95.95 0 0 1 1.34 1.34l-.005.006-5.38 5.38 5.38 5.38.005.007a.95.95 0 0 1-1.34 1.34l-.006-.005-5.38-5.38-5.378 5.37a.951.951 0 1 1-1.34-1.341l5.377-5.37-5.38-5.388-.005-.006a.95.95 0 0 1 1.34-1.34l.006.005 5.38 5.387 5.38-5.38Z",
|
|
454
|
+
fill: "#3C393E"
|
|
455
|
+
}));
|
|
456
|
+
|
|
457
|
+
const SvgCloseSlide = ({
|
|
458
|
+
title,
|
|
459
|
+
titleId,
|
|
460
|
+
...props
|
|
461
|
+
}) => /*#__PURE__*/React.createElement("svg", _extends({
|
|
462
|
+
width: "18",
|
|
463
|
+
height: "18",
|
|
464
|
+
viewBox: "0 0 18 18",
|
|
465
|
+
fill: "none",
|
|
466
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
467
|
+
"aria-labelledby": titleId
|
|
468
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
469
|
+
id: titleId
|
|
470
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
471
|
+
d: "m10.47 8.95 7.29-7.29A1 1 0 0 0 16.35.25L9.06 7.54 1.77.24A1 1 0 0 0 .36 1.65l7.29 7.3-7.3 7.29a.999.999 0 1 0 1.41 1.41l7.3-7.29 7.29 7.29a1 1 0 0 0 1.41-1.41l-7.29-7.29Z",
|
|
472
|
+
fill: "#fff"
|
|
473
|
+
}));
|
|
474
|
+
|
|
475
|
+
const Modal = ({
|
|
476
|
+
type,
|
|
477
|
+
data,
|
|
416
478
|
radius,
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
onClick,
|
|
479
|
+
padding,
|
|
480
|
+
setShow,
|
|
481
|
+
selected,
|
|
421
482
|
children,
|
|
422
|
-
|
|
423
|
-
|
|
483
|
+
minWidth,
|
|
484
|
+
minHeight,
|
|
424
485
|
className,
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
486
|
+
headerText,
|
|
487
|
+
imageWidth,
|
|
488
|
+
headerSize,
|
|
489
|
+
imageHeight,
|
|
490
|
+
headerColor,
|
|
491
|
+
headerWeight,
|
|
492
|
+
headerHeight,
|
|
431
493
|
backgroundColor,
|
|
432
|
-
|
|
494
|
+
layerBackgroundColor
|
|
433
495
|
}) => {
|
|
496
|
+
const [select, setSelect] = useState(0);
|
|
497
|
+
const [innerData, setInnerData] = useState([]);
|
|
434
498
|
const configStyles = compereConfigs();
|
|
435
499
|
const classProps = classnames(className);
|
|
436
|
-
const
|
|
437
|
-
|
|
438
|
-
useEffect(() => {
|
|
439
|
-
if (!Object.values(TypographyType).includes(variant)) {
|
|
440
|
-
setValidVariant(true);
|
|
441
|
-
}
|
|
442
|
-
}, [variant]);
|
|
443
|
-
const handleMouseEnter = () => {
|
|
444
|
-
setIsHover(true);
|
|
500
|
+
const handleCloseModal = () => {
|
|
501
|
+
setShow(false);
|
|
445
502
|
};
|
|
446
|
-
const
|
|
447
|
-
|
|
503
|
+
const handleStopClosing = e => {
|
|
504
|
+
e.stopPropagation();
|
|
448
505
|
};
|
|
449
|
-
const
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
}
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
};
|
|
494
|
-
|
|
495
|
-
variant: 'p'
|
|
496
|
-
};
|
|
497
|
-
|
|
498
|
-
const Modal = ({
|
|
499
|
-
setShow,
|
|
500
|
-
headerText,
|
|
501
|
-
className,
|
|
502
|
-
type,
|
|
503
|
-
data,
|
|
504
|
-
selected,
|
|
505
|
-
children
|
|
506
|
-
}) => {
|
|
507
|
-
classnames(styles$9.modal, className);
|
|
508
|
-
const [select, setSelect] = useState(selected);
|
|
506
|
+
const handleGoTo = e => {
|
|
507
|
+
const goTo = e.target.getAttribute('data-go');
|
|
508
|
+
if (goTo === 'next') {
|
|
509
|
+
if (select >= data.length - 1) {
|
|
510
|
+
setSelect(0);
|
|
511
|
+
} else {
|
|
512
|
+
setSelect(select + 1);
|
|
513
|
+
}
|
|
514
|
+
} else {
|
|
515
|
+
if (select <= 0) {
|
|
516
|
+
setSelect(data.length - 1);
|
|
517
|
+
} else {
|
|
518
|
+
setSelect(select - 1);
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
};
|
|
522
|
+
useEffect(() => {
|
|
523
|
+
if (type === 'images') {
|
|
524
|
+
if (data) {
|
|
525
|
+
if (data.length === 0) {
|
|
526
|
+
alert('Please fill data prop');
|
|
527
|
+
} else {
|
|
528
|
+
setInnerData(data);
|
|
529
|
+
}
|
|
530
|
+
} else {
|
|
531
|
+
alert('Please add data prop on Modal component');
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
}, [type, data, data?.length]);
|
|
535
|
+
useEffect(() => {
|
|
536
|
+
if (selected) {
|
|
537
|
+
if (selected <= 0) {
|
|
538
|
+
setSelect(0);
|
|
539
|
+
} else if (selected >= data.length - 1) {
|
|
540
|
+
setSelect(data.length - 1);
|
|
541
|
+
} else {
|
|
542
|
+
setSelect(selected);
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
}, [selected]);
|
|
546
|
+
useEffect(() => {
|
|
547
|
+
return () => {
|
|
548
|
+
setSelect(0);
|
|
549
|
+
setInnerData([]);
|
|
550
|
+
};
|
|
551
|
+
}, []);
|
|
509
552
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
553
|
+
onClick: handleCloseModal,
|
|
554
|
+
style: {
|
|
555
|
+
top: '0px',
|
|
556
|
+
left: '0px',
|
|
557
|
+
zIndex: 999,
|
|
558
|
+
width: '100%',
|
|
559
|
+
height: '100vh',
|
|
560
|
+
position: 'fixed',
|
|
561
|
+
backgroundColor: layerBackgroundColor ? layerBackgroundColor : configStyles.MODAL.layerBackgroundColor
|
|
516
562
|
}
|
|
517
563
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
518
|
-
|
|
564
|
+
style: {
|
|
565
|
+
position: 'relative',
|
|
566
|
+
width: '100%',
|
|
567
|
+
height: '100vh'
|
|
568
|
+
}
|
|
519
569
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
520
|
-
className: `${styles$9[
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
570
|
+
className: `${classProps} ${styles$9['animation__modal']}`,
|
|
571
|
+
onClick: handleStopClosing,
|
|
572
|
+
style: {
|
|
573
|
+
top: '0px',
|
|
574
|
+
left: '0px',
|
|
575
|
+
right: '0px',
|
|
576
|
+
bottom: '0px',
|
|
577
|
+
margin: 'auto',
|
|
578
|
+
maxWidth: '95%',
|
|
579
|
+
overflow: 'auto',
|
|
580
|
+
maxHeight: '95vh',
|
|
581
|
+
position: 'absolute',
|
|
582
|
+
width: 'fit-content',
|
|
583
|
+
height: 'fit-content',
|
|
584
|
+
boxSizing: 'border-box',
|
|
585
|
+
borderRadius: radius ? radius : configStyles.MODAL.radius,
|
|
586
|
+
minWidth: type === 'content' ? minWidth ? minWidth : '' : '',
|
|
587
|
+
minHeight: type === 'content' ? minHeight ? minHeight : '' : '',
|
|
588
|
+
padding: type === 'content' ? padding ? padding : configStyles.MODAL.padding : '10px',
|
|
589
|
+
backgroundColor: backgroundColor ? backgroundColor : configStyles.MODAL.backgroundColor
|
|
535
590
|
}
|
|
536
591
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
})), /*#__PURE__*/React__default.createElement("div", {
|
|
542
|
-
className: `${styles$9["modal-section"]} modal-section-rem`
|
|
543
|
-
}, /*#__PURE__*/React__default.createElement("div", null, select > 1 ? /*#__PURE__*/React__default.createElement("h1", {
|
|
544
|
-
onClick: () => setSelect(select - 1)
|
|
545
|
-
}, "-") : null, data.map(elem => {
|
|
546
|
-
if (select == elem.id) {
|
|
547
|
-
return /*#__PURE__*/React__default.createElement("img", {
|
|
548
|
-
width: "600px",
|
|
549
|
-
key: elem.id,
|
|
550
|
-
src: elem.url
|
|
551
|
-
});
|
|
592
|
+
style: {
|
|
593
|
+
position: 'relative',
|
|
594
|
+
width: '100%',
|
|
595
|
+
height: '100%'
|
|
552
596
|
}
|
|
553
|
-
}
|
|
554
|
-
|
|
555
|
-
|
|
597
|
+
}, type === 'content' ? /*#__PURE__*/React__default.createElement("div", {
|
|
598
|
+
style: {
|
|
599
|
+
width: '100%',
|
|
600
|
+
display: 'flex',
|
|
601
|
+
alignItems: 'center',
|
|
602
|
+
height: headerHeight ? headerHeight : configStyles.MODAL.headerHeight,
|
|
603
|
+
justifyContent: headerText && type === 'content' ? 'space-between' : 'flex-end'
|
|
604
|
+
}
|
|
605
|
+
}, headerText && type === 'content' && /*#__PURE__*/React__default.createElement("p", {
|
|
606
|
+
style: {
|
|
607
|
+
overflow: 'hidden',
|
|
608
|
+
whiteSpace: 'nowrap',
|
|
609
|
+
textOverflow: 'ellipsis',
|
|
610
|
+
margin: '0px 16px 0px 0px',
|
|
611
|
+
maxWidth: 'calc(100% - 30px)',
|
|
612
|
+
fontSize: headerSize ? headerSize : configStyles.MODAL.headerSize,
|
|
613
|
+
color: headerColor ? headerColor : configStyles.MODAL.headerColor,
|
|
614
|
+
fontWeight: headerWeight ? headerWeight : configStyles.MODAL.headerWeight
|
|
615
|
+
}
|
|
616
|
+
}, headerText), /*#__PURE__*/React__default.createElement("div", {
|
|
617
|
+
onClick: handleCloseModal,
|
|
618
|
+
style: {
|
|
619
|
+
width: '14px',
|
|
620
|
+
height: '14px',
|
|
621
|
+
cursor: 'pointer'
|
|
622
|
+
}
|
|
623
|
+
}, /*#__PURE__*/React__default.createElement(SvgCloseIcon, null))) : /*#__PURE__*/React__default.createElement("button", {
|
|
624
|
+
onClick: handleCloseModal,
|
|
625
|
+
style: {
|
|
626
|
+
position: 'absolute',
|
|
627
|
+
top: '23px',
|
|
628
|
+
width: '18px',
|
|
629
|
+
right: '23px',
|
|
630
|
+
height: '18px',
|
|
631
|
+
border: 'none',
|
|
632
|
+
outline: 'none',
|
|
633
|
+
cursor: 'pointer',
|
|
634
|
+
backgroundColor: 'transparent'
|
|
556
635
|
}
|
|
557
|
-
},
|
|
636
|
+
}, /*#__PURE__*/React__default.createElement(SvgCloseSlide, null)), /*#__PURE__*/React__default.createElement("div", {
|
|
637
|
+
style: {
|
|
638
|
+
display: 'flex',
|
|
639
|
+
alignItems: 'center',
|
|
640
|
+
boxSizing: 'border-box',
|
|
641
|
+
justifyContent: 'center',
|
|
642
|
+
paddingTop: type === 'content' ? '10px' : '0px'
|
|
643
|
+
}
|
|
644
|
+
}, type === 'content' ? children ? children : '' : /*#__PURE__*/React__default.createElement("div", {
|
|
645
|
+
style: {
|
|
646
|
+
width: '100%',
|
|
647
|
+
display: 'flex',
|
|
648
|
+
alignItems: 'center'
|
|
649
|
+
}
|
|
650
|
+
}, innerData && innerData.length > 0 && innerData.map((item, index) => {
|
|
651
|
+
if (select === index) {
|
|
652
|
+
if (!item.hasOwnProperty('url')) {
|
|
653
|
+
alert('Please add url property in data prop on each element');
|
|
654
|
+
} else {
|
|
655
|
+
return /*#__PURE__*/React__default.createElement("img", {
|
|
656
|
+
style: {
|
|
657
|
+
objectFit: 'cover',
|
|
658
|
+
objectPosition: 'center',
|
|
659
|
+
borderRadius: radius ? radius : configStyles.MODAL.radius,
|
|
660
|
+
width: imageWidth ? imageWidth : configStyles.MODAL.imageWidth,
|
|
661
|
+
height: imageHeight ? imageHeight : configStyles.MODAL.imageHeight
|
|
662
|
+
},
|
|
663
|
+
src: item.url,
|
|
664
|
+
key: item.id ? item.id : index
|
|
665
|
+
});
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
}), innerData && innerData.length > 1 && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("button", {
|
|
669
|
+
onClick: handleGoTo,
|
|
670
|
+
"data-go": "prev",
|
|
671
|
+
style: {
|
|
672
|
+
position: 'absolute',
|
|
673
|
+
left: '14px',
|
|
674
|
+
width: '24px',
|
|
675
|
+
height: '24px',
|
|
676
|
+
padding: '0px',
|
|
677
|
+
border: 'none',
|
|
678
|
+
outline: 'none',
|
|
679
|
+
cursor: 'pointer',
|
|
680
|
+
top: 'calc(50% - 12px)',
|
|
681
|
+
backgroundColor: 'transparent'
|
|
682
|
+
}
|
|
683
|
+
}, /*#__PURE__*/React__default.createElement(SvgPrev, null)), /*#__PURE__*/React__default.createElement("button", {
|
|
684
|
+
onClick: handleGoTo,
|
|
685
|
+
"data-go": "next",
|
|
686
|
+
style: {
|
|
687
|
+
position: 'absolute',
|
|
688
|
+
width: '24px',
|
|
689
|
+
right: '14px',
|
|
690
|
+
height: '24px',
|
|
691
|
+
border: 'none',
|
|
692
|
+
padding: '0px',
|
|
693
|
+
outline: 'none',
|
|
694
|
+
cursor: 'pointer',
|
|
695
|
+
top: 'calc(50% - 12px)',
|
|
696
|
+
backgroundColor: 'transparent'
|
|
697
|
+
}
|
|
698
|
+
}, /*#__PURE__*/React__default.createElement(SvgNext, null)))))))));
|
|
558
699
|
};
|
|
559
700
|
Modal.propTypes = {
|
|
701
|
+
data: PropTypes.array,
|
|
702
|
+
type: PropTypes.string,
|
|
560
703
|
setShow: PropTypes.func,
|
|
561
|
-
|
|
704
|
+
radius: PropTypes.string,
|
|
705
|
+
padding: PropTypes.string,
|
|
706
|
+
selected: PropTypes.number,
|
|
707
|
+
minWidth: PropTypes.string,
|
|
708
|
+
minHeight: PropTypes.string,
|
|
562
709
|
className: PropTypes.string,
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
710
|
+
headerText: PropTypes.string,
|
|
711
|
+
imageWidth: PropTypes.string,
|
|
712
|
+
headerSize: PropTypes.string,
|
|
713
|
+
headerColor: PropTypes.string,
|
|
714
|
+
imageHeight: PropTypes.string,
|
|
715
|
+
headerWeight: PropTypes.string,
|
|
716
|
+
headerHeight: PropTypes.string,
|
|
717
|
+
backgroundColor: PropTypes.string,
|
|
718
|
+
layerBackgroundColor: PropTypes.string
|
|
719
|
+
};
|
|
720
|
+
Modal.defaultProps = {
|
|
721
|
+
type: 'content'
|
|
566
722
|
};
|
|
567
723
|
|
|
568
|
-
var css_248z$
|
|
724
|
+
var css_248z$a = ".input-module_input-wrap__NunrE{position:relative;width:100%}.input-module_input-content__kP7lZ{display:flex;width:100%}input:-webkit-autofill,input:-webkit-autofill:active,input:-webkit-autofill:focus,input:-webkit-autofill:hover{background-color:inherit!important}.input-module_error-message-show__OrVSo{animation-fill-mode:forwards;animation-name:input-module_error-show__9MP6k}@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)}}";
|
|
569
725
|
var styles$8 = {"input-wrap":"input-module_input-wrap__NunrE","input-content":"input-module_input-content__kP7lZ","error-message-show":"input-module_error-message-show__OrVSo","error-show":"input-module_error-show__9MP6k"};
|
|
570
|
-
styleInject(css_248z$
|
|
726
|
+
styleInject(css_248z$a);
|
|
571
727
|
|
|
572
728
|
const InputTypes = {
|
|
573
729
|
TEL: 'tel',
|
|
@@ -885,9 +1041,9 @@ Input.defaultProps = {
|
|
|
885
1041
|
type: "text"
|
|
886
1042
|
};
|
|
887
1043
|
|
|
888
|
-
var css_248z$
|
|
1044
|
+
var css_248z$9 = ".radio-module_radio-wrap__-lO7V{align-items:center;cursor:pointer;display:inline-flex;flex-direction:row;flex-wrap:nowrap;margin:0 6px;padding-left:24px;position:relative}.radio-module_radio-wrap__-lO7V>input{height:0;opacity:0;position:absolute;width:0}.radio-module_radio-wrap__-lO7V .radio-module_radio-checkmark__Kvol0{border:1px solid #d9d9d9;border-radius:50%;display:inline-block;height:14px;left:0;margin-right:4px;position:absolute;top:0;transition:border-color .24s;vertical-align:top;width:14px}.radio-module_radio-wrap__-lO7V>.radio-module_radio-checkmark__Kvol0:after{background-color:#d9d9d9;border-radius:50%;bottom:0;content:\"\";height:8px;left:0;margin:auto;opacity:0;position:absolute;right:0;top:0;transition:opacity .24s,background-color .24s;width:8px}.radio-module_radio-wrap__-lO7V input:checked~.radio-module_radio-checkmark__Kvol0:after{background-color:#1890ff;opacity:1}.radio-module_radio-wrap__-lO7V:hover input~.radio-module_radio-checkmark__Kvol0:after{opacity:1}.radio-module_radio-wrap__-lO7V input:checked~.radio-module_radio-checkmark__Kvol0{border-color:#1890ff}";
|
|
889
1045
|
var styles$7 = {"radio-wrap":"radio-module_radio-wrap__-lO7V","radio-checkmark":"radio-module_radio-checkmark__Kvol0"};
|
|
890
|
-
styleInject(css_248z$
|
|
1046
|
+
styleInject(css_248z$9);
|
|
891
1047
|
|
|
892
1048
|
const Radio = ({
|
|
893
1049
|
disabled,
|
|
@@ -1104,27 +1260,9 @@ const SvgArrow = ({
|
|
|
1104
1260
|
fill: "#3C393E"
|
|
1105
1261
|
}));
|
|
1106
1262
|
|
|
1107
|
-
|
|
1108
|
-
title,
|
|
1109
|
-
titleId,
|
|
1110
|
-
...props
|
|
1111
|
-
}) => /*#__PURE__*/React.createElement("svg", _extends({
|
|
1112
|
-
width: "14",
|
|
1113
|
-
height: "14",
|
|
1114
|
-
viewBox: "0 0 14 14",
|
|
1115
|
-
fill: "none",
|
|
1116
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
1117
|
-
"aria-labelledby": titleId
|
|
1118
|
-
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
1119
|
-
id: titleId
|
|
1120
|
-
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
1121
|
-
d: "m12.425.241.006-.005a.95.95 0 0 1 1.34 1.34l-.005.006-5.38 5.38 5.38 5.38.005.007a.95.95 0 0 1-1.34 1.34l-.006-.005-5.38-5.38-5.378 5.37a.951.951 0 1 1-1.34-1.341l5.377-5.37-5.38-5.388-.005-.006a.95.95 0 0 1 1.34-1.34l.006.005 5.38 5.387 5.38-5.38Z",
|
|
1122
|
-
fill: "#3C393E"
|
|
1123
|
-
}));
|
|
1124
|
-
|
|
1125
|
-
var css_248z$7 = ".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:1}.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}}";
|
|
1263
|
+
var css_248z$8 = ".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:1}.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}}";
|
|
1126
1264
|
var styles$6 = {"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"};
|
|
1127
|
-
styleInject(css_248z$
|
|
1265
|
+
styleInject(css_248z$8);
|
|
1128
1266
|
|
|
1129
1267
|
const Select = ({
|
|
1130
1268
|
options,
|
|
@@ -1284,7 +1422,7 @@ const Select = ({
|
|
|
1284
1422
|
});
|
|
1285
1423
|
setExistOptions(modifiedOptions);
|
|
1286
1424
|
}
|
|
1287
|
-
}, [options, multiple, selected, selected
|
|
1425
|
+
}, [options, multiple, selected, selected?.length]);
|
|
1288
1426
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
1289
1427
|
className: classProps
|
|
1290
1428
|
}, label ? /*#__PURE__*/React__default.createElement("label", {
|
|
@@ -1534,9 +1672,9 @@ const SvgToasterSuccess = ({
|
|
|
1534
1672
|
fill: "#0DA574"
|
|
1535
1673
|
}));
|
|
1536
1674
|
|
|
1537
|
-
var css_248z$
|
|
1675
|
+
var css_248z$7 = "#toaster-module_top-left__q0LcN{left:0;top:1em}#toaster-module_top-right__f-AFL{right:0;top:1em}#toaster-module_top-center__eVRbc{left:50%;top:1em;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}#toaster-module_bottom-left__b-YHI{bottom:1em;left:0}#toaster-module_bottom-right__g9ACP{bottom:1em;right:0}#toaster-module_bottom-center__4KcFe{bottom:1em;left:50%;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_top-left__q0LcN{left:0;top:1em}.toaster-module_top-right__f-AFL{right:0;top:1em}.toaster-module_top-center__eVRbc{left:50%;top:1em;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_bottom-left__b-YHI{bottom:1em;left:0}.toaster-module_bottom-right__g9ACP{bottom:1em;right:0}.toaster-module_bottom-center__4KcFe{bottom:1em;left:50%;transform:translateX(-50%);-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%)}.toaster-module_notify-block__pRnEB{-webkit-animation-duration:.5s;animation-duration:.5s;-webkit-animation-fill-mode:both;animation-fill-mode:both}.toaster-module_bounce-in-right__shR2D{-webkit-animation-name:toaster-module_bounceInRight__rSk5p;animation-name:toaster-module_bounceInRight__rSk5p}.toaster-module_bounce-out-right__48pyA{-webkit-animation-name:toaster-module_bounceOutRight__bmFGS;animation-name:toaster-module_bounceOutRight__bmFGS}@keyframes toaster-module_bounceInRight__rSk5p{0%{opacity:0;right:-100%}60%{opacity:1;right:40px}75%{right:0}90%{right:30px}to{right:20px}}@keyframes toaster-module_bounceOutRight__bmFGS{0%{opacity:1;right:20px}60%{opacity:1;right:60px}to{opacity:0;right:-100%}}.toaster-module_bounce-in-left__xoF-M{-webkit-animation-name:toaster-module_bounceInLeft__to59v;animation-name:toaster-module_bounceInLeft__to59v}.toaster-module_bounce-out-left__fDOZw{-webkit-animation-name:toaster-module_bounceOutLeft__k5QgO;animation-name:toaster-module_bounceOutLeft__k5QgO}@keyframes toaster-module_bounceInLeft__to59v{0%{left:-100%;opacity:0}60%{left:40px;opacity:1}75%{left:0}90%{left:30px}to{left:20px}}@keyframes toaster-module_bounceOutLeft__k5QgO{0%{left:20px;opacity:1}60%{left:60px;opacity:1}to{left:-100%;opacity:0}}";
|
|
1538
1676
|
var styles$5 = {"top-left":"toaster-module_top-left__q0LcN","top-right":"toaster-module_top-right__f-AFL","top-center":"toaster-module_top-center__eVRbc","bottom-left":"toaster-module_bottom-left__b-YHI","bottom-right":"toaster-module_bottom-right__g9ACP","bottom-center":"toaster-module_bottom-center__4KcFe","notify-block":"toaster-module_notify-block__pRnEB","bounce-in-right":"toaster-module_bounce-in-right__shR2D","bounceInRight":"toaster-module_bounceInRight__rSk5p","bounce-out-right":"toaster-module_bounce-out-right__48pyA","bounceOutRight":"toaster-module_bounceOutRight__bmFGS","bounce-in-left":"toaster-module_bounce-in-left__xoF-M","bounceInLeft":"toaster-module_bounceInLeft__to59v","bounce-out-left":"toaster-module_bounce-out-left__fDOZw","bounceOutLeft":"toaster-module_bounceOutLeft__k5QgO"};
|
|
1539
|
-
styleInject(css_248z$
|
|
1677
|
+
styleInject(css_248z$7);
|
|
1540
1678
|
|
|
1541
1679
|
const ToasterType = {
|
|
1542
1680
|
info: 'info',
|
|
@@ -1808,9 +1946,9 @@ const SvgTooltip = ({
|
|
|
1808
1946
|
fill: "#D1D1D1"
|
|
1809
1947
|
}));
|
|
1810
1948
|
|
|
1811
|
-
var css_248z$
|
|
1949
|
+
var css_248z$6 = ".tooltip-module_tooltip-block__v8U9u{align-items:center;display:flex;justify-content:center;position:relative}.tooltip-module_tooltip__emM6A{padding:10px;position:absolute;z-index:1}.tooltip-module_tooltip-rel__to9gq{align-items:center;border-radius:5px;-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;-o-border-radius:5px;display:flex;height:auto;justify-content:center;min-height:10px;min-width:30px;position:relative;width:auto}.tooltip-module_tooltip-decor__qvt7t{border-radius:2px;-webkit-border-radius:2px;-moz-border-radius:2px;-ms-border-radius:2px;-o-border-radius:2px;height:10px;position:absolute;transform:rotate(45deg);-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);-o-transform:rotate(45deg);width:10px;z-index:-1}";
|
|
1812
1950
|
var styles$4 = {"tooltip-block":"tooltip-module_tooltip-block__v8U9u","tooltip":"tooltip-module_tooltip__emM6A","tooltip-rel":"tooltip-module_tooltip-rel__to9gq","tooltip-decor":"tooltip-module_tooltip-decor__qvt7t"};
|
|
1813
|
-
styleInject(css_248z$
|
|
1951
|
+
styleInject(css_248z$6);
|
|
1814
1952
|
|
|
1815
1953
|
const Tooltip = ({
|
|
1816
1954
|
type,
|
|
@@ -1940,9 +2078,9 @@ const SvgCaptchaArrowDown = ({
|
|
|
1940
2078
|
fill: "#00236A"
|
|
1941
2079
|
}));
|
|
1942
2080
|
|
|
1943
|
-
var css_248z$
|
|
2081
|
+
var css_248z$5 = ".captcha-module_start-point__LkOqy:after{background-color:#d1d1d1;border:2px solid #fff;border-radius:6px;-webkit-border-radius:6px;-moz-border-radius:6px;-ms-border-radius:6px;-o-border-radius:6px;content:\"\";height:10px;left:0;position:absolute;top:7.5px;width:10px;z-index:-1}.captcha-module_range__k24I2{-webkit-appearance:none;margin:0}.captcha-module_range__k24I2::-webkit-slider-runnable-track{-webkit-appearance:none;width:100%}.captcha-module_range-default__-O0QD::-webkit-slider-thumb{background-image:url(../../assets/range-arrow-default.svg)}.captcha-module_range-default__-O0QD::-webkit-slider-thumb,.captcha-module_range-error__FKMfG::-webkit-slider-thumb{-webkit-appearance:none;background-position:-5px;background-repeat:no-repeat;background-size:46px 46px;border-radius:17px;-webkit-border-radius:17px;-moz-border-radius:17px;-ms-border-radius:17px;-o-border-radius:17px;cursor:ew-resize;height:34px;width:34px}.captcha-module_range-error__FKMfG::-webkit-slider-thumb{background-image:url(../../assets/range-arrow-error.svg)}.captcha-module_range-success__VzLPq::-webkit-slider-thumb{-webkit-appearance:none;background-image:url(../../assets/range-arrow-success.svg);background-position:-5px;background-repeat:no-repeat;background-size:46px 46px;border-radius:17px;-webkit-border-radius:17px;-moz-border-radius:17px;-ms-border-radius:17px;-o-border-radius:17px;cursor:ew-resize;height:34px;width:34px}";
|
|
1944
2082
|
var styles$3 = {"start-point":"captcha-module_start-point__LkOqy","range":"captcha-module_range__k24I2","range-default":"captcha-module_range-default__-O0QD","range-error":"captcha-module_range-error__FKMfG","range-success":"captcha-module_range-success__VzLPq"};
|
|
1945
|
-
styleInject(css_248z$
|
|
2083
|
+
styleInject(css_248z$5);
|
|
1946
2084
|
|
|
1947
2085
|
const Captcha = ({
|
|
1948
2086
|
size,
|
|
@@ -2064,9 +2202,9 @@ Captcha.propTypes = {
|
|
|
2064
2202
|
getRange: PropTypes.func.isRequired
|
|
2065
2203
|
};
|
|
2066
2204
|
|
|
2067
|
-
var css_248z$
|
|
2205
|
+
var css_248z$4 = ".stepper-module_stepper-container__-OVGy>div:last-child:before{display:none}.stepper-module_activeRing__Lzvh1,.stepper-module_bigRing__5GBm0{border-radius:50%;cursor:pointer;height:36px;margin-bottom:36px;position:relative;width:36px}.stepper-module_bigRing__5GBm0{box-shadow:0 0 0 2px #d1d1d1}.stepper-module_bigRing__5GBm0:before{background:#d1d1d1}.stepper-module_activeRing__Lzvh1{box-shadow:0 0 0 2px #00236a}.stepper-module_activeRing__Lzvh1:before{background:#00236a}.stepper-module_activeRing__Lzvh1:before,.stepper-module_bigRing__5GBm0:before{border-radius:20px;bottom:-32px;content:\"\";height:28px;left:0;margin:auto;overflow:hidden;position:absolute;right:0;width:2px}.stepper-module_smallActiveRing__im-XG,.stepper-module_smallRing__u-5a8{border-radius:50%;bottom:0;left:0;margin:auto;position:absolute;right:0;top:0}.stepper-module_smallRing__u-5a8{background-color:#d1d1d1;height:14px;width:14px}.stepper-module_smallActiveRing__im-XG{align-items:center;background-color:#00236a;color:#fff;display:flex;height:28px;justify-content:center;width:28px}";
|
|
2068
2206
|
var styles$2 = {"stepper-container":"stepper-module_stepper-container__-OVGy","bigRing":"stepper-module_bigRing__5GBm0","activeRing":"stepper-module_activeRing__Lzvh1","smallRing":"stepper-module_smallRing__u-5a8","smallActiveRing":"stepper-module_smallActiveRing__im-XG"};
|
|
2069
|
-
styleInject(css_248z$
|
|
2207
|
+
styleInject(css_248z$4);
|
|
2070
2208
|
|
|
2071
2209
|
const Stepper = ({
|
|
2072
2210
|
className,
|
|
@@ -2894,8 +3032,8 @@ NewFile.defaultProps = {
|
|
|
2894
3032
|
fileExtensions: ['jpg', 'jpeg', 'png', 'pdf']
|
|
2895
3033
|
};
|
|
2896
3034
|
|
|
2897
|
-
var css_248z$
|
|
2898
|
-
styleInject(css_248z$
|
|
3035
|
+
var css_248z$3 = "textarea::-webkit-scrollbar{width:6px}textarea::-webkit-scrollbar-track{background:#eee}textarea::-webkit-scrollbar-thumb,textarea::-webkit-scrollbar-track{border-radius:3px;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;-o-border-radius:3px}textarea::-webkit-scrollbar-thumb{background:#d1d1d1}";
|
|
3036
|
+
styleInject(css_248z$3);
|
|
2899
3037
|
|
|
2900
3038
|
const Textarea = ({
|
|
2901
3039
|
size,
|
|
@@ -3074,6 +3212,105 @@ Textarea.propTypes = {
|
|
|
3074
3212
|
labelRequiredColor: PropTypes.string
|
|
3075
3213
|
};
|
|
3076
3214
|
|
|
3215
|
+
var css_248z$2 = "";
|
|
3216
|
+
styleInject(css_248z$2);
|
|
3217
|
+
|
|
3218
|
+
const TypographyType = {
|
|
3219
|
+
p: 'p',
|
|
3220
|
+
h1: 'h1',
|
|
3221
|
+
h2: 'h2',
|
|
3222
|
+
h3: 'h3',
|
|
3223
|
+
h4: 'h4',
|
|
3224
|
+
h5: 'h5',
|
|
3225
|
+
h6: 'h6',
|
|
3226
|
+
span: 'span'
|
|
3227
|
+
};
|
|
3228
|
+
const Typography = ({
|
|
3229
|
+
size,
|
|
3230
|
+
color,
|
|
3231
|
+
weight,
|
|
3232
|
+
radius,
|
|
3233
|
+
border,
|
|
3234
|
+
cursor,
|
|
3235
|
+
variant,
|
|
3236
|
+
onClick,
|
|
3237
|
+
children,
|
|
3238
|
+
textAlign,
|
|
3239
|
+
fontStyle,
|
|
3240
|
+
className,
|
|
3241
|
+
textShadow,
|
|
3242
|
+
lineHeight,
|
|
3243
|
+
colorHover,
|
|
3244
|
+
fontFamily,
|
|
3245
|
+
textTransform,
|
|
3246
|
+
textDecoration,
|
|
3247
|
+
backgroundColor,
|
|
3248
|
+
...props
|
|
3249
|
+
}) => {
|
|
3250
|
+
const configStyles = compereConfigs();
|
|
3251
|
+
const classProps = classnames(className);
|
|
3252
|
+
const [isHover, setIsHover] = useState(false);
|
|
3253
|
+
const [validVariant, setValidVariant] = useState(false);
|
|
3254
|
+
useEffect(() => {
|
|
3255
|
+
if (!Object.values(TypographyType).includes(variant)) {
|
|
3256
|
+
setValidVariant(true);
|
|
3257
|
+
}
|
|
3258
|
+
}, [variant]);
|
|
3259
|
+
const handleMouseEnter = () => {
|
|
3260
|
+
setIsHover(true);
|
|
3261
|
+
};
|
|
3262
|
+
const handleMouseLeave = () => {
|
|
3263
|
+
setIsHover(false);
|
|
3264
|
+
};
|
|
3265
|
+
const tagT = /*#__PURE__*/React__default.createElement(variant, {
|
|
3266
|
+
style: {
|
|
3267
|
+
border: border ? border : configStyles.TYPOGRAPHY.border,
|
|
3268
|
+
cursor: cursor ? cursor : configStyles.TYPOGRAPHY.cursor,
|
|
3269
|
+
borderRadius: radius ? radius : configStyles.TYPOGRAPHY.radius,
|
|
3270
|
+
fontSize: size ? size : configStyles.TYPOGRAPHY['size' + variant],
|
|
3271
|
+
fontWeight: weight ? weight : configStyles.TYPOGRAPHY['weight' + variant],
|
|
3272
|
+
textShadow: textShadow ? textShadow : configStyles.TYPOGRAPHY.textShadow,
|
|
3273
|
+
textAlign: textAlign ? textAlign : configStyles.TYPOGRAPHY['textAlign' + variant],
|
|
3274
|
+
fontStyle: fontStyle ? fontStyle : configStyles.TYPOGRAPHY['fontStyle' + variant],
|
|
3275
|
+
lineHeight: lineHeight ? lineHeight : configStyles.TYPOGRAPHY['lineHeight' + variant],
|
|
3276
|
+
fontFamily: fontFamily ? fontFamily : configStyles.TYPOGRAPHY['fontFamily' + variant],
|
|
3277
|
+
textTransform: textTransform ? textTransform : configStyles.TYPOGRAPHY['textTransform' + variant],
|
|
3278
|
+
textDecoration: textDecoration ? textDecoration : configStyles.TYPOGRAPHY['textDecoration' + variant],
|
|
3279
|
+
backgroundColor: backgroundColor ? backgroundColor : configStyles.TYPOGRAPHY['backgroundColor' + variant],
|
|
3280
|
+
color: isHover ? colorHover ? colorHover : color ? color : configStyles.TYPOGRAPHY['color' + variant] : color ? color : configStyles.TYPOGRAPHY['color' + variant]
|
|
3281
|
+
},
|
|
3282
|
+
...props,
|
|
3283
|
+
className: classProps,
|
|
3284
|
+
onClick: onClick ? onClick : _ => _,
|
|
3285
|
+
onMouseEnter: handleMouseEnter,
|
|
3286
|
+
onMouseLeave: handleMouseLeave
|
|
3287
|
+
}, [children]);
|
|
3288
|
+
return validVariant ? 'Please set Typography valid variant' : tagT;
|
|
3289
|
+
};
|
|
3290
|
+
Typography.propTypes = {
|
|
3291
|
+
size: PropTypes.string,
|
|
3292
|
+
color: PropTypes.string,
|
|
3293
|
+
onClick: PropTypes.func,
|
|
3294
|
+
weight: PropTypes.string,
|
|
3295
|
+
border: PropTypes.string,
|
|
3296
|
+
cursor: PropTypes.string,
|
|
3297
|
+
radius: PropTypes.string,
|
|
3298
|
+
textAlign: PropTypes.string,
|
|
3299
|
+
className: PropTypes.string,
|
|
3300
|
+
fontStyle: PropTypes.string,
|
|
3301
|
+
lineHeight: PropTypes.string,
|
|
3302
|
+
textShadow: PropTypes.string,
|
|
3303
|
+
fontFamily: PropTypes.string,
|
|
3304
|
+
colorHover: PropTypes.string,
|
|
3305
|
+
textTransform: PropTypes.string,
|
|
3306
|
+
textDecoration: PropTypes.string,
|
|
3307
|
+
backgroundColor: PropTypes.string,
|
|
3308
|
+
variant: PropTypes.oneOf(Object.values(TypographyType))
|
|
3309
|
+
};
|
|
3310
|
+
Typography.defaultProps = {
|
|
3311
|
+
variant: 'p'
|
|
3312
|
+
};
|
|
3313
|
+
|
|
3077
3314
|
var css_248z$1 = ".pagination-module_listItem__b1-WN:focus{background-color:#4caf50;color:#fff}.pagination-module_listItem__b1-WN:hover:not(.pagination-module_active__KwBDp){background-color:#ddd}.pagination-module_pagination-bar__MrtYT{display:flex;flex-direction:row;flex-wrap:nowrap;gap:8px;justify-content:center}.pagination-module_pagination-btn__w8Yh8{border:none;border-radius:6px;outline:none}.pagination-module_pagination-btn__w8Yh8,.pagination-module_pagination-item__t3emS,.pagination-module_pagination-jump-next__LAb9Z{align-items:center;background-color:#fff;box-shadow:0 0 0 1px #eee;cursor:pointer;display:flex;height:34px;justify-content:center;width:34px}.pagination-module_pagination-item__t3emS,.pagination-module_pagination-jump-next__LAb9Z{border-radius:6px;flex:0 0 auto;font-size:13px;line-height:16px;position:relative;transition:background-color .24s}.pagination-module_pagination-item__t3emS:hover{background-color:#eee}.pagination-module_pagination-item__t3emS.pagination-module_selected__EXzCA{background-color:#00236a;color:#fff}.pagination-module_pagination-jump-next-arrow__aEVD8,.pagination-module_pagination-jump-next-txt__e7nFj{align-items:center;bottom:0;display:flex;font-size:12px;justify-content:center;left:0;line-height:14px;margin:auto;position:absolute;right:0;top:0;transition:opacity .24s,color .24s}.pagination-module_pagination-jump-next-arrow__aEVD8{opacity:0}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-arrow__aEVD8{opacity:1}.pagination-module_pagination-jump-next__LAb9Z:hover .pagination-module_pagination-jump-next-txt__e7nFj{opacity:0}i{color:#3c393e;font-size:12px;line-height:12px}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}";
|
|
3078
3315
|
var styles$1 = {"listItem":"pagination-module_listItem__b1-WN","active":"pagination-module_active__KwBDp","pagination-bar":"pagination-module_pagination-bar__MrtYT","pagination-btn":"pagination-module_pagination-btn__w8Yh8","pagination-item":"pagination-module_pagination-item__t3emS","pagination-jump-next":"pagination-module_pagination-jump-next__LAb9Z","selected":"pagination-module_selected__EXzCA","pagination-jump-next-txt":"pagination-module_pagination-jump-next-txt__e7nFj","pagination-jump-next-arrow":"pagination-module_pagination-jump-next-arrow__aEVD8"};
|
|
3079
3316
|
styleInject(css_248z$1);
|
|
@@ -3470,6 +3707,7 @@ const NewAutocomplete = ({
|
|
|
3470
3707
|
getItem,
|
|
3471
3708
|
required,
|
|
3472
3709
|
disabled,
|
|
3710
|
+
selected,
|
|
3473
3711
|
errorSize,
|
|
3474
3712
|
labelSize,
|
|
3475
3713
|
errorColor,
|
|
@@ -3584,7 +3822,7 @@ const NewAutocomplete = ({
|
|
|
3584
3822
|
getItem(selectedValue);
|
|
3585
3823
|
setInnerValue(selectedValue.name);
|
|
3586
3824
|
};
|
|
3587
|
-
const optionList = /*#__PURE__*/React__default.createElement(React__default.Fragment, null, show && innerOptions ? innerOptions.length > 0 ? /*#__PURE__*/React__default.createElement("div", {
|
|
3825
|
+
const optionList = /*#__PURE__*/React__default.createElement(React__default.Fragment, null, show && innerOptions && !disabled ? innerOptions.length > 0 ? /*#__PURE__*/React__default.createElement("div", {
|
|
3588
3826
|
style: {
|
|
3589
3827
|
left: contentBottomLeft ? contentBottomLeft : configStyles.NEWAUTOCOMPLETE.contentBottomLeft,
|
|
3590
3828
|
width: contentBottomWidth ? contentBottomWidth : configStyles.NEWAUTOCOMPLETE.contentBottomWidth,
|
|
@@ -3654,12 +3892,19 @@ const NewAutocomplete = ({
|
|
|
3654
3892
|
alert('Please add getItem function for get choosen item from autocomplete');
|
|
3655
3893
|
}
|
|
3656
3894
|
options && setInnerOptions(options);
|
|
3657
|
-
}, [options, options
|
|
3895
|
+
}, [options, options?.length, getItem]);
|
|
3658
3896
|
useEffect(() => {
|
|
3659
3897
|
if (!change) {
|
|
3660
3898
|
alert('Please add change prop on New Autocomplete component');
|
|
3661
3899
|
}
|
|
3662
3900
|
}, [change]);
|
|
3901
|
+
useEffect(() => {
|
|
3902
|
+
if (selected) {
|
|
3903
|
+
setInnerValue(selected);
|
|
3904
|
+
} else {
|
|
3905
|
+
setInnerValue('');
|
|
3906
|
+
}
|
|
3907
|
+
}, [selected, selected?.length]);
|
|
3663
3908
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, label ? /*#__PURE__*/React__default.createElement("label", {
|
|
3664
3909
|
style: {
|
|
3665
3910
|
color: labelColor ? labelColor : configStyles.NEWAUTOCOMPLETE.labelColor,
|
|
@@ -3724,6 +3969,7 @@ NewAutocomplete.propTypes = {
|
|
|
3724
3969
|
label: PropTypes.string,
|
|
3725
3970
|
required: PropTypes.bool,
|
|
3726
3971
|
disabled: PropTypes.bool,
|
|
3972
|
+
selected: PropTypes.string,
|
|
3727
3973
|
errorSize: PropTypes.string,
|
|
3728
3974
|
labelSize: PropTypes.string,
|
|
3729
3975
|
errorColor: PropTypes.string,
|