From 378b97d2990977dc25116884d1c8d540bfa3a40b Mon Sep 17 00:00:00 2001 From: stitch Date: Fri, 8 Nov 2024 02:15:57 +0200 Subject: [PATCH] product page and product card changes --- public/assets/css/product.css | 383 ++++++++++++++++++++++++++++++ public/assets/css/productCard.css | 15 ++ public/assets/css/profileBox.css | 141 +++++++++++ public/assets/css/store.css | 69 ------ public/assets/css/styles.css | 25 +- public/assets/css/tabs.css | 73 ++++++ public/assets/css/wot.css | 73 ++++++ public/assets/js/tabs.js | 25 ++ public/index.html | 29 ++- public/productPage.html | 313 +++++++++++++++++++++++- public/products.html | 19 +- public/storePage.html | 31 ++- public/stores.html | 15 +- 13 files changed, 1095 insertions(+), 116 deletions(-) create mode 100644 public/assets/css/product.css create mode 100644 public/assets/css/profileBox.css create mode 100644 public/assets/css/tabs.css create mode 100644 public/assets/css/wot.css create mode 100644 public/assets/js/tabs.js diff --git a/public/assets/css/product.css b/public/assets/css/product.css new file mode 100644 index 0000000..9836f4c --- /dev/null +++ b/public/assets/css/product.css @@ -0,0 +1,383 @@ +.productMainWrapper { + width: 100%; + display: flex; + flex-direction: column; + grid-gap: 15px; +} + +.productMain { + width: 100%; + display: flex; + flex-direction: row; + grid-gap: 35px; +} + +@media (max-width: 992px) { + .productMain { + flex-wrap: wrap; + } +} + +.productMainSec { + flex-grow: 1; + display: flex; + flex-direction: column; + grid-gap: 15px; +} + +.productMainSec.productMainSecSide { + min-width: 400px; + max-width: 400px; +} + +@media (max-width: 992px) { + .productMainSec.productMainSecSide { + min-width: unset; + max-width: unset; + } +} + +.productMainSec.productMainSecBod { + display: flex; + flex-direction: column; + grid-gap: 25px; + min-width: 0%; +} + +.productMainSecBodGallery { + width: 100%; + display: flex; + flex-direction: column; + grid-gap: 15px; +} + +.productMainSecSideSec { + display: flex; + flex-direction: column; + grid-gap: 10px; +} + +.productMainSecSideSec.productMainSecSideSecAlt { + padding: 15px; + background: white; + border-radius: 8px; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); +} + +.productMainSecBodGalleryTop { +} + +.productMainSecBodGalleryBot { + padding: 10px; + border-radius: 8px; + background: white; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); + display: flex; + flex-direction: column; +} + +.productMainSecBodGalleryBotList { + width: 100%; + display: flex; + flex-direction: row; + grid-gap: 10px; + padding: 10px; + background: rgba(0,0,0,0.15); + border-radius: 4px; + overflow-y: hidden; + overflow-x: auto; + justify-content: start; + box-shadow: inset 0 0 8px 0 rgb(0,0,0,0.1); +} + +.productMainSecBodGalleryBotListPicWrapper { + min-width: 200px; + max-width: 200px; +} + +.productMainSecBodGalleryBotListPic { + transition: ease 0.3s; + padding-top: 56.25%; + background: rgba(0,0,0,0.1); + overflow: hidden; + border-radius: 6px; + position: relative; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); + outline: solid 3px rgba(255,153,0,0); + cursor: pointer; +} + +.productMainSecBodGalleryBotListPic:hover { + outline: solid 3px rgba(255,153,0,0.85); +} + +.productMainSecBodGalleryBotListPicImg { + position: absolute; + top: 0; + bottom: 0; + right: 0; + left: 0; + width: 100%; + height: 100%; + object-fit: cover; +} + +.productMainSecBodExtra { + display: flex; + flex-direction: column; + grid-gap: 10px; +} + +.productMainSecBodGalleryTopPic { + width: 100%; + padding-top: 56.25%; + background: rgba(0,0,0,0.1); + border-radius: 8px; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + position: relative; + overflow: hidden; +} + +.productMainSecBodGalleryTopPicImg { + position: absolute; + top: 0; + bottom: 0; + right: 0; + left: 0; + width: 100%; + height: 100%; + object-fit: cover; +} + +.productMainSecBodGalleryBotListPic.productMainSecBodGalleryBotListPicActive { + outline: solid 2px rgb(255,153,0); +} + +.productMainWrapperTop { + width: 100%; + display: flex; + flex-direction: row; + grid-gap: 10px; +} + +.productMainWrapperTopSec { + display: flex; + flex-direction: row; + grid-gap: 5px; +} + +.productMainWrapperTopSec.productMainWrapperTopSecInfo { + flex-direction: column; +} + +.productMainWrapperTopSecInfoTitle { + font-weight: 600; +} + +.productMainSecBodExtraInside { + width: 100%; + display: flex; + flex-direction: column; + grid-gap: 10px; +} + +.productMainSecBodExtraInsideDetails { + display: flex; + flex-direction: column; +} + +.productMainSecBodExtraInsideActions { + display: flex; + flex-direction: row; + justify-content: center; + align-items: center; +} + +.btnMain.productMainSecBodExtraInsideActionsBtn { + width: 100%; + padding: 5px 15px; + font-size: 16px; + background: rgba(0,0,0,0.05); + color: rgba(0,0,0,0.35); +} + +.productMainSecSideSecText { +} + +.btnMain.productMainSecSideSecBtn { + width: 100%; + padding: 5px 15px; + font-size: 16px; + background: rgba(0,0,0,0.05); + color: rgba(0,0,0,0.35); +} + +.productMainSecSideSecActions { + display: flex; + flex-direction: row; + grid-gap: 10px; +} + +@media (max-width: 576px) { + .productMainSecSideSecActions { + flex-direction: column; + } +} + +.btnMain.productMainSecSideSecActionsBtn { + padding: 10px 20px; + font-size: 16px; + background: rgba(0,0,0,0); + color: rgba(0,0,0,0.35); + border: solid 1px rgba(0,0,0,0.1); +} + +.btnMain.productMainSecSideSecActionsBtn:hover { + background: rgba(255,153,0,0.85); + border: solid 1px rgba(0,0,0,0); +} + +.btnMain.productMainSecSideSecActionsBtn.productMainSecSideSecActionsBtnBuy { + width: 100%; + background: rgb(255,153,0); + color: white; + border: solid 1px rgba(0,0,0,0); + padding: 5px 5px; + flex-wrap: wrap; +} + +.btnMain.productMainSecSideSecActionsBtn.productMainSecSideSecActionsBtnBuy:hover { + background: rgba(255,153,0,0.85); + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); +} + +.productMainSecSideSecPrice { + width: 100%; + display: flex; + flex-direction: row; + grid-gap: 10px; + align-items: center; + flex-wrap: wrap; +} + +@media (max-width: 576px) { + .productMainSecSideSecPrice { + flex-direction: column; + } +} + +.productMainSecSideSecPriceBox { + display: flex; + flex-direction: row; + grid-gap: 0px; + border-radius: 6px; + border: solid 1px rgba(0,0,0,0.1); + overflow: hidden; + font-size: 18px; + flex-grow: 1; +} + +@media (max-width: 576px) { + .productMainSecSideSecPriceBox { + width: 100%; + } +} + +.productMainSecSideSecPriceBoxCurrency { + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + padding: 5px 15px; + border-right: solid 1px rgba(0,0,0,0.1); + background: rgba(255,153,0,0.85); + color: white; + font-weight: 600; +} + +.productMainSecSideSecPriceBoxPrice { + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + padding: 5px 15px; + font-weight: 600; + white-space: nowrap; +} + +.productMainSecSideSecPriceText { +} + +.productMainSecSideSecPriceBoxPriceText { + width: 100%; +} + +.productMainSecSideSecPriceOther { + font-size: 14px; + color: rgba(0,0,0,0.5); + font-weight: 600; + display: flex; + flex-direction: row; + grid-gap: 5px; + flex-wrap: wrap; +} + +.productMainSecSideSecActionsBtnBuySpan { + text-align: center; + flex-grow: 1; +} + +.productMainSecSideSecActionsBtnBuySpan.productMainSecSideSecActionsBtnBuySpanAlt { + font-size: 14px; + padding: 5px 15px; + border-radius: 4px; + background: rgba(0,0,0,0.05); + border: solid 1px rgba(255,255,255,0.15); + flex-grow: unset; +} + +.productMainSecSideSecTitle { + font-weight: 600; + color: rgba(0,0,0,0.5); + font-size: 21px; +} + +.productMainSecBodExtraTagsWrapper { + display: flex; + flex-direction: column; + grid-gap: 10px; +} + +.productMainSecBodExtraTags { + padding: 15px; + border-radius: 8px; + background: white; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); + display: flex; + flex-direction: row; + grid-gap: 10px; + flex-wrap: wrap; +} + +.productMainSecBodExtraTagsTag { + transition: ease 0.3s; + padding: 5px 15px; + border-radius: 8px; + border: solid 1px rgba(0,0,0,0.1); + font-weight: 400; + color: rgba(0,0,0,0.5); + background: white; +} + +.productMainSecBodExtraTagsTag:hover { + color: rgb(255,255,255); + background: #ffa826; +} + diff --git a/public/assets/css/productCard.css b/public/assets/css/productCard.css index 5c40e3c..4bff2aa 100644 --- a/public/assets/css/productCard.css +++ b/public/assets/css/productCard.css @@ -57,6 +57,7 @@ flex-grow: 1; padding: 8px; font-weight: 700; + flex-wrap: wrap; } .btnMain.productCardMainInsideBotBtn:hover { @@ -202,3 +203,17 @@ background: rgba(255,255,255,0.1); } +.productCardMainInsideBotBtnSpan { + text-align: center; + flex-grow: 1; +} + +.productCardMainInsideBotBtnSpan.productCardMainInsideBotBtnSpanAlt { + font-size: 14px; + padding: 5px 15px; + border-radius: 4px; + background: rgba(0,0,0,0.05); + border: solid 1px rgba(255,255,255,0.15); + flex-grow: unset; +} + diff --git a/public/assets/css/profileBox.css b/public/assets/css/profileBox.css new file mode 100644 index 0000000..37fda6f --- /dev/null +++ b/public/assets/css/profileBox.css @@ -0,0 +1,141 @@ +.userProfileBoxMain { + width: 100%; + display: flex; + flex-direction: column; + grid-gap: 10px; +} + +.userProfileBoxMainTop { + display: flex; + flex-direction: row; + grid-gap: 15px; + width: 100%; + max-width: 90%; + background: rgba(255,255,255,0.85); + backdrop-filter: blur(10px); + padding: 10px; + margin-top: -30px; + z-index: 1; + border-radius: 8px; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.15); + border: solid 1px rgba(0,0,0,0.1); + align-self: center; +} + +.userProfileBoxMainTopPic { + transition: ease 0.3s; + min-height: 75px; + min-width: 75px; + max-height: 75px; + max-width: 75px; + background: rgba(0,0,0,0.1); + border-radius: 100%; + border: solid 4px white; + box-shadow: 0 0 6px 0 rgb(0,0,0,0.25); + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + overflow: hidden; + position: relative; +} + +.userProfileBoxMainTopPic:hover { + border: solid 4px #ff9900; + transform: scale(1.02); +} + +.userProfileBoxMainTopPicImg { + position: absolute; + top: 0; + bottom: 0; + left: 0; + right: 0; + object-fit: cover; + width: 100%; + height: 100%; +} + +.userProfileBoxMainTopDetails { + flex-grow: 1; + display: flex; + flex-direction: column; + grid-gap: 5px; +} + +.userProfileBoxMainTopDetailsName { + font-weight: 600; + font-size: 16px; +} + +.userProfileBoxMainTopDetailsBio { + font-size: 14px; + display: -webkit-box; + -webkit-box-orient: vertical; + overflow: hidden; + -webkit-line-clamp: 2; +} + +.userProfileBoxMainMid { + display: flex; + flex-direction: column; + grid-gap: 5px; +} + +.userProfileBoxMainBottom { + display: flex; + flex-direction: row; + grid-gap: 10px; +} + +.btnMain.userProfileBoxMainBottomBtn { + width: 100%; + background: rgba(0,0,0,0.1); + color: rgba(0,0,0,0.5); + border: solid 1px rgba(0,0,0,0.1); + padding: 8px; + font-size: 16px; +} + +.btnMain.userProfileBoxMainBottomBtn:hover { + width: 100%; + background: rgba(255,153,0,0.85); + border: solid 1px rgba(0,0,0,0); + transform: scale(1.02); +} + +.btnMain.userProfileBoxMainBottomBtn.userProfileBoxMainBottomBtnActive { + background: rgba(255,153,0,0.85); + color: white; +} + +.userProfileBoxMainBanner { + width: 100%; + border-radius: 8px; + padding-top: 25%; + background: rgba(0,0,0,0.1); + position: relative; + overflow: hidden; + display: flex; + flex-direction: column; + box-shadow: 0 0 6px 0 rgb(0,0,0,0.2); +} + +.userProfileBoxMainBannerImg { + width: 100%; + height: 100%; + position: absolute; + top: 0; + bottom: 0; + left: 0; + right: 0; + object-fit: cover; +} + +.storeProfileBoxMain { +} + +.userProfileBoxMainTopPic.userProfileBoxMainTopPicAlt { + border-radius: 8px; +} + diff --git a/public/assets/css/store.css b/public/assets/css/store.css index da58f54..5e60b02 100644 --- a/public/assets/css/store.css +++ b/public/assets/css/store.css @@ -127,78 +127,9 @@ border-radius: 4px; } -.storeMainMidInsideSecWoT { - display: flex; - flex-direction: row; - grid-gap: 10px; -} - -@media (max-width: 576px) { - .storeMainMidInsideSecWoT { - flex-direction: column; - } -} - .storeMainMidInsideSecAction { } -.storeMainMidInsideSecWoTSec { - display: flex; - flex-direction: column; - grid-gap: 5px; - width: 100%; -} - -.storeMainMidInsideSecWoTSecPeople { - display: flex; - flex-direction: row; - grid-gap: 5px; -} - -.storeMainMidInsideSecWoTSecPeoplePerson { - transition: ease 0.3s; - min-width: 40px; - max-width: 40px; - min-height: 40px; - min-width: 40px; - background: rgba(255,255,255,0.75); - backdrop-filter: blur(5px); - border-radius: 100%; - border: solid 3px white; - box-shadow: 0 0 4px 0 rgb(0,0,0,0.5); - display: flex; - flex-direction: column; - justify-content: center; - align-items: center; - position: relative; - overflow: hidden; - margin-left: -20px; - color: rgba(0,0,0,0.5); - font-weight: 700; - font-size: 14px; -} - -.storeMainMidInsideSecWoTSecPeoplePerson:first-child { - margin: 0; -} - -.storeMainMidInsideSecWoTSecPeoplePerson:hover { - margin: 0 20px 0 0; - transform: translateY(-5px); - border: solid 3px rgb(255,153,0); - box-shadow: 0 0 0px 0 rgb(0,0,0,0.5); -} - -.storeMainMidInsideSecWoTSecPeoplePersonImg { - position: absolute; - top: 0; - bottom: 0; - left: 0; - right: 0; - width: 100%; - height: 100%; -} - .storeMainMidInsideSecUser { width: 100%; display: flex; diff --git a/public/assets/css/styles.css b/public/assets/css/styles.css index 901a4c8..5c48c17 100644 --- a/public/assets/css/styles.css +++ b/public/assets/css/styles.css @@ -97,6 +97,7 @@ h1, h2, h3, h4, h5, h6 { } a { + transition: ease 0.2s; display: block; transition: ease 0.2s; color: unset; @@ -105,7 +106,6 @@ a { } a:hover { - transition: ease 0.2s; color: unset; text-decoration: unset; color: #FF9900; @@ -113,7 +113,7 @@ a:hover { .btnMain { transition: ease 0.4s; - background: rgba(255,153,0,0.85); + background: rgb(255,153,0); border: unset; outline: unset; color: rgba(255,255,255,0.85); @@ -131,7 +131,7 @@ a:hover { } .btnMain:hover { - background: #ff9900; + background: rgba(255,153,0,0.85); color: rgb(255,255,255); } @@ -446,3 +446,22 @@ a:hover { } } +.linkMain { +} + +.secMainInsideExtraSec { + display: flex; + flex-direction: column; + grid-gap: 15px; +} + +.secMainInsideExtraSecTop { + display: flex; + flex-direction: column; + grid-gap: 5px; +} + +.secMainInsideExtraSecTopTitle { + font-weight: 600; +} + diff --git a/public/assets/css/tabs.css b/public/assets/css/tabs.css new file mode 100644 index 0000000..dbe6bde --- /dev/null +++ b/public/assets/css/tabs.css @@ -0,0 +1,73 @@ +.tabsMain { + width: 100%; + display: flex; + flex-direction: column; + grid-gap: 15px; +} + +.tabsMainTop { + display: flex; + flex-direction: row; + grid-gap: 10px; + flex-wrap: wrap; +} + +.tabsMainMid { + width: 100%; + display: flex; + flex-direction: column; + /*padding: 10px 0 0 0;*/ + /*border-top: solid 1px rgba(0,0,0,0.1);*/ + /*margin-top: 10px;*/ +} + +.tabsMainTopElement { + transition: ease 0.3s; + display: flex; + flex-direction: row; + grid-gap: 5px; + justify-content: center; + align-items: center; + text-align: center; + padding: 10px 20px; + border-radius: 6px; + background: rgba(255,255,255,0); + color: rgba(0,0,0,0.5); + font-weight: 600; + cursor: pointer; + border: solid 1px rgba(0,0,0,0.1); + flex-grow: 1; +} + +.tabsMainTopElement:hover { + background: rgb(255,255,255); + color: rgba(0,0,0,0.65); + border: solid 1px rgba(0,0,0,0); + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); +} + +.tabsMainTopElementText { +} + +.tabsMainTopElement.tabsMainTopElementActive { + color: rgba(0,0,0,0.75); + background: white; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); + border: solid 1px rgba(0,0,0,0); +} + +.tabsMainMidElement { + width: 100%; + display: none; +} + +.tabsMainMidElement.tabsMainMidElementActive { + display: flex; + flex-direction: column; + grid-gap: 0px; + background: white; + border-radius: 8px; + padding: 15px; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.1); +} + diff --git a/public/assets/css/wot.css b/public/assets/css/wot.css new file mode 100644 index 0000000..de06399 --- /dev/null +++ b/public/assets/css/wot.css @@ -0,0 +1,73 @@ +.wotMain { + display: flex; + flex-direction: row; + grid-gap: 10px; +} + +@media (max-width: 576px) { + .wotMain { + flex-direction: column; + } +} + +.wotMain.wotMainAlt { + flex-direction: column; +} + +.wotMainSec { + display: flex; + flex-direction: column; + grid-gap: 5px; + width: 100%; +} + +.wotMainSecPeople { + display: flex; + flex-direction: row; + grid-gap: 5px; +} + +.wotMainSecPeoplePerson { + transition: ease 0.3s; + min-width: 40px; + max-width: 40px; + min-height: 40px; + min-width: 40px; + background: rgba(255,255,255,0.75); + backdrop-filter: blur(5px); + border-radius: 100%; + border: solid 3px white; + box-shadow: 0 0 4px 0 rgb(0,0,0,0.5); + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + position: relative; + overflow: hidden; + margin-left: -20px; + color: rgba(0,0,0,0.5); + font-weight: 700; + font-size: 14px; +} + +.wotMainSecPeoplePerson:first-child { + margin: 0; +} + +.wotMainSecPeoplePerson:hover { + margin: 0 20px 0 0; + transform: translateY(-5px); + border: solid 3px rgb(255,153,0); + box-shadow: 0 0 0px 0 rgb(0,0,0,0.5); +} + +.wotMainSecPeoplePersonImg { + position: absolute; + top: 0; + bottom: 0; + left: 0; + right: 0; + width: 100%; + height: 100%; +} + diff --git a/public/assets/js/tabs.js b/public/assets/js/tabs.js new file mode 100644 index 0000000..1c391ec --- /dev/null +++ b/public/assets/js/tabs.js @@ -0,0 +1,25 @@ +document.querySelectorAll('.tabsMain').forEach(tabsMain => { + const tabsTopElements = tabsMain.querySelectorAll('.tabsMainTopElement'); + const tabsMidElements = tabsMain.querySelectorAll('.tabsMainMidElement'); + + tabsTopElements.forEach((tab, index) => { + tab.addEventListener('click', () => { + // Remove active class from all tabs and content + tabsTopElements.forEach(t => t.classList.remove('tabsMainTopElementActive')); + tabsMidElements.forEach(m => m.classList.remove('tabsMainMidElementActive')); + + // Add active class to the clicked tab and corresponding content + tab.classList.add('tabsMainTopElementActive'); + tabsMidElements[index].classList.add('tabsMainMidElementActive'); + + // Set active class on the parent tabsMain + tabsMain.classList.add('tabsMainActive'); + // Remove active class from all other tabsMain + document.querySelectorAll('.tabsMain').forEach(otherTabsMain => { + if (otherTabsMain !== tabsMain) { + otherTabsMain.classList.remove('tabsMainActive'); + } + }); + }); + }); +}); diff --git a/public/index.html b/public/index.html index a1cdf91..ae10045 100644 --- a/public/index.html +++ b/public/index.html @@ -13,12 +13,16 @@ + + + + - + @@ -27,13 +31,13 @@