fix: tab hover affects active indicator
CD — Kai-Sa-Cam Deployment / deploy (push) Successful in 10s
CD — Kai-Sa-Cam Deployment / deploy (push) Successful in 10s
This commit is contained in:
+4
-8
@@ -140,17 +140,15 @@ export function App() {
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="mx-auto mt-[1vh] sm:mt-[1.5vh] w-[min(95vw,380px)] shrink-0">
|
<div className="mx-auto mt-[1vh] sm:mt-[1.5vh] w-[min(95vw,380px)] shrink-0">
|
||||||
<nav className="group relative flex trans-bloc rounded-full p-[1px] overflow-hidden">
|
<nav className="group relative flex trans-bloc rounded-full overflow-hidden">
|
||||||
<div
|
<div
|
||||||
className={`absolute inset-y-[1px] left-[1px] w-[calc(50%-1px)] rounded-full glass-button transition-transform duration-300 ease-in-out ${
|
className={`absolute inset-y-0 left-0 w-1/2 rounded-full glass-button transition-transform duration-300 ease-in-out group-hover:opacity-90 ${
|
||||||
activeTab === "media" ? "translate-x-full" : "translate-x-0"
|
activeTab === "media" ? "translate-x-full" : "translate-x-0"
|
||||||
}`}
|
}`}
|
||||||
/>
|
/>
|
||||||
<button
|
<button
|
||||||
className={`relative z-10 flex-1 py-2 sm:py-2.5 md:py-3 text-center text-sm sm:text-base md:text-lg transition-all duration-300 active:scale-95 ${
|
className={`relative z-10 flex-1 py-2 sm:py-2.5 md:py-3 text-center text-sm sm:text-base md:text-lg transition-all duration-300 active:scale-95 ${
|
||||||
activeTab === "live"
|
activeTab === "live" ? "font-medium" : ""
|
||||||
? "font-medium"
|
|
||||||
: "group-hover:bg-white/10"
|
|
||||||
}`}
|
}`}
|
||||||
onClick={() => setActiveTab("live")}
|
onClick={() => setActiveTab("live")}
|
||||||
>
|
>
|
||||||
@@ -158,9 +156,7 @@ export function App() {
|
|||||||
</button>
|
</button>
|
||||||
<button
|
<button
|
||||||
className={`relative z-10 flex-1 py-2 sm:py-2.5 md:py-3 text-center text-sm sm:text-base md:text-lg transition-all duration-300 active:scale-95 ${
|
className={`relative z-10 flex-1 py-2 sm:py-2.5 md:py-3 text-center text-sm sm:text-base md:text-lg transition-all duration-300 active:scale-95 ${
|
||||||
activeTab === "media"
|
activeTab === "media" ? "font-medium" : ""
|
||||||
? "font-medium"
|
|
||||||
: "group-hover:bg-white/10"
|
|
||||||
}`}
|
}`}
|
||||||
onClick={() => setActiveTab("media")}
|
onClick={() => setActiveTab("media")}
|
||||||
>
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user