Skip to content

Commit

Permalink
up
Browse files Browse the repository at this point in the history
  • Loading branch information
Flosciante committed Sep 19, 2023
1 parent 4cadc32 commit 98f0238
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 27 deletions.
29 changes: 14 additions & 15 deletions components/ThemeCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,22 @@ const command = computed(() => {

<template>
<ULandingCard class="relative" :ui="{ body: { padding: '' } }" :description="theme.description">
<template #title>
<div class="relative mb-4">
<NuxtImg :src="theme.image" class="w-full rounded-xl object-cover h-[300px]" alt="" sizes="sm:300px lg:600px"
width="1112" height="617" format="webp" :loading="lazyImg ? 'loading' : undefined" />
<div class="h-[3px] w-full line flex justify-between -mb-[2px] z-10 relative">
<span class="h-[3px] w-full bg-gradient-to-l from-transparent to-slate-950/90" />
<span class="h-[3px] w-full bg-gradient-to-r from-transparent to-slate-950/90" />
</div>
<div v-if="theme.demo"
class='absolute inset-0 w-full h-full bg-gradient-to-b from-transparent to-gray-950/80 flex justify-center'>
<div class="absolute bottom-6 left-0 right-0 flex justify-center group">
<UButton label="preview" icon="i-ph-arrow-up-right-bold" :to="theme.demo" size="sm" target="_blank"
:trailing="true" color="blur" variant="outline" :ui="{ icon: { size: { sm: 'w-4 h-4' } } }" />
</div>
<div class="relative mb-4 order-first">
<NuxtImg :src="theme.image" class="w-full rounded-xl object-cover h-[300px]" alt="" sizes="sm:300px lg:600px"
width="1112" height="617" format="webp" :loading="lazyImg ? 'loading' : undefined" />
<div class="h-[3px] w-full line flex justify-between -mb-[2px] z-10 relative">
<span class="h-[3px] w-full bg-gradient-to-l from-transparent to-slate-950/90" />
<span class="h-[3px] w-full bg-gradient-to-r from-transparent to-slate-950/90" />
</div>
<div v-if="theme.demo"
class='absolute inset-0 w-full h-full bg-gradient-to-b from-transparent to-gray-950/80 flex justify-center'>
<div class="absolute bottom-6 left-0 right-0 flex justify-center group">
<UButton label="preview" icon="i-ph-arrow-up-right-bold" :to="theme.demo" size="sm" target="_blank"
:trailing="true" color="blur" variant="outline" :ui="{ icon: { size: { sm: 'w-4 h-4' } } }" />
</div>
</div>

</div>
<template #title>
<div v-if="!theme.shop" class="flex flex-col justify-between h-full">
<div class="flex flex-col items-center justify-center">
<div class="flex gap-x-2 items-center justify-center ">
Expand Down
24 changes: 12 additions & 12 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,16 +55,16 @@ export default defineNuxtConfig({
preference: 'dark',
},

hooks: {
// Related to https://github.com/nuxt/nuxt/pull/22558
// Adding all global components to the main entry
// To avoid lagging during page navigation on client-side
'components:extend': function (components) {
for (const comp of components) {
if (comp.global)
//@ts-ignore
comp.global = 'sync'
}
},
},
// hooks: {
// // Related to https://github.com/nuxt/nuxt/pull/22558
// // Adding all global components to the main entry
// // To avoid lagging during page navigation on client-side
// 'components:extend': function (components) {
// for (const comp of components) {
// if (comp.global)
// //@ts-ignore
// comp.global = 'sync'
// }
// },
// },
})

0 comments on commit 98f0238

Please sign in to comment.