Commit 725602b6 by sneha-khedekar

spacing alignment

1 parent 76a837b1
...@@ -103,14 +103,14 @@ const GuestReviews = ({ activityById }) => { ...@@ -103,14 +103,14 @@ const GuestReviews = ({ activityById }) => {
rating={data.attributes.rating} rating={data.attributes.rating}
starRatedColor="#FFD600" // Set the rated color to yellow starRatedColor="#FFD600" // Set the rated color to yellow
starHoverColor="#ffe20" // Set the hover color to yellow starHoverColor="#ffe20" // Set the hover color to yellow
changeRating={() => { }} changeRating={() => {}}
numberOfStars={5} numberOfStars={5}
name="rating" name="rating"
starDimension="20px" // Set star width and height starDimension="20px" // Set star width and height
/> />
<div className="review-content"> <div className="review-content">
"{data.attributes.comments.length > 180 ? `${data.attributes.comments.slice(0, 180)}...` : data.attributes.comments} "{data.attributes?.comments?.length > 180 ? `${data?.attributes?.comments.slice(0, 180)}...` : data?.attributes?.comments}"
{data.attributes.comments.length > 180 && ( {data?.attributes?.comments?.length > 180 && (
<a <a
onClick={() => { onClick={() => {
setreadMoreText(data); setreadMoreText(data);
...@@ -128,7 +128,9 @@ const GuestReviews = ({ activityById }) => { ...@@ -128,7 +128,9 @@ const GuestReviews = ({ activityById }) => {
); );
}) })
) : ( ) : (
<div className="d-flex justify-content-center"><strong>No reviews available</strong></div> <div className="d-flex justify-content-center">
<strong>No reviews available</strong>
</div>
)} )}
</Swiper> </Swiper>
</div> </div>
......
...@@ -50,7 +50,6 @@ const Header = () => { ...@@ -50,7 +50,6 @@ const Header = () => {
if (endUser) dispatch(getWishlists({ endUser: endUser.id })); if (endUser) dispatch(getWishlists({ endUser: endUser.id }));
}, [endUser]); }, [endUser]);
//// ////
// const [isGridViewOpen, setIsGridViewOpen] = useState(false); // const [isGridViewOpen, setIsGridViewOpen] = useState(false);
const innerBoxRef = useRef(null); // Ref to hold reference to inner-box div const innerBoxRef = useRef(null); // Ref to hold reference to inner-box div
...@@ -62,22 +61,17 @@ const Header = () => { ...@@ -62,22 +61,17 @@ const Header = () => {
}; };
// Function to handle click outside // Function to handle click outside
const handleClickOutside = (event) => { const handleClickOutside = event => {
if ( if (logoutBkRef.current && !logoutBkRef.current.contains(event.target) && innerBoxRef.current && !innerBoxRef.current.contains(event.target)) {
logoutBkRef.current &&
!logoutBkRef.current.contains(event.target) &&
innerBoxRef.current &&
!innerBoxRef.current.contains(event.target)
) {
setIsGridViewOpen(false); // Close if clicked outside setIsGridViewOpen(false); // Close if clicked outside
} }
}; };
// Effect to add click event listener when component mounts // Effect to add click event listener when component mounts
useEffect(() => { useEffect(() => {
document.addEventListener('mousedown', handleClickOutside); document.addEventListener("mousedown", handleClickOutside);
return () => { return () => {
document.removeEventListener('mousedown', handleClickOutside); document.removeEventListener("mousedown", handleClickOutside);
}; };
}, []); }, []);
...@@ -93,7 +87,7 @@ const Header = () => { ...@@ -93,7 +87,7 @@ const Header = () => {
</Navbar.Brand> </Navbar.Brand>
{loadedUser && loadedUser.id ? ( {loadedUser && loadedUser.id ? (
<div className="top-btn hide-on-desktop"> <div className="top-btn hide-on-desktop">
<div className="logout-bk" > <div className="logout-bk">
<a onClick={toggleGridViewDropdown} className="user-icon"> <a onClick={toggleGridViewDropdown} className="user-icon">
<span className="image-container user-pic"> <span className="image-container user-pic">
<Image layout="fill" priority alt="" className="image img-fluid" src="/images/icons/user.svg" /> <Image layout="fill" priority alt="" className="image img-fluid" src="/images/icons/user.svg" />
......
...@@ -18,35 +18,35 @@ const MyGiftCard = () => { ...@@ -18,35 +18,35 @@ const MyGiftCard = () => {
console.log("endUser", endUser); console.log("endUser", endUser);
console.log("giftCard", giftCard); console.log("giftCard", giftCard);
const getStatus = (status) => { const getStatus = status => {
let text; let text;
let color; let color;
switch (status) { switch (status) {
case 'new': case "new":
text = 'PENDING'; text = "PENDING";
color = 'warning'; color = "warning";
break; break;
case 'fulfilled': case "fulfilled":
text = 'APPROVED'; text = "APPROVED";
color = 'success'; color = "success";
break; break;
case 'rejected': case "rejected":
text = 'REJECTED'; text = "REJECTED";
color = 'error'; color = "error";
break; break;
default: default:
break; break;
} }
return <Tag color={color}>{text.toUpperCase()}</Tag>; return <Tag color={color}>{text.toUpperCase()}</Tag>;
} };
return ( return (
<Fragment> <Fragment>
<div className="container"> <div className="container min-height-40 ">
<div className="row"> <div className="row">
<div className="col-12 col-lg-12 form-container content-wraaper"> <div className="col-12 col-lg-12 form-container content-wraaper">
<h2 className="px-2 px-lg-0">My Gift Card</h2> <h2 className="px-2 px-lg-0">My Gift Card</h2>
<div className="row"> <div className="row">
{giftCard?.length > 0 ? {giftCard?.length > 0 ? (
<> <>
{giftCard.map((data, index) => ( {giftCard.map((data, index) => (
<div className="col-12 col-lg-4 col-md-6 px-4 px-lg-3" key={`1${index}`}> <div className="col-12 col-lg-4 col-md-6 px-4 px-lg-3" key={`1${index}`}>
...@@ -74,20 +74,18 @@ const MyGiftCard = () => { ...@@ -74,20 +74,18 @@ const MyGiftCard = () => {
<p className="m-0">${data.attributes.amount}</p> <p className="m-0">${data.attributes.amount}</p>
</div> </div>
{data.attributes.status !== null && {data.attributes.status !== null && <div>{getStatus(data?.attributes?.status)}</div>}
<div>
{getStatus(data?.attributes?.status)}
</div>
}
</div> </div>
</div> </div>
</div> </div>
</div> </div>
))}</> ))}
: </>
) : (
<> <>
<p className="mb-5">No Item Found</p> <p className="mb-5">No Item Found</p>
</>} </>
)}
</div> </div>
</div> </div>
</div> </div>
......
...@@ -352,11 +352,6 @@ ...@@ -352,11 +352,6 @@
resolved "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.2.5.tgz" resolved "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.2.5.tgz"
integrity sha512-0szyAo8jMCClkjNK0hknjhmAngUppoRekW6OAezbEYwHXN/VNtsXbfzgYOqjKWxEx3OoAzrT3jLwAF0HdX2MEw== integrity sha512-0szyAo8jMCClkjNK0hknjhmAngUppoRekW6OAezbEYwHXN/VNtsXbfzgYOqjKWxEx3OoAzrT3jLwAF0HdX2MEw==
"@next/swc-linux-x64-musl@12.2.5":
version "12.2.5"
resolved "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.2.5.tgz"
integrity sha512-zg/Y6oBar1yVnW6Il1I/08/2ukWtOG6s3acdJdEyIdsCzyQi4RLxbbhkD/EGQyhqBvd3QrC6ZXQEXighQUAZ0g==
"@nodelib/fs.scandir@2.1.5": "@nodelib/fs.scandir@2.1.5":
version "2.1.5" version "2.1.5"
resolved "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz" resolved "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz"
...@@ -2622,27 +2617,27 @@ glob-parent@~5.1.2: ...@@ -2622,27 +2617,27 @@ glob-parent@~5.1.2:
dependencies: dependencies:
is-glob "^4.0.1" is-glob "^4.0.1"
glob@^7.1.3, glob@^7.1.4, glob@^7.2.0: glob@^7.1.3, glob@^7.1.4, glob@7.1.7:
version "7.2.3" version "7.1.7"
resolved "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz" resolved "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz"
integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== integrity sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==
dependencies: dependencies:
fs.realpath "^1.0.0" fs.realpath "^1.0.0"
inflight "^1.0.4" inflight "^1.0.4"
inherits "2" inherits "2"
minimatch "^3.1.1" minimatch "^3.0.4"
once "^1.3.0" once "^1.3.0"
path-is-absolute "^1.0.0" path-is-absolute "^1.0.0"
glob@7.1.7: glob@^7.2.0:
version "7.1.7" version "7.2.3"
resolved "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz" resolved "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz"
integrity sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ== integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==
dependencies: dependencies:
fs.realpath "^1.0.0" fs.realpath "^1.0.0"
inflight "^1.0.4" inflight "^1.0.4"
inherits "2" inherits "2"
minimatch "^3.0.4" minimatch "^3.1.1"
once "^1.3.0" once "^1.3.0"
path-is-absolute "^1.0.0" path-is-absolute "^1.0.0"
...@@ -3696,21 +3691,16 @@ move-concurrently@^1.0.1: ...@@ -3696,21 +3691,16 @@ move-concurrently@^1.0.1:
rimraf "^2.5.4" rimraf "^2.5.4"
run-queue "^1.0.3" run-queue "^1.0.3"
ms@^2.1.1: ms@^2.1.1, ms@2.1.2:
version "2.1.3" version "2.1.2"
resolved "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz"
integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==
ms@2.0.0: ms@2.0.0:
version "2.0.0" version "2.0.0"
resolved "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz" resolved "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz"
integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==
ms@2.1.2:
version "2.1.2"
resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz"
integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==
nanoclone@^0.2.1: nanoclone@^0.2.1:
version "0.2.1" version "0.2.1"
resolved "https://registry.npmjs.org/nanoclone/-/nanoclone-0.2.1.tgz" resolved "https://registry.npmjs.org/nanoclone/-/nanoclone-0.2.1.tgz"
...@@ -4838,16 +4828,7 @@ react-easy-crop@^5.0.7: ...@@ -4838,16 +4828,7 @@ react-easy-crop@^5.0.7:
normalize-wheel "^1.0.1" normalize-wheel "^1.0.1"
tslib "^2.0.1" tslib "^2.0.1"
react-event-listener@^0.6.2: react-event-listener@^0.6.2, react-event-listener@^0.6.6:
version "0.6.6"
resolved "https://registry.npmjs.org/react-event-listener/-/react-event-listener-0.6.6.tgz"
integrity sha512-+hCNqfy7o9wvO6UgjqFmBzARJS7qrNoda0VqzvOuioEpoEXKutiKuv92dSz6kP7rYLmyHPyYNLesi5t/aH1gfw==
dependencies:
"@babel/runtime" "^7.2.0"
prop-types "^15.6.0"
warning "^4.0.1"
react-event-listener@^0.6.6:
version "0.6.6" version "0.6.6"
resolved "https://registry.npmjs.org/react-event-listener/-/react-event-listener-0.6.6.tgz" resolved "https://registry.npmjs.org/react-event-listener/-/react-event-listener-0.6.6.tgz"
integrity sha512-+hCNqfy7o9wvO6UgjqFmBzARJS7qrNoda0VqzvOuioEpoEXKutiKuv92dSz6kP7rYLmyHPyYNLesi5t/aH1gfw== integrity sha512-+hCNqfy7o9wvO6UgjqFmBzARJS7qrNoda0VqzvOuioEpoEXKutiKuv92dSz6kP7rYLmyHPyYNLesi5t/aH1gfw==
...@@ -5157,7 +5138,7 @@ react-transition-group@^2.5.3: ...@@ -5157,7 +5138,7 @@ react-transition-group@^2.5.3:
prop-types "^15.6.2" prop-types "^15.6.2"
react-lifecycles-compat "^3.0.4" react-lifecycles-compat "^3.0.4"
react-transition-group@^4, react-transition-group@4.3.0: react-transition-group@^4, react-transition-group@^4.3.0, react-transition-group@4.3.0:
version "4.3.0" version "4.3.0"
resolved "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.3.0.tgz" resolved "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.3.0.tgz"
integrity sha512-1qRV1ZuVSdxPlPf4O8t7inxUGpdyO5zG9IoNfJxSO0ImU2A1YWkEQvFPuIPZmMLkg5hYs7vv5mMOyfgSkvAwvw== integrity sha512-1qRV1ZuVSdxPlPf4O8t7inxUGpdyO5zG9IoNfJxSO0ImU2A1YWkEQvFPuIPZmMLkg5hYs7vv5mMOyfgSkvAwvw==
...@@ -5167,7 +5148,7 @@ react-transition-group@^4, react-transition-group@4.3.0: ...@@ -5167,7 +5148,7 @@ react-transition-group@^4, react-transition-group@4.3.0:
loose-envify "^1.4.0" loose-envify "^1.4.0"
prop-types "^15.6.2" prop-types "^15.6.2"
react-transition-group@^4.3.0, react-transition-group@^4.4.2: react-transition-group@^4.4.2:
version "4.4.5" version "4.4.5"
resolved "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz" resolved "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz"
integrity sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g== integrity sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==
...@@ -5669,17 +5650,22 @@ source-map-url@^0.4.0: ...@@ -5669,17 +5650,22 @@ source-map-url@^0.4.0:
resolved "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.1.tgz" resolved "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.1.tgz"
integrity sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw== integrity sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw==
source-map@^0.5.6: source-map@^0.5.6, source-map@^0.5.7:
version "0.5.7" version "0.5.7"
resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz"
integrity sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ== integrity sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ==
source-map@^0.5.7: source-map@^0.6.0:
version "0.5.7" version "0.6.1"
resolved "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz" resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz"
integrity sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ== integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
source-map@^0.6.1:
version "0.6.1"
resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz"
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: source-map@~0.6.1:
version "0.6.1" version "0.6.1"
resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz" resolved "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz"
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!