sprint-asia-custom-component 0.1.14 → 0.1.16
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.js
CHANGED
|
@@ -23768,7 +23768,8 @@
|
|
|
23768
23768
|
|
|
23769
23769
|
const Description = ({
|
|
23770
23770
|
title = "Title",
|
|
23771
|
-
value = "Description"
|
|
23771
|
+
value = "Description",
|
|
23772
|
+
textColor = "default"
|
|
23772
23773
|
}) => {
|
|
23773
23774
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
23774
23775
|
className: "w-full"
|
|
@@ -23777,7 +23778,10 @@
|
|
|
23777
23778
|
}, title), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
23778
23779
|
className: "py-1"
|
|
23779
23780
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
23780
|
-
className:
|
|
23781
|
+
className: `
|
|
23782
|
+
${textColor == "default" && "text-black"}
|
|
23783
|
+
${textColor == "success" && "text-success500"}
|
|
23784
|
+
"font-medium text-medium"`
|
|
23781
23785
|
}, value)));
|
|
23782
23786
|
};
|
|
23783
23787
|
|
|
@@ -44004,7 +44008,7 @@
|
|
|
44004
44008
|
title = 'Title Modal',
|
|
44005
44009
|
subtitle = 'Subtitle Modal',
|
|
44006
44010
|
type = 'default',
|
|
44007
|
-
addition,
|
|
44011
|
+
addition = "state",
|
|
44008
44012
|
placeholderTextArea,
|
|
44009
44013
|
onChangeTextArea,
|
|
44010
44014
|
valueTextArea,
|
|
@@ -44023,6 +44027,8 @@
|
|
|
44023
44027
|
return typeof valueTextArea === 'string' && valueTextArea.trim() !== '';
|
|
44024
44028
|
} else if (addition === 'dropzone&input') {
|
|
44025
44029
|
return fileUploaded && typeof textInputValue === 'string' && textInputValue.trim() !== '';
|
|
44030
|
+
} else if (addition === 'state') {
|
|
44031
|
+
return true;
|
|
44026
44032
|
}
|
|
44027
44033
|
return false;
|
|
44028
44034
|
};
|
|
@@ -44069,7 +44075,7 @@
|
|
|
44069
44075
|
className: "cursor-pointer text-xl",
|
|
44070
44076
|
onClick: onClose
|
|
44071
44077
|
}, "x")), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
44072
|
-
className: "border-
|
|
44078
|
+
className: "border-t border-b border-neutral30 py-6"
|
|
44073
44079
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
44074
44080
|
className: "font-normal text-lg text-neutral500 px-6"
|
|
44075
44081
|
}, subtitle), addition == "textarea" && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -46398,14 +46404,14 @@
|
|
|
46398
46404
|
break;
|
|
46399
46405
|
}
|
|
46400
46406
|
return /*#__PURE__*/React__default["default"].createElement("tr", {
|
|
46401
|
-
className: `bg-white hover:bg-neutral20 border-t border-neutral40 ${onClickBody != undefined && "cursor-pointer"}
|
|
46407
|
+
className: `bg-white hover:bg-neutral20 border-t border-neutral40 ${onClickBody != undefined && "cursor-pointer"}`
|
|
46408
|
+
}, /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46409
|
+
className: "flex items-center",
|
|
46402
46410
|
onClick: () => {
|
|
46403
46411
|
if (onClickBody != undefined) {
|
|
46404
46412
|
onClickBody();
|
|
46405
46413
|
}
|
|
46406
46414
|
}
|
|
46407
|
-
}, /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46408
|
-
className: "flex items-center"
|
|
46409
46415
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46410
46416
|
className: "py-3.5 px-4"
|
|
46411
46417
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
@@ -46417,7 +46423,12 @@
|
|
|
46417
46423
|
}, Column_One_C), /*#__PURE__*/React__default["default"].createElement("p", {
|
|
46418
46424
|
className: "font-normal text-neutral300 text-sm"
|
|
46419
46425
|
}, Column_One_D)))), /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46420
|
-
className: "flex items-center"
|
|
46426
|
+
className: "flex items-center",
|
|
46427
|
+
onClick: () => {
|
|
46428
|
+
if (onClickBody != undefined) {
|
|
46429
|
+
onClickBody();
|
|
46430
|
+
}
|
|
46431
|
+
}
|
|
46421
46432
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46422
46433
|
className: "py-3.5 px-4"
|
|
46423
46434
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
@@ -46433,7 +46444,12 @@
|
|
|
46433
46444
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
46434
46445
|
className: "font-normal text-neutral500 text-sm"
|
|
46435
46446
|
}, "\xA0"))))), /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46436
|
-
className: "flex items-center"
|
|
46447
|
+
className: "flex items-center",
|
|
46448
|
+
onClick: () => {
|
|
46449
|
+
if (onClickBody != undefined) {
|
|
46450
|
+
onClickBody();
|
|
46451
|
+
}
|
|
46452
|
+
}
|
|
46437
46453
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46438
46454
|
className: "py-3.5 px-4"
|
|
46439
46455
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
@@ -46451,7 +46467,12 @@
|
|
|
46451
46467
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
46452
46468
|
className: "font-normal text-neutral500 text-sm"
|
|
46453
46469
|
}, "\xA0"))))), /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46454
|
-
className: "flex items-center"
|
|
46470
|
+
className: "flex items-center",
|
|
46471
|
+
onClick: () => {
|
|
46472
|
+
if (onClickBody != undefined) {
|
|
46473
|
+
onClickBody();
|
|
46474
|
+
}
|
|
46475
|
+
}
|
|
46455
46476
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46456
46477
|
className: "py-3.5 px-4"
|
|
46457
46478
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
@@ -46469,7 +46490,12 @@
|
|
|
46469
46490
|
}, /*#__PURE__*/React__default["default"].createElement("p", {
|
|
46470
46491
|
className: "font-normal text-neutral500 text-sm"
|
|
46471
46492
|
}, "\xA0"))))), /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46472
|
-
className: "flex items-center"
|
|
46493
|
+
className: "flex items-center",
|
|
46494
|
+
onClick: () => {
|
|
46495
|
+
if (onClickBody != undefined) {
|
|
46496
|
+
onClickBody();
|
|
46497
|
+
}
|
|
46498
|
+
}
|
|
46473
46499
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
46474
46500
|
className: "py-3.5 px-4"
|
|
46475
46501
|
}, /*#__PURE__*/React__default["default"].createElement(Chip, {
|
|
@@ -46615,7 +46641,7 @@
|
|
|
46615
46641
|
className: "rounded-md shadow-sm"
|
|
46616
46642
|
}, /*#__PURE__*/React__default["default"].createElement("button", {
|
|
46617
46643
|
type: "button",
|
|
46618
|
-
className: "flex items-center w-60 py-2.5 text-left px-4 bg-
|
|
46644
|
+
className: "flex items-center w-60 py-2.5 text-left px-4 bg-white border-neutral50 font-normal text-sm text-neutral300 rounded-md border focus:outline-none",
|
|
46619
46645
|
onClick: () => setShowFilterMenu(!showFilterMenu)
|
|
46620
46646
|
}, /*#__PURE__*/React__default["default"].createElement("span", {
|
|
46621
46647
|
className: "flex-grow"
|
package/package.json
CHANGED
|
@@ -2,13 +2,17 @@ import React from 'react';
|
|
|
2
2
|
|
|
3
3
|
const Description = ({
|
|
4
4
|
title = "Title",
|
|
5
|
-
value = "Description"
|
|
5
|
+
value = "Description",
|
|
6
|
+
textColor = "default",
|
|
6
7
|
}) => {
|
|
7
8
|
return (
|
|
8
9
|
<div className='w-full'>
|
|
9
10
|
{title && <p className="text-sm font-normal text-black mb-1">{title}</p>}
|
|
10
11
|
<div className='py-1'>
|
|
11
|
-
<p className=
|
|
12
|
+
<p className={`
|
|
13
|
+
${textColor == "default" && "text-black"}
|
|
14
|
+
${textColor == "success" && "text-success500"}
|
|
15
|
+
"font-medium text-medium"`}>{value}</p>
|
|
12
16
|
</div>
|
|
13
17
|
</div>
|
|
14
18
|
);
|
|
@@ -59,7 +59,7 @@ const FilterDropdown = ({
|
|
|
59
59
|
<span className='rounded-md shadow-sm'>
|
|
60
60
|
<button
|
|
61
61
|
type='button'
|
|
62
|
-
className="flex items-center w-60 py-2.5 text-left px-4 bg-
|
|
62
|
+
className="flex items-center w-60 py-2.5 text-left px-4 bg-white border-neutral50 font-normal text-sm text-neutral300 rounded-md border focus:outline-none"
|
|
63
63
|
onClick={() => setShowFilterMenu(!showFilterMenu)}
|
|
64
64
|
>
|
|
65
65
|
<span className='flex-grow'>{buttonText}</span>
|
|
@@ -14,7 +14,7 @@ const ModalState = ({
|
|
|
14
14
|
title = 'Title Modal',
|
|
15
15
|
subtitle = 'Subtitle Modal',
|
|
16
16
|
type = 'default',
|
|
17
|
-
addition,
|
|
17
|
+
addition = "state",
|
|
18
18
|
placeholderTextArea,
|
|
19
19
|
onChangeTextArea,
|
|
20
20
|
valueTextArea,
|
|
@@ -33,9 +33,13 @@ const ModalState = ({
|
|
|
33
33
|
if (addition === 'textarea') {
|
|
34
34
|
// Check if valueTextArea is a string before calling .trim()
|
|
35
35
|
return typeof valueTextArea === 'string' && valueTextArea.trim() !== '';
|
|
36
|
-
}
|
|
36
|
+
}
|
|
37
|
+
else if (addition === 'dropzone&input') {
|
|
37
38
|
return fileUploaded && typeof textInputValue === 'string' && textInputValue.trim() !== '';
|
|
38
39
|
}
|
|
40
|
+
else if (addition === 'state') {
|
|
41
|
+
return true
|
|
42
|
+
}
|
|
39
43
|
return false;
|
|
40
44
|
};
|
|
41
45
|
|
|
@@ -76,7 +80,7 @@ const ModalState = ({
|
|
|
76
80
|
x
|
|
77
81
|
</p>
|
|
78
82
|
</div>
|
|
79
|
-
<div className="border-
|
|
83
|
+
<div className="border-t border-b border-neutral30 py-6">
|
|
80
84
|
<p className="font-normal text-lg text-neutral500 px-6">{subtitle}</p>
|
|
81
85
|
{
|
|
82
86
|
addition == "textarea" &&
|
|
@@ -36,16 +36,16 @@ const CellModelOne = ({
|
|
|
36
36
|
return (
|
|
37
37
|
<tr
|
|
38
38
|
className={`bg-white hover:bg-neutral20 border-t border-neutral40 ${onClickBody != undefined && "cursor-pointer"}`}
|
|
39
|
-
onClick={
|
|
40
|
-
() => {
|
|
41
|
-
if (onClickBody != undefined) {
|
|
42
|
-
onClickBody()
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
39
|
>
|
|
47
40
|
<td>
|
|
48
|
-
<div className='flex items-center'
|
|
41
|
+
<div className='flex items-center'
|
|
42
|
+
onClick={
|
|
43
|
+
() => {
|
|
44
|
+
if (onClickBody != undefined) {
|
|
45
|
+
onClickBody()
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}>
|
|
49
49
|
<div className= "py-3.5 px-4">
|
|
50
50
|
<p className='font-semibold text-black text-sm'>{Column_One_A}</p>
|
|
51
51
|
<p className='font-normal text-neutral300 text-sm'>{Column_One_B}</p>
|
|
@@ -55,7 +55,14 @@ const CellModelOne = ({
|
|
|
55
55
|
</div>
|
|
56
56
|
</td>
|
|
57
57
|
<td>
|
|
58
|
-
<div className='flex items-center'
|
|
58
|
+
<div className='flex items-center'
|
|
59
|
+
onClick={
|
|
60
|
+
() => {
|
|
61
|
+
if (onClickBody != undefined) {
|
|
62
|
+
onClickBody()
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}>
|
|
59
66
|
<div className= "py-3.5 px-4">
|
|
60
67
|
<p className='font-semibold text-black text-sm'>{Column_Two_A}</p>
|
|
61
68
|
<p className='font-normal text-neutral300 text-sm'>{Column_Two_B}</p>
|
|
@@ -69,7 +76,14 @@ const CellModelOne = ({
|
|
|
69
76
|
</div>
|
|
70
77
|
</td>
|
|
71
78
|
<td>
|
|
72
|
-
<div className='flex items-center'
|
|
79
|
+
<div className='flex items-center'
|
|
80
|
+
onClick={
|
|
81
|
+
() => {
|
|
82
|
+
if (onClickBody != undefined) {
|
|
83
|
+
onClickBody()
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}>
|
|
73
87
|
<div className= "py-3.5 px-4">
|
|
74
88
|
<p className='font-normal text-black text-sm'>{Column_Three_A}</p>
|
|
75
89
|
<div className='flex items-center pt-1'>
|
|
@@ -85,7 +99,14 @@ const CellModelOne = ({
|
|
|
85
99
|
</div>
|
|
86
100
|
</td>
|
|
87
101
|
<td>
|
|
88
|
-
<div className='flex items-center'
|
|
102
|
+
<div className='flex items-center'
|
|
103
|
+
onClick={
|
|
104
|
+
() => {
|
|
105
|
+
if (onClickBody != undefined) {
|
|
106
|
+
onClickBody()
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}>
|
|
89
110
|
<div className= "py-3.5 px-4">
|
|
90
111
|
<p className='font-normal text-black text-sm'>{Column_Four_A}</p>
|
|
91
112
|
<div className='flex items-center pt-1'>
|
|
@@ -101,7 +122,14 @@ const CellModelOne = ({
|
|
|
101
122
|
</div>
|
|
102
123
|
</td>
|
|
103
124
|
<td>
|
|
104
|
-
<div className='flex items-center'
|
|
125
|
+
<div className='flex items-center'
|
|
126
|
+
onClick={
|
|
127
|
+
() => {
|
|
128
|
+
if (onClickBody != undefined) {
|
|
129
|
+
onClickBody()
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}>
|
|
105
133
|
<div className= "py-3.5 px-4">
|
|
106
134
|
<Chip
|
|
107
135
|
type={chipType}
|