Skip to content

Commit 25bba74

Browse files
authored
fix(doc): active status of project cards (#502)
1 parent 8e4ec7b commit 25bba74

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

docs/pages/index.vue

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -130,34 +130,34 @@ watch(projectsSectionVisible, () => {
130130
class="group relative hidden cursor-pointer lg:block"
131131
:ui="{ background: 'bg-transparent dark:bg-transparent', sahdow: 'none', ring: 'ring-0', body: { background: 'bg-transparent dark:bg-transparent', base: 'flex flex-col space-y-2' } }"
132132
>
133-
<div class="absolute inset-0 h-full w-full" @click="selectProjectCard(index)" />
133+
<div class="absolute inset-0 h-full w-full" @click="selectProjectCard(idx)" />
134134
<h4
135135
class="text-xl font-medium transition-color duration-200 group-hover:text-white"
136-
:class="currentStep === index ? 'text-white ' : 'text-gray-400'"
136+
:class="currentStep === idx ? 'text-white ' : 'text-gray-400'"
137137
>
138138
{{ project.title }}
139139
</h4>
140140
<p
141141
class="transition-color duration-200 group-hover:text-gray-400"
142-
:class="currentStep === index ? 'text-gray-400' : 'text-gray-600'"
142+
:class="currentStep === idx ? 'text-gray-400' : 'text-gray-600'"
143143
>
144144
{{ project.description }}
145145
</p>
146146
<UButton
147147
trailing variant="link" color="white" size="md" :ui="{ size: { md: 'text-md' } }"
148148
class="z-20 -ml-2.5" :to="project.to"
149149
>
150-
<span class="transition-color duration-200 group-hover:text-white" :class="currentStep === index ? 'text-white' : 'text-gray-400'">Learn more</span>
150+
<span class="transition-color duration-200 group-hover:text-white" :class="currentStep === idx ? 'text-white' : 'text-gray-400'">Learn more</span>
151151
<UIcon
152152
name="i-ph-arrow-right" class="h-5 w-5 group-hover:text-white"
153-
:class="currentStep === index ? 'text-white' : 'text-gray-400'"
153+
:class="currentStep === idx ? 'text-white' : 'text-gray-400'"
154154
/>
155155
</UButton>
156156
</UCard>
157157

158158
<ULandingSection
159159
align="center"
160-
:icon="index === 0 ? 'i-ph-tree-structure' : index === 1 ? 'i-ph-circles-three' : 'i-ph-function'"
160+
:icon="idx === 0 ? 'i-ph-tree-structure' : idx === 1 ? 'i-ph-circles-three' : 'i-ph-function'"
161161
class="lg:hidden"
162162
:ui="{ base: 'flex flex-col items-center', wrapper: 'py-8 sm:py-12', icon: { wrapper: 'relative rounded-lg flex items-center justify-center mb-6 w-10 h-10 bg-gray-700 flex-shrink-0' }, title: 'text-2xl font-bold tracking-tight text-white sm:text-3xl lg:text-4xl' }"
163163
>
@@ -172,7 +172,7 @@ watch(projectsSectionVisible, () => {
172172
>
173173
<div class="p-4">
174174
<NuxtImg
175-
:src="`/images/${index === 0 ? 'pages' : index === 1 ? 'components' : 'imports'}.webp`"
175+
:src="`/images/${idx === 0 ? 'pages' : idx === 1 ? 'components' : 'imports'}.webp`"
176176
class="rounded-lg"
177177
/>
178178
</div>

0 commit comments

Comments
 (0)