mirror of
https://github.com/lucide-icons/lucide.git
synced 2026-11-18 14:38:24 +00:00
* setup icon popularity call * Adjust sort button * Adjust sorting * Adds aliases * Format code * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Add check for env variable * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Improve styling on mobile * Better icon detail page * Update detail page * feat: make edit button more visible * Fix types * Add unreleased version tag * Adjust icon detail * Added edit button * format code * Replace pencil sparkles * Revert changes * Fix types * Add docs checks * Fix types * Fix awaiting release * revert icons changes * Format code * Fix type issues * Update CarbonAdOverlay to not display Disable CarbonAdOverlay by setting drawerOpen to false. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Fix types * Fix condition for showing awaiting release icons Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Format code --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: Jakob Guddas <github@jguddas.de>
83 lines
1.7 KiB
Vue
83 lines
1.7 KiB
Vue
<script setup lang="ts">
|
|
import { computed } from 'vue';
|
|
|
|
const props = defineProps<{
|
|
href?: string;
|
|
}>()
|
|
|
|
const isExternal = computed(() => {
|
|
return props.href?.startsWith('http') ?? false
|
|
})
|
|
|
|
const component = computed(() => {
|
|
return props.href ? 'a' : 'button'
|
|
})
|
|
|
|
const target = computed(() => {
|
|
return isExternal.value ? '_blank' : undefined
|
|
})
|
|
|
|
const rel = computed(() => {
|
|
return isExternal.value ? 'noreferrer noopener' : undefined
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<component
|
|
:is="component"
|
|
v-bind="$attrs"
|
|
:href="href"
|
|
:target="target"
|
|
:rel="rel"
|
|
class="icon-button"
|
|
>
|
|
<slot />
|
|
</component>
|
|
</template>
|
|
|
|
<style scoped>
|
|
.icon-button {
|
|
display: inline-flex;
|
|
border: 1px solid transparent;
|
|
text-align: center;
|
|
font-weight: 600;
|
|
padding: 6px;
|
|
border-radius: 8px;
|
|
white-space: nowrap;
|
|
transition: color 0.25s, border-color 0.25s, background-color 0.25s;
|
|
border-radius: 6px;
|
|
background-color: var(--vp-c-bg-alt);
|
|
color: inherit;
|
|
text-decoration: none;
|
|
/* width: 56px;
|
|
height: 56px; */
|
|
gap: 8px;
|
|
font-size: 16px;
|
|
font-weight: 500;
|
|
transition: color 0.1s, border-color 0.1s, background-color 0.1s;
|
|
}
|
|
|
|
.icon-button span {
|
|
padding: 0 4px;
|
|
display: block;
|
|
}
|
|
|
|
.icon-button:hover {
|
|
border-color: var(--vp-button-alt-hover-border);
|
|
color: var(--vp-button-alt-hover-text);
|
|
background-color: var(--vp-button-alt-hover-bg);
|
|
}
|
|
|
|
.icon-button:active {
|
|
border-color: var(--vp-button-alt-active-border);
|
|
color: var(--vp-button-alt-active-text);
|
|
background-color: var(--vp-button-alt-active-bg);
|
|
}
|
|
|
|
.icon-button.active {
|
|
border-color: var(--vp-c-brand);
|
|
/* color: var(--vp-button-alt-active-text);
|
|
background-color: var(--vp-button-alt-active-bg); */
|
|
}
|
|
</style>
|