feat: 添加 IonRange 组件类型声明;更新 CSS 变量以优化样式;重构交易界面,添加交易切换和市场信息组件

This commit is contained in:
2025-12-29 16:58:32 +07:00
parent e0d64261e1
commit 7f10d4f4e4
8 changed files with 141 additions and 294 deletions

View File

@@ -1,13 +1,13 @@
<script lang='ts' setup>
const { type = "primary", size = "medium", round = false } = defineProps<{
type?: "primary" | "secondary" | "tertiary" | "success" | "warning" | "danger";
size?: "small" | "medium" | "large";
size?: "mini" | "small" | "medium" | "large";
round?: boolean;
}>();
</script>
<template>
<div class="ui-tag rounded-md inline-block" :class="[type, size, { 'rounded-full': round }]">
<div class="ui-tag" :class="[type, size, { 'rounded-full': round }]">
<slot />
</div>
</template>
@@ -16,7 +16,7 @@ const { type = "primary", size = "medium", round = false } = defineProps<{
@reference "tailwindcss";
.ui-tag {
@apply px-3 py-1 text-xs;
@apply px-3 py-1 text-xs rounded-md inline-block;
}
.ui-tag.primary {
@apply bg-(--ion-color-dark) text-white;
@@ -25,7 +25,7 @@ const { type = "primary", size = "medium", round = false } = defineProps<{
@apply bg-(--ion-color-medium-shade) text-white;
}
.ui-tag.tertiary {
@apply bg-(--ion-color-medium-tint) text-white;
@apply bg-(--ion-color-light-shade) text-black;
}
.ui-tag.success {
@apply bg-(--ion-color-success) text-white;
@@ -36,13 +36,16 @@ const { type = "primary", size = "medium", round = false } = defineProps<{
.ui-tag.danger {
@apply bg-(--ion-color-danger) text-white;
}
.ui-tag.mini {
@apply text-[10px] px-1 py-0.5 rounded-sm;
}
.ui-tag.small {
@apply text-xs px-2 py-0.5;
@apply text-xs px-2 py-0.5 rounded-sm;
}
.ui-tag.medium {
@apply text-sm px-3 py-1;
@apply text-sm px-3 py-1 rounded-md;
}
.ui-tag.large {
@apply text-base px-4 py-2;
@apply text-base px-4 py-2 rounded-md;
}
</style>