mirror of
https://github.com/element-plus/element-plus.git
synced 2024-12-27 03:01:14 +08:00
31 lines
458 B
Vue
31 lines
458 B
Vue
<script setup lang="ts">
|
|
import type { Component } from 'vue'
|
|
|
|
defineProps<{
|
|
icon: Component
|
|
link: string
|
|
text: string
|
|
}>()
|
|
</script>
|
|
|
|
<template>
|
|
<a
|
|
:href="link"
|
|
:title="text"
|
|
target="_blank"
|
|
rel="noreferrer noopener"
|
|
class="social-link"
|
|
>
|
|
<ElIcon :size="20">
|
|
<component :is="icon" />
|
|
</ElIcon>
|
|
</a>
|
|
</template>
|
|
|
|
<style scoped lang="scss">
|
|
.social-link {
|
|
padding: 0 4px;
|
|
color: var(--text-color);
|
|
}
|
|
</style>
|