🚸 增加胡桃云购买跳转

This commit is contained in:
BTMuli
2026-01-12 23:43:09 +08:00
parent 44dd81463b
commit 1d82ecd319
2 changed files with 6 additions and 74 deletions

View File

@@ -33,6 +33,7 @@
@click="hutaoStore.tryRefreshInfo()"
/>
<v-btn icon="mdi-lock-reset" title="重置密码" variant="outlined" @click="showVerify = true" />
<v-btn icon="mdi-cart" title="购买胡桃云" variant="outlined" @click="toDonate()" />
</template>
</v-card>
<TcoHutaoVerify v-model="showVerify" />
@@ -41,6 +42,7 @@
import showDialog from "@comp/func/dialog.js";
import TcoHutaoVerify from "@comp/pageConfig/tco-hutaoVerify.vue";
import useHutaoStore from "@store/hutao.js";
import { openUrl } from "@tauri-apps/plugin-opener";
import { timeStr2str } from "@utils/toolFunc.js";
import { storeToRefs } from "pinia";
import { ref } from "vue";
@@ -68,6 +70,10 @@ async function tryLogin(): Promise<void> {
isLogin.value = false;
await hutaoStore.tryLogin();
}
async function toDonate(): Promise<void> {
await openUrl("https://afdian.com/item/80d3b9decf9011edb5f452540025c377");
}
</script>
<style lang="scss" scoped>
.tch-box {

View File

@@ -180,79 +180,5 @@ onUnmounted(() => {
align-items: stretch;
justify-content: flex-start;
font-size: 10px;
row-gap: 8px;
}
.thvc-form-item {
position: relative;
display: flex;
align-items: center;
justify-content: center;
column-gap: 8px;
}
.thvc-fi-label {
position: relative;
width: 60px;
flex-shrink: 0;
font-family: var(--font-title);
text-align: right;
}
.thvc-fi-input {
position: relative;
display: flex;
width: 100%;
align-items: center;
justify-content: center;
column-gap: 4px;
input {
width: 100%;
height: 24px;
padding: 2px 8px;
border: 1px solid var(--common-shadow-1);
border-radius: 4px;
background: var(--box-bg-2);
font-size: 12px;
line-height: 16px;
&:focus-visible {
border: unset;
outline: 1px solid var(--tgc-od-blue);
}
}
.icon {
color: var(--tgc-od-white);
cursor: pointer;
}
}
.thvc-fii-append {
flex-shrink: 0;
&.code {
display: flex;
width: 80px;
height: 24px;
box-sizing: border-box;
align-items: center;
justify-content: center;
border-radius: 4px;
background: var(--tgc-od-blue);
color: var(--tgc-white-1);
cursor: pointer;
font-size: 12px;
line-height: 24px;
&:hover {
filter: brightness(1.2);
}
&.disabled {
cursor: not-allowed;
}
}
}
</style>