From d0f98ad8e1047e3161a458399ad3005404ed87b8 Mon Sep 17 00:00:00 2001
From: whychdw <496960745@qq.com>
Date: 星期五, 06 六月 2025 15:52:15 +0800
Subject: [PATCH] 标准参数管理

---
 src/components/TabButton/index.vue |   37 +++++++++++++++++++++++++++++++++++++
 1 files changed, 37 insertions(+), 0 deletions(-)

diff --git a/src/components/TabButton/index.vue b/src/components/TabButton/index.vue
new file mode 100644
index 0000000..97439e2
--- /dev/null
+++ b/src/components/TabButton/index.vue
@@ -0,0 +1,37 @@
+<script setup>
+const props = defineProps({
+  active: {
+    type: Boolean,
+    default: false
+  }
+});
+</script>
+
+<template>
+  <div class="tab-button-wrapper" :class="{'active': active}">
+    <slot></slot>
+  </div>
+</template>
+
+<style scoped lang="less">
+.tab-button-wrapper {
+  display: inline-block;
+  user-select: none;
+  padding: 12px 48px;
+  text-align: center;
+  background-image: url("./images/bg.png");
+  background-size: 100% 100%;
+  background-repeat: no-repeat;
+  cursor: pointer;
+  font-size: 16px;
+  &:hover {
+    font-weight: 700;
+  }
+  &:active {
+    background-image: url("./images/active-bg.png");
+  }
+  &.active {
+    background-image: url("./images/active-bg.png");
+  }
+}
+</style>

--
Gitblit v1.9.1