PageLogos 페이지로고
페이지에 표시할 로고 또는 이미지 목록입니다.
Usage
PageLogos 구성 요소는 페이지에 로고 또는 이미지 목록을 표시할 수 있는 유연한 방법을 제공합니다.
<template>
<UPageLogos
:items="[
'i-simple-icons-github',
'i-simple-icons-discord',
'i-simple-icons-x',
'i-simple-icons-instagram',
'i-simple-icons-linkedin',
'i-simple-icons-facebook'
]"
/>
</template>제목
title Prop을 사용하여 로고 위에 제목을 설정합니다.
Trusted by the best front-end teams
<template>
<UPageLogos
title="Trusted by the best front-end teams"
:items="[
'i-simple-icons-github',
'i-simple-icons-discord',
'i-simple-icons-x',
'i-simple-icons-instagram',
'i-simple-icons-linkedin',
'i-simple-icons-facebook'
]"
/>
</template>Items 파일
로고는 다음 두 가지 방법으로 표시할 수 있습니다.
- x
itemsprop을 사용하여 로고 목록을 제공합니다. 각 항목은 다음 중 하나일 수 있습니다.
- An 아이콘 이름 (예:
i-simple-icons-github) - xx
UAvatar구성 요소에서 사용되는 이미지에 대한src및alt속성을 포함하는 개체
- 기본 슬롯을 사용하여 콘텐츠를 완전히 제어할 수 있습니다.
Trusted by the best front-end teams
<script setup lang="ts">
const items = [
'i-simple-icons-github',
'i-simple-icons-discord',
'i-simple-icons-x',
'i-simple-icons-instagram',
'i-simple-icons-linkedin',
'i-simple-icons-facebook'
]
</script>
<template>
<UPageLogos title="Trusted by the best front-end teams" :items="items" />
</template>
Trusted by the best front-end teams
<template>
<UPageLogos title="Trusted by the best front-end teams">
<UIcon name="i-simple-icons-github" class="size-10 shrink-0" />
<UIcon name="i-simple-icons-discord" class="size-10 shrink-0" />
<UIcon name="i-simple-icons-x" class="size-10 shrink-0" />
<UIcon name="i-simple-icons-instagram" class="size-10 shrink-0" />
<UIcon name="i-simple-icons-linkedin" class="size-10 shrink-0" />
<UIcon name="i-simple-icons-facebook" class="size-10 shrink-0" />
</UPageLogos>
</template>
Marquee
marquee 소품을 사용하여 로고에 선택 윤곽 효과를 활성화합니다.
Trusted by the best front-end teams
<template>
<UPageLogos
title="Trusted by the best front-end teams"
marquee
:items="[
'i-simple-icons-github',
'i-simple-icons-discord',
'i-simple-icons-x',
'i-simple-icons-instagram',
'i-simple-icons-linkedin',
'i-simple-icons-facebook'
]"
/>
</template>API
Props 코드
| Prop | Default | Type |
|---|---|---|
as | 'div' | anyThe element or component this component should render as. |
title | string | |
items | PageLogosItem[] | |
marquee | false | boolean | MarqueeProps |
ui | { root?: SlotClass; title?: SlotClass; logos?: SlotClass; logo?: SlotClass; } |
슬롯
| Slot | Type |
|---|---|
default | {} |
Theme 주제
app.config.ts
export default defineAppConfig({
ui: {
pageLogos: {
slots: {
root: 'relative overflow-hidden',
title: 'text-lg text-center font-semibold text-highlighted',
logos: 'mt-10',
logo: 'size-10 shrink-0'
},
variants: {
marquee: {
false: {
logos: 'flex items-center shrink-0 justify-around gap-(--gap) [--gap:--spacing(16)]'
}
}
}
}
}
})vite.config.ts
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import ui from '@nuxt/ui/vite'
export default defineConfig({
plugins: [
vue(),
ui({
ui: {
pageLogos: {
slots: {
root: 'relative overflow-hidden',
title: 'text-lg text-center font-semibold text-highlighted',
logos: 'mt-10',
logo: 'size-10 shrink-0'
},
variants: {
marquee: {
false: {
logos: 'flex items-center shrink-0 justify-around gap-(--gap) [--gap:--spacing(16)]'
}
}
}
}
}
})
]
})변경 로그
No recent changes