fix: 翻牌机制优化
This commit is contained in:
@@ -792,7 +792,7 @@ function generateShareContent(): string {
|
||||
return `
|
||||
🎁 【意心Ai】我来邀请你翻牌抽奖,分享我的限时邀请码~
|
||||
|
||||
使用我的邀请码可为你解锁1次额外翻牌机会,最大可白嫖官方Claude4.5 220RMB额度 Token!💰
|
||||
填写我的邀请码,咱们双方各增加1次翻牌机会!最大可白嫖官方Claude4.5 220RMB额度 Token!💰
|
||||
|
||||
👉 点击链接立即参与我的专属邀请码链接:
|
||||
${shareLink}
|
||||
@@ -1094,27 +1094,42 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
class="invite-dialog"
|
||||
>
|
||||
<div class="invite-dialog-content">
|
||||
<p class="dialog-tip">
|
||||
输入好友的邀请码,可增加翻牌次数,必定中奖每次奖励最大额度翻倍!(使用其他人邀请码,自己的邀请码将失效)
|
||||
</p>
|
||||
<el-input
|
||||
v-model="inputInviteCode"
|
||||
placeholder="请输入8位邀请码"
|
||||
maxlength="8"
|
||||
clearable
|
||||
size="large"
|
||||
class="code-input"
|
||||
>
|
||||
<template #prefix>
|
||||
<span style="font-size: 20px;">🎫</span>
|
||||
</template>
|
||||
</el-input>
|
||||
<!-- 已填写过邀请码的提示 -->
|
||||
<div v-if="taskData?.isFilledInviteCode" class="already-filled-box">
|
||||
<span class="filled-icon">✅</span>
|
||||
<p class="filled-text">
|
||||
您已填写过邀请码,每人仅能填写一次他人邀请码
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<template v-else>
|
||||
<p class="dialog-tip">
|
||||
输入好友的邀请码,双方各增加1次翻牌机会!必定中奖,每次奖励最大额度翻倍!
|
||||
</p>
|
||||
<el-input
|
||||
v-model="inputInviteCode"
|
||||
placeholder="请输入8位邀请码"
|
||||
maxlength="8"
|
||||
clearable
|
||||
size="large"
|
||||
class="code-input"
|
||||
>
|
||||
<template #prefix>
|
||||
<span style="font-size: 20px;">🎫</span>
|
||||
</template>
|
||||
</el-input>
|
||||
</template>
|
||||
</div>
|
||||
<template #footer>
|
||||
<el-button @click="inviteCodeDialog = false">
|
||||
取消
|
||||
</el-button>
|
||||
<el-button type="primary" :loading="loading" @click="handleUseInviteCode">
|
||||
<el-button
|
||||
v-if="!taskData?.isFilledInviteCode"
|
||||
type="primary"
|
||||
:loading="loading"
|
||||
@click="handleUseInviteCode"
|
||||
>
|
||||
确认使用
|
||||
</el-button>
|
||||
</template>
|
||||
@@ -1129,14 +1144,6 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
class="my-invite-dialog"
|
||||
>
|
||||
<div class="my-invite-dialog-content">
|
||||
<!-- 已使用过邀请码的提示 -->
|
||||
<!-- <div v-if="taskData?.isInvited" class="invite-disabled-box"> -->
|
||||
<!-- <span class="disabled-icon">🔒</span> -->
|
||||
<!-- <p class="disabled-text"> -->
|
||||
<!-- 您已使用过他人的邀请码,无法生成自己的邀请码 -->
|
||||
<!-- </p> -->
|
||||
<!-- </div> -->
|
||||
|
||||
<!-- 显示已有的邀请码 -->
|
||||
<div v-if="taskData?.myInviteCode" class="my-invite-code-display">
|
||||
<div class="code-box">
|
||||
@@ -1158,9 +1165,20 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
复制分享链接
|
||||
</el-button>
|
||||
</div>
|
||||
<!-- 显示当前用户是否已填写过邀请码 -->
|
||||
<div v-if="taskData?.isFilledInviteCode" class="filled-status-info">
|
||||
<span class="status-icon">✅</span>
|
||||
<span class="status-text">您已填写过他人邀请码</span>
|
||||
</div>
|
||||
<div v-else class="unfilled-status-info">
|
||||
<span class="status-icon">💡</span>
|
||||
<span class="status-text">您还可以填写他人邀请码获得额外机会</span>
|
||||
</div>
|
||||
<p class="invite-tip">
|
||||
💌 分享给好友,好友使用后可解锁最后3次翻牌机会
|
||||
💌 分享给好友,好友填写您的邀请码后<br>
|
||||
<strong>双方各增加1次翻牌机会!</strong>
|
||||
</p>
|
||||
|
||||
<div class="share-preview">
|
||||
<div class="share-preview-title">
|
||||
📱 分享预览
|
||||
@@ -1174,7 +1192,7 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
<!-- 生成邀请码 -->
|
||||
<div v-else class="generate-invite-box">
|
||||
<p class="generate-tip">
|
||||
您还没有邀请码,生成后可以分享给好友
|
||||
您还没有邀请码,生成后分享给好友,<strong>双方各增加1次翻牌机会</strong>!
|
||||
</p>
|
||||
<el-button
|
||||
type="primary"
|
||||
@@ -2050,6 +2068,28 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.already-filled-box {
|
||||
text-align: center;
|
||||
padding: 24px 16px;
|
||||
background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
|
||||
border: 1px solid #bae6fd;
|
||||
border-radius: 12px;
|
||||
|
||||
.filled-icon {
|
||||
font-size: 48px;
|
||||
display: block;
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
.filled-text {
|
||||
font-size: 15px;
|
||||
color: #0369a1;
|
||||
line-height: 1.6;
|
||||
margin: 0;
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* 我的邀请码对话框样式 */
|
||||
@@ -2109,7 +2149,45 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
font-size: 13px;
|
||||
color: #909399;
|
||||
line-height: 1.5;
|
||||
margin: 0 0 16px 0;
|
||||
margin: 0 0 12px 0;
|
||||
|
||||
strong {
|
||||
color: #f56c6c;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.filled-status-info,
|
||||
.unfilled-status-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 6px;
|
||||
padding: 8px 12px;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 12px;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.filled-status-info {
|
||||
background: #f0fdf4;
|
||||
border: 1px solid #86efac;
|
||||
color: #166534;
|
||||
|
||||
.status-icon {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.unfilled-status-info {
|
||||
background: #fefce8;
|
||||
border: 1px solid #fde047;
|
||||
color: #854d0e;
|
||||
|
||||
.status-icon {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.share-preview {
|
||||
@@ -2169,6 +2247,11 @@ function getCardClass(record: CardFlipRecord): string[] {
|
||||
color: #606266;
|
||||
margin-bottom: 20px;
|
||||
line-height: 1.6;
|
||||
|
||||
strong {
|
||||
color: #f56c6c;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.el-button {
|
||||
|
||||
Reference in New Issue
Block a user