Skip to content

Commit

Permalink
Merge pull request #18 from muhammadshakkeerp/feature/style
Browse files Browse the repository at this point in the history
Feature/style
  • Loading branch information
muhammadshakkeerp authored Sep 10, 2024
2 parents fadc9fb + 29d5fcc commit a0ea1c8
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const App: FC<ProductProps> = () => {
}

return (
<div className={`${DarkMode?.isEnabled ? "dark:bg-darkModeBg text-darkModeText" : "bg-white"} relative`}>
<div className={`${DarkMode?.isEnabled ? "dark:bg-darkModeBg text-darkModeText" : "bg-gradient-primary from-primary-start to-parimary-end"} relative`}>
{showPopUp && <PopupCard setShowPopUp={setShowPopUp} />}
<Header toggleDarkMode={() => { }} />
<Suspense fallback={<div className="text-center mt-10">Loading...</div>} >
Expand Down
2 changes: 1 addition & 1 deletion src/components/CustomProductsRows.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ const CustomProductsRows: FC<RowProps> = ({ title, endProducts, starProducts })
// e.preventDefault(); // Prevent the default window scroll behavior when using touch events (optional)
};
return (
<div className={`relative ${darkMode?.isEnabled ? "bg-darkModeBg text-darkModeText" : "bg-white"} m-2 `} onWheel={handleScroll} >
<div className={`relative ${darkMode?.isEnabled ? "bg-darkModeBg text-darkModeText" : ""} m-2 `} onWheel={handleScroll} >
<Link to="/ProductGallery" >
<button type="button" title="Display More products" onClick={() => setRefreshSite(true)}>
{
Expand Down
2 changes: 1 addition & 1 deletion src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const Header: FC<HeaderProps> = () => {
dispatch(toggleDarkMode())
}
return (
<header className={`h-[50px] ${darkMode?.isEnabled ? " bg-darkModeBg text-darkModeText" : "bg-white"} md:h-[66px] flex items-center justify-around md:flex-row md:justify-between relative`}>
<header className={`h-[50px] ${darkMode?.isEnabled ? " bg-darkModeBg text-darkModeText" : "bg-secondaryColor"} md:h-[66px] flex items-center justify-around md:flex-row md:justify-between relative`}>
{/* Logo */}
<div className="flex items-center gap-4 md:gap-0 ">
<button type="button" title="Click to toggle" onClick={() => setToggleMenu(!toggleMenu)}>
Expand Down
2 changes: 1 addition & 1 deletion src/components/HeaderCategory.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const HeaderCategory: FC<headerCategoriesProps> = () => {
}, [])

return (
<div className={`flex gap-1 flex-shrink-0 justify-between ${DarkMode?.isEnabled ? "bg-slate-800 text-white" : "bg-[#e4adff] md:bg-white"} md:gap-3 header-category-img-p relative`}>
<div className={`flex gap-1 flex-shrink-0 justify-between ${DarkMode?.isEnabled ? "bg-slate-800 text-white" : ""} md:gap-3 header-category-img-p relative`}>
{headerCategories?.map((category, index) => (
<Link to="/productsGroup" key={index}>
<div
Expand Down
13 changes: 12 additions & 1 deletion tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ export default {
robo:['Roboto','sans-serif']
},
backgroundColor:{
primaryColor: "#e2dfd2",
secondaryColor:"#c7b6a3",
lightGray:"#D1D5DB",
darkModeBg:"#1f2937"
},
Expand All @@ -21,7 +23,16 @@ export default {
lightGray:"#D1D5DB",
primary:"#2874f0"
},

backgroundImage: {
'gradient-primary': 'linear-gradient(to right, var(--tw-gradient-stops))',
'gradient-secondary': 'linear-gradient(to bottom, var(--tw-gradient-stops))',
},
gradientColorStops: theme => ({
'primary-start': theme('colors.primaryColor'),
'primary-end': theme('colors.secondaryColor'),
'dark-start': theme('colors.darkModeBg'),
'dark-end': theme('colors.dark'),
}),

},
},
Expand Down

0 comments on commit a0ea1c8

Please sign in to comment.