docs/.vitepress/theme/components/SidebarCard.vue

0c93197cf2432b4c885ec57d88ab242f78527eb7
wotaku/docs/.vitepress/theme/components/SidebarCard.vue
taskylizard wotaku 2bea9706e6c 1 year ago

43 lines · 1519 bytes

 1<!--
 2  All Rights Reserved
 3
 4  Copyright (c) 2025 taskylizard
 5
 6  All rights reserved. This code and its associated files may not be copied, modified, distributed, sublicensed, or used in any form, in whole or in part, without prior written permission from the copyright holder.
 7-->
 8<script setup lang="ts">
 9import { ref } from 'vue'
10
11import LegendModal from './LegendModal.vue'
12
13const isModalOpen = ref(false)
14</script>
15
16<template>
17  <div
18    class="bg-$vp-c-bg hover:bg-$vp-c-bg/40 border-$vp-c-default-soft transition-all duration-500 mt-2 overflow-hidden hover:-translate-y-1 hover:shadow-lg rounded-lg border-2 border-solid relative z-0 max-md:bg-white/85 max-md:dark:bg-neutral-800/85 max-md:border max-md:border-neutral-200 max-md:dark:border-neutral-700"
19  >
20    <div class="h-20 w-full overflow-hidden">
21      <img
22        src="/sui.webp"
23        alt="Icon Key Banner"
24        class="w-full h-full object-cover"
25      />
26    </div>
27    <div class="p-5">
28      <button class="w-full text-left" @click="isModalOpen = true">
29        <div class="flex items-center gap-2">
30          <div class="i-lucide-badge-info text-$vp-c-text-1" />
31          <div class="text-$vp-c-text-1 lh-relaxed text-sm font-bold">
32            Icon key
33          </div>
34        </div>
35        <div class="text-$vp-c-text-2 text-sm mt-2">
36          Reference guide for all symbols used across the index.
37        </div>
38      </button>
39
40      <LegendModal :is-open="isModalOpen" @close="isModalOpen = false" />
41    </div>
42  </div>
43</template>
Keyboard shortcuts

Global

⌘K
Command palette & jump
/
Focus search
?
Show this help
g d
Dashboard
g e
Explore repositories
g n
Notifications

Repository & editor

t
Find file in repository
y
Copy immutable SHA permalink
g c
Code tab
g i
Issues tab
g m
Merge requests tab
g b
Builds tab
⌘↵
Submit active form