ok
This commit is contained in:
@@ -168,37 +168,50 @@ const Item = ({
|
|||||||
lineHeight: '1rem',
|
lineHeight: '1rem',
|
||||||
marginLeft: 10
|
marginLeft: 10
|
||||||
}}>
|
}}>
|
||||||
{promoPrice && promoPrice != 0 && promoPrice != '' &&
|
{promoPrice && promoPrice != 0 && promoPrice != '' ?
|
||||||
<div style={{
|
<>
|
||||||
position: 'relative',
|
<div style={{
|
||||||
marginTop: '0.125rem',
|
position: 'relative',
|
||||||
display: 'flex',
|
marginTop: '0.125rem',
|
||||||
width: 'max-content',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
width: 'max-content',
|
||||||
whiteSpace: 'nowrap',
|
alignItems: 'center',
|
||||||
borderRadius: '9999px',
|
whiteSpace: 'nowrap',
|
||||||
backgroundImage: 'linear-gradient(to right, #e52535, #eb525e)',
|
borderRadius: '9999px',
|
||||||
padding: '0.25rem 0.75rem',
|
backgroundImage: 'linear-gradient(to right, #e52535, #eb525e)',
|
||||||
color: 'rgb(255, 255, 255)',
|
padding: '0.25rem 0.75rem',
|
||||||
fontSize: '0.75rem',
|
color: 'rgb(255, 255, 255)',
|
||||||
fontWeight: 600,
|
fontSize: '0.75rem',
|
||||||
lineHeight: '1rem'
|
fontWeight: 600,
|
||||||
}}>
|
lineHeight: '1rem'
|
||||||
Promo
|
}}>
|
||||||
</div>
|
Promo {(((initialPrice - promoPrice) / initialPrice) * 100).toFixed(0)}%
|
||||||
}
|
</div>
|
||||||
<div style={{ display: 'flex' }}>
|
|
||||||
<span style={{
|
<div style={{ display: 'flex' }}>
|
||||||
marginLeft: '1rem',
|
<span style={{
|
||||||
marginRight: '0.5rem',
|
marginLeft: '1rem',
|
||||||
marginTop: '0.125rem'
|
marginRight: '0.5rem',
|
||||||
}}>{promoPrice}</span>
|
marginTop: '0.125rem'
|
||||||
<span style={{
|
}}>{promoPrice}</span>
|
||||||
marginTop: '0.125rem',
|
<span style={{
|
||||||
color: 'rgb(114, 114, 114)',
|
marginTop: '0.125rem',
|
||||||
textDecoration: 'line-through'
|
color: 'rgb(114, 114, 114)',
|
||||||
}}>{initialPrice}</span>
|
textDecoration: 'line-through'
|
||||||
</div>
|
}}>{initialPrice}</span>
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
:
|
||||||
|
<>
|
||||||
|
|
||||||
|
<div style={{ display: 'flex' }}>
|
||||||
|
<span style={{
|
||||||
|
marginRight: '0.5rem',
|
||||||
|
marginTop: '0.125rem'
|
||||||
|
}}>{initialPrice}</span>
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
@@ -250,7 +263,7 @@ const Item = ({
|
|||||||
<div className={styles.itemQty}>
|
<div className={styles.itemQty}>
|
||||||
<button
|
<button
|
||||||
className={styles.addButton}
|
className={styles.addButton}
|
||||||
style={{ backgroundColor: !isAvailable ? "" : "inherit", border: `2px solid ${isAvailable ? 'inherit' : 'gray'}`, color: `${isAvailable ? '#73a585' : 'gray'}` }}
|
style={{ backgroundColor: !isAvailable ? "" : "inherit", border: `2px solid ${isAvailable ? 'inherit' : 'gray'}`, color: `${isAvailable ? '#a8c7a9' : 'gray'}` }}
|
||||||
onClick={handlePlusClick}
|
onClick={handlePlusClick}
|
||||||
disabled={!isAvailable} // Optionally disable the button if not available
|
disabled={!isAvailable} // Optionally disable the button if not available
|
||||||
>
|
>
|
||||||
@@ -264,7 +277,7 @@ const Item = ({
|
|||||||
style={{
|
style={{
|
||||||
backgroundColor: "white",
|
backgroundColor: "white",
|
||||||
width: "150px",
|
width: "150px",
|
||||||
color: '#73a585'
|
color: '#a8c7a9'
|
||||||
}}
|
}}
|
||||||
onClick={isBeingEdit ? handleUpdate : handleCreate}
|
onClick={isBeingEdit ? handleUpdate : handleCreate}
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -153,8 +153,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
margin-left: 5px;
|
margin-left: 5px;
|
||||||
color: rgb(115, 165, 133);
|
color: #a8c7a9;
|
||||||
fill: rgb(115, 165, 133);
|
fill: #a8c7a9;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -182,7 +182,7 @@
|
|||||||
|
|
||||||
.addButton {
|
.addButton {
|
||||||
background-color: #ffffff;
|
background-color: #ffffff;
|
||||||
border: 2px solid #73a585;
|
border: 2px solid #a8c7a9;
|
||||||
/* border: none; */
|
/* border: none; */
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
|
|||||||
Reference in New Issue
Block a user