chore(repo): 合并推广分享与智能路由分支基线
This commit is contained in:
@@ -22,6 +22,9 @@ import { API, showError, showSuccess, copy } from '../../helpers';
|
||||
|
||||
const { Text, Title, Paragraph } = Typography;
|
||||
|
||||
// 暂时隐藏推广弹窗里的邀请奖励规则入口。
|
||||
const SHOW_INVITATION_REWARD_RULES = false;
|
||||
|
||||
// 默认海报模板配置
|
||||
const DEFAULT_TEMPLATES = [
|
||||
{ id: 'blue', name: '科技蓝' },
|
||||
@@ -449,23 +452,25 @@ const PromotionPosterModal = ({ visible, onClose }) => {
|
||||
title={t('邀请链接获取中,请稍后')}
|
||||
/>
|
||||
)}
|
||||
<button
|
||||
type='button'
|
||||
className='pm-rewards'
|
||||
onClick={() => {
|
||||
onClose();
|
||||
navigate('/user-center/invite');
|
||||
}}
|
||||
>
|
||||
<span className='pm-rewards-icon'>
|
||||
<Gift size={20} aria-hidden />
|
||||
</span>
|
||||
<span className='pm-rewards-copy'>
|
||||
<strong>{t('查看邀请奖励规则')}</strong>
|
||||
<span>{t('了解返佣比例和奖励详情')}</span>
|
||||
</span>
|
||||
<ChevronRight size={18} aria-hidden />
|
||||
</button>
|
||||
{SHOW_INVITATION_REWARD_RULES && (
|
||||
<button
|
||||
type='button'
|
||||
className='pm-rewards'
|
||||
onClick={() => {
|
||||
onClose();
|
||||
navigate('/user-center/invite');
|
||||
}}
|
||||
>
|
||||
<span className='pm-rewards-icon'>
|
||||
<Gift size={20} aria-hidden />
|
||||
</span>
|
||||
<span className='pm-rewards-copy'>
|
||||
<strong>{t('查看邀请奖励规则')}</strong>
|
||||
<span>{t('了解返佣比例和奖励详情')}</span>
|
||||
</span>
|
||||
<ChevronRight size={18} aria-hidden />
|
||||
</button>
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
</Modal>
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
--pm-soft: var(--brand-primary-soft);
|
||||
--pm-qr-surface: var(--ui-color-white);
|
||||
--pm-poster-ink: var(--ui-color-white);
|
||||
--pm-body-max-height: calc(100dvh - 200px);
|
||||
--pm-tab-panel-height: 448px;
|
||||
--pm-preview-min-height: 418px;
|
||||
max-width: calc(100vw - 32px);
|
||||
padding-block: 24px;
|
||||
}
|
||||
@@ -29,23 +32,44 @@
|
||||
right: 24px;
|
||||
}
|
||||
.promotion-modal .ant-modal-body {
|
||||
max-height: calc(100dvh - 160px);
|
||||
max-height: var(--pm-body-max-height);
|
||||
overflow-y: auto;
|
||||
overscroll-behavior: contain;
|
||||
}
|
||||
.promotion-tabs {
|
||||
max-block-size: var(--pm-body-max-height);
|
||||
}
|
||||
.promotion-tabs > .ant-tabs-nav {
|
||||
flex-shrink: 0;
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
.promotion-tabs > .ant-tabs-body-holder {
|
||||
flex: 0 1 var(--pm-tab-panel-height);
|
||||
min-block-size: 0;
|
||||
overflow-y: auto;
|
||||
overscroll-behavior: contain;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
.pm-tab-label {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
.pm-link-layout {
|
||||
.pm-link-layout,
|
||||
.pm-poster-layout {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
|
||||
gap: 32px;
|
||||
align-items: stretch;
|
||||
align-items: start;
|
||||
}
|
||||
.pm-invitation-card,
|
||||
.pm-preview-stage {
|
||||
min-block-size: var(--pm-preview-min-height);
|
||||
border-radius: 12px;
|
||||
}
|
||||
.pm-share-details,
|
||||
.pm-poster-options {
|
||||
align-self: center;
|
||||
}
|
||||
.pm-invitation-card {
|
||||
display: flex;
|
||||
@@ -53,7 +77,6 @@
|
||||
align-items: center;
|
||||
padding: 28px 20px;
|
||||
border: 1px solid var(--pm-border);
|
||||
border-radius: 12px;
|
||||
background: var(--pm-muted);
|
||||
text-align: center;
|
||||
min-width: 0;
|
||||
@@ -195,12 +218,6 @@
|
||||
flex-shrink: 0;
|
||||
color: var(--pm-secondary);
|
||||
}
|
||||
.pm-poster-layout {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
|
||||
gap: 32px;
|
||||
align-items: center;
|
||||
}
|
||||
.promotion-modal [data-poster-template='blue'] {
|
||||
--pm-template-background: #2455b8;
|
||||
}
|
||||
@@ -217,7 +234,6 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
padding-inline: 16px;
|
||||
border-radius: 12px;
|
||||
background: var(--pm-template-background);
|
||||
color: var(--pm-poster-ink);
|
||||
min-width: 0;
|
||||
@@ -228,8 +244,7 @@
|
||||
align-items: center;
|
||||
width: min(100%, 280px);
|
||||
min-width: 0;
|
||||
min-height: 448px;
|
||||
padding: 32px 8px 24px;
|
||||
padding: 28px 8px 20px;
|
||||
text-align: center;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
@@ -246,7 +261,7 @@
|
||||
color: inherit;
|
||||
}
|
||||
.pm-poster h3 {
|
||||
margin: 20px 0;
|
||||
margin: 16px 0;
|
||||
font-size: 16px;
|
||||
line-height: 1.5;
|
||||
color: inherit;
|
||||
@@ -312,6 +327,10 @@
|
||||
outline-offset: 3px;
|
||||
}
|
||||
@media (max-width: 600px) {
|
||||
.promotion-modal.ant-modal {
|
||||
--pm-tab-panel-height: 760px;
|
||||
--pm-preview-min-height: 395px;
|
||||
}
|
||||
.promotion-modal .ant-modal-container {
|
||||
padding: 20px;
|
||||
}
|
||||
@@ -322,9 +341,6 @@
|
||||
top: 18px;
|
||||
right: 16px;
|
||||
}
|
||||
.promotion-modal .ant-modal-body {
|
||||
max-height: calc(100dvh - 136px);
|
||||
}
|
||||
.pm-link-layout,
|
||||
.pm-poster-layout {
|
||||
grid-template-columns: minmax(0, 1fr);
|
||||
@@ -344,7 +360,6 @@
|
||||
width: 100%;
|
||||
}
|
||||
.pm-poster {
|
||||
min-height: 408px;
|
||||
padding-block: 24px 20px;
|
||||
}
|
||||
.pm-template-list {
|
||||
|
||||
Reference in New Issue
Block a user