Skip to content

Commit

Permalink
format files
Browse files Browse the repository at this point in the history
  • Loading branch information
midudev committed Jul 2, 2024
1 parent 9b42aae commit 7f2e810
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 14 deletions.
6 changes: 3 additions & 3 deletions src/components/BoxerDetailInfoRival.astro
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ const isVersus = value[0].versus.length === 2
: [
isVersus
? "grid grid-cols-2"
: "flex w-full flex-row flex-wrap justify-center gap-x-2 md:justify-center md:text-center",
: "flex w-full flex-row flex-wrap justify-center gap-x-2 md:justify-center md:text-center",
]}
>
{
value.map((item, index) => (
<a
class:list={[
`${isVersus ? "mx-2 p-1" : ""}`,
`${isVersus ? "mx-2 p-1" : ""}`,
`${isKingOfTheTrack ? "p-1" : "boxer-link z-20 text-xl font-bold text-accent"}`,
]}
href={`/boxers/${item.id}`}
Expand All @@ -46,7 +46,7 @@ const isVersus = value[0].versus.length === 2

<img
src={`https://cdn.lavelada.dev/boxers/${item.id}-small.webp`}
class:list={isKingOfTheTrack ? ["h-14 object-contain"] : ["boxer-image "]}
class:list={isKingOfTheTrack ? ["h-14 object-contain"] : ["boxer-image"]}
alt={`Foto en pequeño del rival ${item.name}`}
style="mask-image: linear-gradient(to bottom, black 50%, transparent 100%);"
/>
Expand Down
2 changes: 1 addition & 1 deletion src/components/Boxers/Gallery.astro
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const { id, name } = Astro.props
Array.from({ length: IMAGES_TO_LOAD }).map((_, index) => (
<a
class:list={[
" aspect-square transition hover:scale-105 hover:brightness-125",
"aspect-square transition hover:scale-105 hover:brightness-125",
{ "row-span-2": index === 0 },
]}
href={`https://cdn.lavelada.dev/boxers/gallery/${id}/${index + 1}.webp`}
Expand Down
2 changes: 1 addition & 1 deletion src/components/Date.astro
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const thirdDigitHeight = (1 / (maxThird + 1)) * 100
))
}
<div style={{ height: `${firstDigitHeight}%`, transition: "height 0.3s ease" }} data-num-x0>
<span class:list={`tabular-nums ${className}`}>0</span>
<span class:list={`tabular-nums ${className}`}>0</span>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/components/ForecastBoxer.astro
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const { image, imageAlt, boxerId, boxerName, boxerHref, isSmall = false } = Astr
<a
href={boxerHref}
class:list={[
"group relative transition-transform hover:scale-105 ",
"group relative transition-transform hover:scale-105",
isSmall ? "pb-[68px]" : "pb-[72px] md:pb-[96px]",
]}
aria-label={`Ir a la página de ${boxerName}`}
Expand Down
8 changes: 4 additions & 4 deletions src/pages/combates/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ export const prerender = true
<img
decoding="async"
loading={index < 2 ? "eager" : "lazy"}
class="group-hover:scale-115 absolute bottom-0 z-20 mx-auto h-auto w-full md:z-10"
class="group-hover:scale-115 absolute bottom-0 z-20 mx-auto h-auto w-full md:z-10"
src={`https://cdn.lavelada.dev/matches/combat-${combat.id}.webp`}
alt={`Fotografía del combate entre ${boxerNames.join(", ")}`}
style="mask-image: linear-gradient(black 90%, transparent 100%);"
Expand Down Expand Up @@ -132,7 +132,7 @@ export const prerender = true
class:list={[
"absolute bottom-0 left-0 h-full max-h-60 w-auto sm:max-h-80",
{ "group-hover:scale-115 z-20 md:z-10": isKingOfTheHill },
{ "z-10 group-hover:scale-105 ": !isKingOfTheHill },
{ "z-10 group-hover:scale-105": !isKingOfTheHill },
]}
src={image1.src}
alt={image1.alt}
Expand All @@ -145,7 +145,7 @@ export const prerender = true
class:list={[
"absolute bottom-0 right-0 h-full max-h-60 w-auto sm:max-h-80",
{ "group-hover:scale-115 z-20 md:z-10": isKingOfTheHill },
{ "z-10 group-hover:scale-105 ": !isKingOfTheHill },
{ "z-10 group-hover:scale-105": !isKingOfTheHill },
]}
src={image2.src}
alt={image2.alt}
Expand All @@ -158,7 +158,7 @@ export const prerender = true
transition:name={`title-image-${combatData.id}`}
loading={index < 2 ? "eager" : "lazy"}
class:list={[
"group-hover:saturate-15 absolute left-1/2 h-auto max-h-[15rem] w-auto -translate-x-1/2 transform-gpu transition-all duration-300 ease-in-out group-hover:scale-75",
"group-hover:saturate-15 absolute left-1/2 h-auto max-h-[15rem] w-auto -translate-x-1/2 transform-gpu transition-all duration-300 ease-in-out group-hover:scale-75",
{ "top-10 z-10 md:z-20": isKingOfTheHill },
{ "-bottom-20 z-20": !isKingOfTheHill },
]}
Expand Down
5 changes: 1 addition & 4 deletions src/sections/SelectYourBoxer.astro
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,7 @@ const boxerColumns = [
{
listOfBoxers.map((boxer, index) => (
<div
class:list={`
carousel-item w-[70%] flex-shrink-0 snap-center px-2
${index === 0 ? "ml-[65%]" : ""}
`}
class:list={`carousel-item w-[70%] flex-shrink-0 snap-center px-2 ${index === 0 ? "ml-[65%]" : ""} `}
>
<ColumnBoxers boxers={[boxer]} selectedBoxer={selectedBoxer} />
</div>
Expand Down

0 comments on commit 7f2e810

Please sign in to comment.