feat: 1.升级 Ant Design Ui 至 v6 2. 修复企业充值金额输入限制
This commit is contained in:
@@ -37,7 +37,7 @@ const ChannelConsumption = ({ data, title, icon, t, embedded = false }) => {
|
||||
</div>
|
||||
)
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='h-[300px] flex items-center justify-center text-gray-400'>
|
||||
{t('暂无数据')}
|
||||
@@ -136,7 +136,7 @@ const ChannelConsumption = ({ data, title, icon, t, embedded = false }) => {
|
||||
</div>
|
||||
)
|
||||
}
|
||||
bodyStyle={{ padding: '0' }}
|
||||
styles={{ body: { padding: '0' } }}
|
||||
>
|
||||
<Table
|
||||
columns={columns}
|
||||
|
||||
@@ -180,7 +180,7 @@ const DailyStatsTable = ({ data, title, icon, t, embedded = false }) => {
|
||||
</div>
|
||||
)
|
||||
}
|
||||
bodyStyle={{ padding: '0' }}
|
||||
styles={{ body: { padding: '0' } }}
|
||||
>
|
||||
{embedded && (
|
||||
<div className='flex justify-end p-4'>
|
||||
|
||||
@@ -251,7 +251,7 @@ const HighFreqLowCostUsers = ({
|
||||
</Space>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{/* 筛选区 */}
|
||||
<div className='mb-4 grid grid-cols-2 sm:grid-cols-4 gap-3 items-end'>
|
||||
|
||||
@@ -104,7 +104,7 @@ const ModelDistribution = ({ data, title, icon, t }) => {
|
||||
<span className='font-semibold'>{title}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{pieSpec ? (
|
||||
<div>
|
||||
|
||||
@@ -134,7 +134,7 @@ const OverviewCards = ({ overview, loading = false, t }) => {
|
||||
<Card
|
||||
key={index}
|
||||
className={`${card.bgColor} border-none shadow-sm hover:shadow-md transition-shadow`}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='flex items-start justify-between'>
|
||||
<div className='flex-1'>
|
||||
|
||||
@@ -120,7 +120,7 @@ const TopupChannelChart = ({ data, title, icon, t }) => {
|
||||
<span className='font-semibold'>{title}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{pieSpec ? (
|
||||
<div>
|
||||
|
||||
@@ -237,7 +237,7 @@ const TrendCharts = ({ title, icon, data, type, t }) => {
|
||||
<span className='font-semibold'>{title}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{spec ? (
|
||||
<VChart
|
||||
|
||||
@@ -32,7 +32,7 @@ const UserRanking = ({ data, title, icon, t }) => {
|
||||
<span className='font-semibold'>{title}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='h-[300px] flex items-center justify-center text-gray-400'>
|
||||
{t('暂无数据')}
|
||||
@@ -75,7 +75,7 @@ const UserRanking = ({ data, title, icon, t }) => {
|
||||
</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='space-y-2 max-h-[450px] overflow-y-auto pr-1'>
|
||||
{data.map((item, index) => (
|
||||
|
||||
@@ -300,7 +300,7 @@ const UserSurveyStats = ({ title, icon, t }) => {
|
||||
<div className={collapsed ? 'hidden' : ''}>
|
||||
<Card
|
||||
className='analytics-fold-content shadow-sm'
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{!collapsed && (
|
||||
<Spin spinning={loading}>
|
||||
|
||||
@@ -33,7 +33,7 @@ const UserTopupRanking = ({ data, title, icon, t, embedded = false }) => {
|
||||
</div>
|
||||
)
|
||||
}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='h-[300px] flex items-center justify-center text-gray-400'>
|
||||
{t('暂无数据')}
|
||||
@@ -137,7 +137,7 @@ const UserTopupRanking = ({ data, title, icon, t, embedded = false }) => {
|
||||
</div>
|
||||
)
|
||||
}
|
||||
bodyStyle={{ padding: '0' }}
|
||||
styles={{ body: { padding: '0' } }}
|
||||
>
|
||||
<Table
|
||||
// 列宽合计远超窄屏视口;没有 scroll 时表格会压缩到 min-content 硬塞进去,
|
||||
|
||||
@@ -40,7 +40,7 @@ export const ReportHeader = ({ report, onExport, t }) => {
|
||||
|
||||
return (
|
||||
<div className='flex flex-col gap-4'>
|
||||
<Card className='shadow-sm' bodyStyle={{ padding: '16px 20px' }}>
|
||||
<Card className='shadow-sm' styles={{ body: { padding: '16px 20px' } }}>
|
||||
<div className='flex flex-col md:flex-row md:items-center md:justify-between gap-3'>
|
||||
<div className='min-w-0'>
|
||||
<div className='text-xs font-semibold tracking-wider text-brand mb-1'>
|
||||
|
||||
@@ -40,7 +40,7 @@ export const SectionCard = ({
|
||||
{extra}
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '16px', ...bodyStyle }}
|
||||
styles={{ body: { padding: '16px', ...bodyStyle } }}
|
||||
>
|
||||
{children}
|
||||
</Card>
|
||||
@@ -106,11 +106,11 @@ export const KpiCard = ({
|
||||
}) => (
|
||||
<Card
|
||||
className={`shadow-sm border-none transition-shadow ${onClick ? 'cursor-pointer hover:shadow-md' : ''}`}
|
||||
bodyStyle={{ padding: '14px 16px' }}
|
||||
onClick={onClick}
|
||||
style={{
|
||||
borderLeft: `3px solid ${accent || 'var(--ui-color-primary)'}`,
|
||||
}}
|
||||
styles={{ body: { padding: '14px 16px' } }}
|
||||
>
|
||||
<div className='flex items-center gap-1 text-xs text-gray-500 dark:text-gray-400 mb-1'>
|
||||
<span className='truncate'>{title}</span>
|
||||
|
||||
@@ -164,7 +164,7 @@ const NewUserGiftModal = ({ visible, onClose, quota }) => {
|
||||
</div>
|
||||
|
||||
<style jsx='true'>{`
|
||||
.new-user-gift-modal .ant-modal-content {
|
||||
.new-user-gift-modal .ant-modal-container {
|
||||
border-radius: 20px;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
|
||||
@@ -108,7 +108,6 @@ export function ColumnSettingsModal({
|
||||
'--cs-theme-border': token.colorBorderSecondary,
|
||||
}}
|
||||
onCancel={onCancel}
|
||||
maskClosable
|
||||
keyboard
|
||||
footer={
|
||||
<div className='table-column-settings-footer'>
|
||||
@@ -123,6 +122,7 @@ export function ColumnSettingsModal({
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
<div className='table-column-settings-all'>
|
||||
<Checkbox
|
||||
@@ -155,7 +155,7 @@ export function ColumnSettingsModal({
|
||||
className='table-column-settings-error'
|
||||
type='error'
|
||||
showIcon
|
||||
message={t('请至少保留一列')}
|
||||
title={t('请至少保留一列')}
|
||||
/>
|
||||
)}
|
||||
</Modal>
|
||||
|
||||
@@ -21,7 +21,7 @@ html.dark .table-column-settings-dialog {
|
||||
max-width: calc(100vw - 32px);
|
||||
}
|
||||
|
||||
.table-column-settings-dialog .ant-modal-content {
|
||||
.table-column-settings-dialog .ant-modal-container {
|
||||
padding: 20px 24px;
|
||||
border-radius: 12px;
|
||||
}
|
||||
|
||||
@@ -187,7 +187,7 @@ const CardPro = ({
|
||||
title={headerContent}
|
||||
footer={footerContent}
|
||||
shadows={shadows}
|
||||
bordered={bordered}
|
||||
variant={bordered === false ? 'borderless' : 'outlined'}
|
||||
style={style}
|
||||
{...props}
|
||||
>
|
||||
|
||||
@@ -656,7 +656,6 @@ const JSONEditor = ({
|
||||
<TabPane tab={t('可视化')} itemKey='visual' />
|
||||
<TabPane tab={t('手动编辑')} itemKey='manual' />
|
||||
</Tabs>
|
||||
|
||||
{template && templateLabel && (
|
||||
<Button type='tertiary' onClick={fillTemplate} size='small'>
|
||||
{templateLabel}
|
||||
@@ -667,8 +666,8 @@ const JSONEditor = ({
|
||||
headerStyle={{
|
||||
padding: 'var(--json-editor-header-padding, 12px 16px)',
|
||||
}}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
className='!rounded-2xl'
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
{/* JSON错误提示 */}
|
||||
{hasJsonError && (
|
||||
|
||||
@@ -224,6 +224,7 @@ export function ConsoleDrawer({
|
||||
rootStyle,
|
||||
footer,
|
||||
width = 560,
|
||||
size = width,
|
||||
...props
|
||||
}) {
|
||||
const themeStyle = useConsoleThemeStyle();
|
||||
@@ -231,7 +232,7 @@ export function ConsoleDrawer({
|
||||
return (
|
||||
<Drawer
|
||||
{...props}
|
||||
width={width}
|
||||
size={size}
|
||||
rootStyle={{ ...themeStyle, ...rootStyle }}
|
||||
footer={normalizeFooter(footer)}
|
||||
rootClassName={classes(
|
||||
|
||||
@@ -281,19 +281,17 @@
|
||||
min-width: 0;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
:is(.console-page, .console-overlay) .ant-alert-message,
|
||||
:is(.console-page, .console-overlay) .ant-alert-title,
|
||||
:is(.console-page, .console-overlay) .ant-alert-description {
|
||||
color: var(--console-text);
|
||||
font-size: 14px;
|
||||
line-height: 22px;
|
||||
}
|
||||
:is(.console-page, .console-overlay) .ant-alert-message {
|
||||
:is(.console-page, .console-overlay) .ant-alert-title {
|
||||
margin-bottom: 0;
|
||||
font-weight: 500;
|
||||
}
|
||||
:is(.console-page, .console-overlay)
|
||||
.ant-alert-message
|
||||
+ .ant-alert-description {
|
||||
:is(.console-page, .console-overlay) .ant-alert-title + .ant-alert-description {
|
||||
margin-top: 4px;
|
||||
}
|
||||
:is(.console-page, .console-overlay) .ant-alert-icon {
|
||||
|
||||
@@ -74,7 +74,7 @@ const AnnouncementsPanel = ({
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
<ScrollableContainer maxHeight='24rem'>
|
||||
{announcementData.length > 0 ? (
|
||||
|
||||
@@ -45,7 +45,7 @@ const ApiInfoPanel = ({
|
||||
{t('API信息')}
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
<ScrollableContainer maxHeight='24rem'>
|
||||
{apiInfoData.length > 0 ? (
|
||||
|
||||
@@ -45,7 +45,7 @@ const FaqPanel = ({
|
||||
{t('常见问答')}
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
<ScrollableContainer maxHeight='24rem'>
|
||||
{faqData.length > 0 ? (
|
||||
|
||||
@@ -60,7 +60,7 @@ const UptimePanel = ({
|
||||
/>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
{/* 内容区域 */}
|
||||
<div className='relative'>
|
||||
|
||||
@@ -44,7 +44,7 @@ const UserDashboardFilterModal = ({
|
||||
onOk={handleSearchConfirm}
|
||||
okText={t('查询')}
|
||||
cancelText={t('取消')}
|
||||
maskClosable
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
<Form layout='vertical' requiredMark={false}>
|
||||
<Form.Item label={t('时间范围')} htmlFor='dashboard-filter-range'>
|
||||
|
||||
@@ -135,7 +135,7 @@ const NoticeModal = ({
|
||||
if (loading) {
|
||||
return (
|
||||
<div className='nm-empty'>
|
||||
<Spin tip={t('加载中...')}>
|
||||
<Spin description={t('加载中...')}>
|
||||
<div className='nm-spin-placeholder' />
|
||||
</Spin>
|
||||
</div>
|
||||
@@ -213,7 +213,6 @@ const NoticeModal = ({
|
||||
'--nm-tab-bg': token.colorBgLayout,
|
||||
'--nm-primary': token.colorPrimary,
|
||||
}}
|
||||
maskClosable={true}
|
||||
footer={
|
||||
<div className='nm-footer'>
|
||||
<Checkbox
|
||||
@@ -230,6 +229,7 @@ const NoticeModal = ({
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
<Segmented
|
||||
block
|
||||
|
||||
@@ -203,7 +203,7 @@ const ActionButtons = ({
|
||||
|
||||
{/* Divider:原型仅在主操作与工具按钮之间保留一条竖线 */}
|
||||
{hasPrimaryActions && hasUtilityActions && (
|
||||
<Divider type='vertical' className='ui-header-actions-divider' />
|
||||
<Divider orientation='vertical' className='ui-header-actions-divider' />
|
||||
)}
|
||||
|
||||
{isActionVisible('newYear') && (
|
||||
|
||||
@@ -147,7 +147,6 @@ const UserArea = ({
|
||||
placement='bottomRight'
|
||||
open={open}
|
||||
onOpenChange={setOpen}
|
||||
overlayClassName='ui-account-dropdown'
|
||||
menu={{ items, onClick: () => setOpen(false) }}
|
||||
popupRender={(menu) => (
|
||||
<div className='ui-account-panel'>
|
||||
@@ -168,6 +167,7 @@ const UserArea = ({
|
||||
{menu}
|
||||
</div>
|
||||
)}
|
||||
classNames={{ root: 'ui-account-dropdown' }}
|
||||
>
|
||||
<AntButton
|
||||
type='text'
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
padding-bottom: 24px;
|
||||
color: var(--nm-text);
|
||||
}
|
||||
.notice-modal .ant-modal-content {
|
||||
.notice-modal .ant-modal-container {
|
||||
padding: 20px 24px;
|
||||
background: var(--nm-surface);
|
||||
border-radius: 12px;
|
||||
@@ -175,7 +175,7 @@
|
||||
.notice-modal.ant-modal {
|
||||
top: 24px;
|
||||
}
|
||||
.notice-modal .ant-modal-content {
|
||||
.notice-modal .ant-modal-container {
|
||||
padding: 20px 16px;
|
||||
}
|
||||
.nm-notice-scroll,
|
||||
|
||||
@@ -149,7 +149,7 @@ export const MembershipHistoryContent = ({ visible, t, inline = false }) => {
|
||||
const status = getMembershipStatus(membership);
|
||||
const config = STATUS_CONFIG[status] || STATUS_CONFIG.expired;
|
||||
return (
|
||||
<AntTag bordered={false} color={config.color}>
|
||||
<AntTag variant='filled' color={config.color}>
|
||||
{t(config.label)}
|
||||
</AntTag>
|
||||
);
|
||||
|
||||
@@ -396,24 +396,26 @@ const ChatArea = ({
|
||||
|
||||
<Card
|
||||
className={`h-full min-h-0 ${styleState.isExperienceMode ? 'border-none shadow-none bg-transparent' : ''}`}
|
||||
bordered={false}
|
||||
variant='borderless'
|
||||
style={{
|
||||
background: styleState.isExperienceMode ? 'transparent' : undefined,
|
||||
backgroundColor: styleState.isExperienceMode
|
||||
? 'transparent'
|
||||
: undefined,
|
||||
}}
|
||||
bodyStyle={{
|
||||
padding: 0,
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
overflow: 'hidden',
|
||||
minHeight: 0,
|
||||
background: styleState.isExperienceMode ? 'transparent' : undefined,
|
||||
backgroundColor: styleState.isExperienceMode
|
||||
? 'transparent'
|
||||
: undefined,
|
||||
styles={{
|
||||
body: {
|
||||
padding: 0,
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
overflow: 'hidden',
|
||||
minHeight: 0,
|
||||
background: styleState.isExperienceMode ? 'transparent' : undefined,
|
||||
backgroundColor: styleState.isExperienceMode
|
||||
? 'transparent'
|
||||
: undefined,
|
||||
},
|
||||
}}
|
||||
>
|
||||
{/* 聊天头部 */}
|
||||
|
||||
@@ -100,12 +100,14 @@ const DebugPanel = ({
|
||||
return (
|
||||
<Card
|
||||
className='h-full flex flex-col'
|
||||
bordered={false}
|
||||
bodyStyle={{
|
||||
padding: styleState.isMobile ? '16px' : '24px',
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
variant='borderless'
|
||||
styles={{
|
||||
body: {
|
||||
padding: styleState.isMobile ? '16px' : '24px',
|
||||
height: '100%',
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
},
|
||||
}}
|
||||
>
|
||||
<div className='flex items-center justify-between mb-6 flex-shrink-0'>
|
||||
|
||||
@@ -617,7 +617,7 @@ const PersonalSetting = () => {
|
||||
<div className='ui-profile-meta'>
|
||||
<div className='ui-profile-name'>
|
||||
<strong>{getDisplayName()}</strong>
|
||||
<AntTag color='gold' bordered={false}>
|
||||
<AntTag color='gold' variant='filled'>
|
||||
{roleInfo.text}
|
||||
</AntTag>
|
||||
</div>
|
||||
|
||||
@@ -837,8 +837,8 @@ const NotificationSettings = ({
|
||||
? ''
|
||||
: 'opacity-50'
|
||||
}`}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
hoverable
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='flex justify-between items-center h-full'>
|
||||
<div className='flex-1 text-left'>
|
||||
|
||||
@@ -129,7 +129,7 @@ const UserInfoHeader = ({ t, userState }) => {
|
||||
<Card
|
||||
size='small'
|
||||
className='!rounded-xl'
|
||||
bodyStyle={{ padding: '12px 16px' }}
|
||||
styles={{ body: { padding: '12px 16px' } }}
|
||||
>
|
||||
<div className='flex items-center gap-4'>
|
||||
<div className='flex items-center gap-2'>
|
||||
@@ -171,7 +171,7 @@ const UserInfoHeader = ({ t, userState }) => {
|
||||
<Card
|
||||
size='small'
|
||||
className='!rounded-xl'
|
||||
bodyStyle={{ padding: '12px 16px' }}
|
||||
styles={{ body: { padding: '12px 16px' } }}
|
||||
>
|
||||
<div className='space-y-3'>
|
||||
<div className='flex items-center justify-between'>
|
||||
|
||||
@@ -173,7 +173,7 @@ const AccountBindingSection = ({
|
||||
) : null}
|
||||
</div>
|
||||
<div className='ui-settings-row-actions'>
|
||||
<AntTag bordered={false} color={bound ? 'success' : undefined}>
|
||||
<AntTag variant='filled' color={bound ? 'success' : undefined}>
|
||||
{bound ? t('已绑定') : t('未绑定')}
|
||||
</AntTag>
|
||||
<Button
|
||||
|
||||
@@ -52,7 +52,7 @@ const renderStatus = (status, record, t, showEnableDisableModal) => {
|
||||
}
|
||||
/>
|
||||
{meta && (
|
||||
<AntTag color={meta.color} bordered={false}>
|
||||
<AntTag color={meta.color} variant='filled'>
|
||||
{t(meta.label)}
|
||||
</AntTag>
|
||||
)}
|
||||
@@ -88,7 +88,7 @@ const renderKey = (text) => {
|
||||
const renderQuotaCell = (text, record, t) => {
|
||||
if (record.unlimited_quota) {
|
||||
return (
|
||||
<AntTag color='success' bordered={false}>
|
||||
<AntTag color='success' variant='filled'>
|
||||
{t('无限制')}
|
||||
</AntTag>
|
||||
);
|
||||
|
||||
@@ -211,11 +211,11 @@ const ModelTestModal = ({
|
||||
</div>
|
||||
) : null
|
||||
}
|
||||
maskClosable={!isBatchTesting}
|
||||
rootClassName='console-overlay model-test-modal'
|
||||
width={isMobile ? 'calc(100vw - 32px)' : 514.8}
|
||||
centered
|
||||
styles={{ body: { maxHeight: 'none', overflow: 'visible' } }}
|
||||
mask={{ closable: !isBatchTesting }}
|
||||
>
|
||||
{hasChannel && (
|
||||
<div className='model-test-content'>
|
||||
|
||||
@@ -239,7 +239,7 @@ const MarketCatalog = ({
|
||||
className='mm-scope-alert'
|
||||
type='warning'
|
||||
showIcon
|
||||
message={t(
|
||||
title={t(
|
||||
'以下价格已按所属企业的等级折扣展示;企业成员使用个人密钥或体验中心调用时同样按企业等级计费。',
|
||||
)}
|
||||
/>
|
||||
|
||||
@@ -138,7 +138,7 @@ const MarketModelCard = ({
|
||||
<h3 title={model.model_name}>{model.model_name}</h3>
|
||||
{model.level_locked && (
|
||||
<Tooltip title={t('当前等级无权调用此模型,升级等级后可用')}>
|
||||
<Tag icon={<Lock size={11} />} bordered={false}>
|
||||
<Tag icon={<Lock size={11} />} variant='filled'>
|
||||
{t('仅可见')}
|
||||
</Tag>
|
||||
</Tooltip>
|
||||
@@ -193,7 +193,7 @@ const MarketModelCard = ({
|
||||
'相比官方牌价的折扣,按当前计价分组实付价计算(已含您的等级折扣),仅供参考',
|
||||
)}
|
||||
>
|
||||
<Tag bordered={false}>{discountText}</Tag>
|
||||
<Tag variant='filled'>{discountText}</Tag>
|
||||
</Tooltip>
|
||||
) : (
|
||||
<span>{getBillingLabel(priceData, t)}</span>
|
||||
|
||||
@@ -187,9 +187,9 @@ const ModelMarketPage = () => {
|
||||
className='hidden'
|
||||
src={modalImageUrl}
|
||||
preview={{
|
||||
visible: isModalOpenurl,
|
||||
open: isModalOpenurl,
|
||||
src: modalImageUrl,
|
||||
onVisibleChange: (visible) => setIsModalOpenurl(visible),
|
||||
onOpenChange: (visible) => setIsModalOpenurl(visible),
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
|
||||
@@ -56,8 +56,7 @@ const ModelDetailSideSheet = ({
|
||||
title={t('模型详情')}
|
||||
open={visible}
|
||||
onClose={onClose}
|
||||
maskClosable
|
||||
width={isMobile ? '100%' : 820}
|
||||
size={isMobile ? '100%' : 820}
|
||||
rootClassName='mm-detail-drawer mm-theme'
|
||||
rootStyle={themeStyle}
|
||||
footer={
|
||||
@@ -67,6 +66,7 @@ const ModelDetailSideSheet = ({
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
{!modelData ? (
|
||||
<div className='mm-detail-loading'>
|
||||
|
||||
@@ -52,7 +52,7 @@ const ModelEndpoints = ({ modelData, endpointMap = {}, t }) => {
|
||||
<strong>{type}</strong>
|
||||
{path && <code>{path}</code>}
|
||||
</div>
|
||||
{path && <Tag bordered={false}>{method}</Tag>}
|
||||
{path && <Tag variant='filled'>{method}</Tag>}
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
|
||||
@@ -137,7 +137,7 @@ const ModelPricingTable = ({
|
||||
'相比官方牌价的折扣,按当前计价分组实付价计算(已含您的等级折扣),仅供参考',
|
||||
)}
|
||||
>
|
||||
<Tag bordered={false}>{row.discountText}</Tag>
|
||||
<Tag variant='filled'>{row.discountText}</Tag>
|
||||
</Tooltip>
|
||||
)}
|
||||
</span>
|
||||
@@ -236,7 +236,7 @@ const ModelPricingTable = ({
|
||||
<span>{t('auto分组调用链路')}</span>
|
||||
{autoChain.map((g, idx) => (
|
||||
<React.Fragment key={g}>
|
||||
<Tag bordered={false}>{g}</Tag>
|
||||
<Tag variant='filled'>{g}</Tag>
|
||||
{idx < autoChain.length - 1 && <ChevronRight size={12} />}
|
||||
</React.Fragment>
|
||||
))}
|
||||
|
||||
@@ -272,7 +272,7 @@ const RECORD_STATUS_COLORS = {
|
||||
|
||||
const recordTagFrom = (node, color) =>
|
||||
node?.props?.label !== undefined ? (
|
||||
<AntTag bordered={false} color={color}>
|
||||
<AntTag variant='filled' color={color}>
|
||||
{node.props.label}
|
||||
</AntTag>
|
||||
) : (
|
||||
@@ -324,7 +324,7 @@ const applyTaskRecordPresentation = (columns, { COLUMN_KEYS }) =>
|
||||
className='usage-record-copy-text'
|
||||
onClick={node.props.children.props.onClick}
|
||||
>
|
||||
<AntTag bordered={false}>{text}</AntTag>
|
||||
<AntTag variant='filled'>{text}</AntTag>
|
||||
</span>
|
||||
</Tooltip>
|
||||
);
|
||||
|
||||
@@ -94,7 +94,7 @@ const TaskLogsPage = ({
|
||||
{/* 只有真实存在进行中任务时才显示,避免误导 */}
|
||||
{pageStats.pendingCount > 0 && (
|
||||
<AntTag
|
||||
bordered={false}
|
||||
variant='filled'
|
||||
color='processing'
|
||||
icon={<Clock size={12} />}
|
||||
>
|
||||
|
||||
@@ -96,8 +96,7 @@ const EditTokenDrawer = ({
|
||||
open={open}
|
||||
onClose={onCancel}
|
||||
title={isEdit ? t('编辑密钥') : t('创建密钥')}
|
||||
width={isMobile ? '100%' : 560}
|
||||
maskClosable
|
||||
size={isMobile ? '100%' : 560}
|
||||
forceRender
|
||||
rootClassName='km-edit-drawer'
|
||||
footer={
|
||||
@@ -112,6 +111,7 @@ const EditTokenDrawer = ({
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
<Spin spinning={loading}>
|
||||
<Form
|
||||
|
||||
@@ -305,7 +305,7 @@ function renderRecordTime(text) {
|
||||
function renderRecordType(type, t) {
|
||||
const config = TYPE_CONFIG[type] || TYPE_CONFIG.default;
|
||||
return (
|
||||
<AntTag bordered={false} color={RECORD_TYPE_COLORS[type]}>
|
||||
<AntTag variant='filled' color={RECORD_TYPE_COLORS[type]}>
|
||||
{t(config.label)}
|
||||
</AntTag>
|
||||
);
|
||||
@@ -324,7 +324,7 @@ function renderRecordUseTime(record, t) {
|
||||
{useTime}
|
||||
{firstTime && <em>{firstTime}</em>}
|
||||
</span>
|
||||
<AntTag bordered={false} color={record.is_stream ? 'cyan' : undefined}>
|
||||
<AntTag variant='filled' color={record.is_stream ? 'cyan' : undefined}>
|
||||
{record.is_stream ? t('流') : t('非流')}
|
||||
</AntTag>
|
||||
</span>
|
||||
@@ -409,7 +409,7 @@ const applyUsageRecordPresentation = (
|
||||
const group =
|
||||
record.group || getLogOther(record.other)?.group || '';
|
||||
return group && node?.props?.children ? (
|
||||
<AntTag bordered={false}>{group}</AntTag>
|
||||
<AntTag variant='filled'>{group}</AntTag>
|
||||
) : null;
|
||||
},
|
||||
};
|
||||
|
||||
@@ -129,7 +129,7 @@ const PaymentConfirmModal = ({
|
||||
{renderAmount()}
|
||||
</strong>
|
||||
{hasDiscount && (
|
||||
<AntTag bordered={false} color='success'>
|
||||
<AntTag variant='filled' color='success'>
|
||||
{Math.round((1 - discountRate) * 100)}% OFF
|
||||
</AntTag>
|
||||
)}
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.payment-confirm-modal .ant-modal-content {
|
||||
.payment-confirm-modal .ant-modal-container {
|
||||
border-radius: 12px;
|
||||
padding: 20px 24px;
|
||||
}
|
||||
|
||||
@@ -39,6 +39,7 @@ import { useLocation } from 'react-router-dom';
|
||||
import { useActualTheme } from '../../context/Theme';
|
||||
import { normalizeLanguage } from '../../i18n/language';
|
||||
import { colord } from 'colord';
|
||||
import './antd-v5-compat.css';
|
||||
|
||||
// 与下方 Ant Design locale 一一对应的 dayjs 语言(未覆盖语言与 Ant Design 一样回退中文)。
|
||||
const DAYJS_LOCALES = {
|
||||
@@ -57,6 +58,17 @@ const DAYJS_LOCALES = {
|
||||
const PROTOTYPE_DARK_PRIMARY = '#d1963a';
|
||||
const PROTOTYPE_DARK_SEED = '#f2ad41';
|
||||
|
||||
// v5 used these shadows in both themes; v6 derives white shadows in dark mode.
|
||||
const v5ShadowTokens = {
|
||||
...Object.fromEntries(
|
||||
Object.entries(theme.getDesignToken()).filter(([name]) =>
|
||||
name.startsWith('boxShadow'),
|
||||
),
|
||||
),
|
||||
boxShadowTertiary:
|
||||
'0 1px 2px 0 rgba(0,0,0,0.03), 0 1px 6px -1px rgba(0,0,0,0.02), 0 2px 4px 0 rgba(0,0,0,0.02)',
|
||||
};
|
||||
|
||||
// 页面局部“品牌强调色”(原型 --brand):等于当前主题的种子色。
|
||||
// 浅色与自定义主色时即 colorPrimary;仅默认暗色主色 #d1963a 时回到原型种子 #f2ad41,
|
||||
// 保证浅色 / 深色 / 自定义主题色三态都只由主题 token 推导,不在页面里另写颜色。
|
||||
@@ -82,6 +94,7 @@ export const prototypeTheme = (dark) => ({
|
||||
};
|
||||
},
|
||||
token: {
|
||||
...v5ShadowTokens,
|
||||
colorPrimary: dark ? PROTOTYPE_DARK_PRIMARY : '#b96508',
|
||||
colorInfo: dark ? PROTOTYPE_DARK_PRIMARY : '#b96508',
|
||||
colorBgLayout: dark ? '#11151c' : '#f4f6f9',
|
||||
@@ -108,6 +121,13 @@ export const prototypeTheme = (dark) => ({
|
||||
},
|
||||
});
|
||||
|
||||
// Keep v5 tag borders and overlay masks while inheriting the existing theme.
|
||||
const v5ComponentDefaults = {
|
||||
tag: { variant: 'outlined' },
|
||||
modal: { mask: { blur: false } },
|
||||
drawer: { mask: { blur: false } },
|
||||
};
|
||||
|
||||
function TokenBridge() {
|
||||
const { token } = theme.useToken();
|
||||
useLayoutEffect(() => {
|
||||
@@ -249,14 +269,14 @@ export default function UiThemeProvider({ children }) {
|
||||
useEffect(() => {
|
||||
ConfigProvider.config({
|
||||
holderRender: (nodes) => (
|
||||
<ConfigProvider theme={config} locale={locale}>
|
||||
<ConfigProvider {...v5ComponentDefaults} theme={config} locale={locale}>
|
||||
{nodes}
|
||||
</ConfigProvider>
|
||||
),
|
||||
});
|
||||
}, [config, locale]);
|
||||
return (
|
||||
<ConfigProvider theme={config} locale={locale}>
|
||||
<ConfigProvider {...v5ComponentDefaults} theme={config} locale={locale}>
|
||||
<App>
|
||||
<TokenBridge />
|
||||
{children}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/* Keep v5 spacing at component specificity so page overrides still take priority. */
|
||||
:where(body[data-ui-scope='admin']) .ant-tag {
|
||||
margin-inline-end: 8px;
|
||||
}
|
||||
|
||||
/* The v6 suffix layout makes automatic pagination selects 3px narrower. */
|
||||
:where(body[data-ui-scope='admin'])
|
||||
.ant-pagination-options-size-changer
|
||||
.ant-select-suffix {
|
||||
margin-inline-start: 3px;
|
||||
}
|
||||
|
||||
/* v6 changed the required-mark font; retain v5 label metrics and form spacing. */
|
||||
body[data-ui-scope='admin']
|
||||
.ant-form-item-label
|
||||
> label.ant-form-item-required::before {
|
||||
font-family: SimSun, sans-serif;
|
||||
}
|
||||
@@ -129,7 +129,7 @@ export const Button = forwardRef(function Button(
|
||||
danger={danger}
|
||||
size={useConsoleControlSize(size)}
|
||||
shape={circle ? 'circle' : undefined}
|
||||
iconPosition={iconPosition === 'right' ? 'end' : 'start'}
|
||||
iconPlacement={iconPosition === 'right' ? 'end' : 'start'}
|
||||
/>
|
||||
);
|
||||
});
|
||||
@@ -193,6 +193,10 @@ export function Select({
|
||||
prefix,
|
||||
dropdownStyle,
|
||||
dropdownClassName,
|
||||
autoClearSearchValue,
|
||||
onSearch,
|
||||
searchValue,
|
||||
filterSort,
|
||||
...props
|
||||
}) {
|
||||
const canSearch =
|
||||
@@ -210,28 +214,39 @@ export function Select({
|
||||
}
|
||||
styles={{
|
||||
...props.styles,
|
||||
popup: { ...props.styles?.popup, root: dropdownStyle },
|
||||
popup: {
|
||||
...props.styles?.popup,
|
||||
root: dropdownStyle ?? props.styles?.popup?.root,
|
||||
},
|
||||
}}
|
||||
classNames={{
|
||||
...props.classNames,
|
||||
popup: { ...props.classNames?.popup, root: dropdownClassName },
|
||||
popup: {
|
||||
...props.classNames?.popup,
|
||||
root: dropdownClassName ?? props.classNames?.popup?.root,
|
||||
},
|
||||
}}
|
||||
options={optionList || options}
|
||||
allowClear={showClear ?? props.allowClear}
|
||||
showSearch={canSearch}
|
||||
filterOption={
|
||||
remote
|
||||
showSearch={{
|
||||
enabled: canSearch,
|
||||
filterOption: remote
|
||||
? false
|
||||
: typeof filter === 'function'
|
||||
? filter
|
||||
: filter === false
|
||||
? false
|
||||
: undefined
|
||||
}
|
||||
optionFilterProp='label'
|
||||
: undefined,
|
||||
optionFilterProp: 'label',
|
||||
...(typeof props.showSearch === 'object' ? props.showSearch : {}),
|
||||
...(autoClearSearchValue !== undefined ? { autoClearSearchValue } : {}),
|
||||
...(onSearch !== undefined ? { onSearch } : {}),
|
||||
...(searchValue !== undefined ? { searchValue } : {}),
|
||||
...(filterSort !== undefined ? { filterSort } : {}),
|
||||
}}
|
||||
notFoundContent={emptyContent}
|
||||
status={statusOf(validateStatus)}
|
||||
onOpenChange={onDropdownVisibleChange}
|
||||
onOpenChange={onDropdownVisibleChange ?? props.onOpenChange}
|
||||
prefix={prefix}
|
||||
popupRender={
|
||||
outerBottomSlot || innerBottomSlot
|
||||
@@ -348,7 +363,7 @@ export function Switch({
|
||||
{...props}
|
||||
checkedChildren={checkedText}
|
||||
unCheckedChildren={uncheckedText}
|
||||
size={size === 'small' ? 'small' : 'default'}
|
||||
size={size === 'small' ? 'small' : 'medium'}
|
||||
/>
|
||||
);
|
||||
}
|
||||
@@ -369,6 +384,8 @@ export function DatePicker({
|
||||
presets,
|
||||
size,
|
||||
inputReadOnly,
|
||||
dropdownClassName,
|
||||
dropdownStyle,
|
||||
...props
|
||||
}) {
|
||||
const range = type?.toLowerCase().includes('range');
|
||||
@@ -377,6 +394,20 @@ export function DatePicker({
|
||||
return (
|
||||
<Component
|
||||
{...props}
|
||||
classNames={{
|
||||
...props.classNames,
|
||||
popup: {
|
||||
...props.classNames?.popup,
|
||||
root: dropdownClassName ?? props.classNames?.popup?.root,
|
||||
},
|
||||
}}
|
||||
styles={{
|
||||
...props.styles,
|
||||
popup: {
|
||||
...props.styles?.popup,
|
||||
root: dropdownStyle ?? props.styles?.popup?.root,
|
||||
},
|
||||
}}
|
||||
{...(value !== undefined ? { value: convert(value) } : {})}
|
||||
defaultValue={
|
||||
defaultValue === undefined ? undefined : convert(defaultValue)
|
||||
@@ -426,11 +457,13 @@ export function TreeSelect({
|
||||
{...props}
|
||||
treeData={treeNodes(treeData)}
|
||||
allowClear={showClear}
|
||||
showSearch={!!filterTreeNode}
|
||||
treeNodeFilterProp='title'
|
||||
filterTreeNode={
|
||||
typeof filterTreeNode === 'function' ? filterTreeNode : undefined
|
||||
}
|
||||
showSearch={{
|
||||
enabled: !!filterTreeNode,
|
||||
filterTreeNode:
|
||||
typeof filterTreeNode === 'function' ? filterTreeNode : undefined,
|
||||
treeNodeFilterProp: 'title',
|
||||
...(typeof props.showSearch === 'object' ? props.showSearch : {}),
|
||||
}}
|
||||
treeDefaultExpandAll={expandAll}
|
||||
/>
|
||||
);
|
||||
@@ -461,12 +494,19 @@ export function AutoComplete({
|
||||
renderItem,
|
||||
emptyContent,
|
||||
onEnterPress,
|
||||
onSearch,
|
||||
showSearch,
|
||||
size,
|
||||
...props
|
||||
}) {
|
||||
return (
|
||||
<AntAutoComplete
|
||||
{...props}
|
||||
showSearch={
|
||||
onSearch
|
||||
? { ...(typeof showSearch === 'object' ? showSearch : {}), onSearch }
|
||||
: showSearch
|
||||
}
|
||||
options={data?.map((item) =>
|
||||
typeof item === 'string' ? { value: item } : item,
|
||||
)}
|
||||
|
||||
+55
-23
@@ -27,7 +27,7 @@ import {
|
||||
paginationEvents,
|
||||
paginationShowTotal,
|
||||
} from './pagination';
|
||||
import { overlayMaskClosable } from './overlayPolicy';
|
||||
import { overlayMask } from './overlayPolicy';
|
||||
import './pagination.css';
|
||||
import { useIsMobile } from '../../hooks/common/useIsMobile';
|
||||
import { useConsolePage } from '../console/ConsoleContext';
|
||||
@@ -132,7 +132,7 @@ export const Card = forwardRef(function Card(
|
||||
variant={
|
||||
props.variant ?? (bordered === false ? 'borderless' : 'outlined')
|
||||
}
|
||||
size={size === 'small' ? 'small' : 'default'}
|
||||
size={size === 'small' ? 'small' : 'medium'}
|
||||
title={
|
||||
props.title ??
|
||||
header?.title ??
|
||||
@@ -141,7 +141,7 @@ export const Card = forwardRef(function Card(
|
||||
: undefined)
|
||||
}
|
||||
extra={headerExtraContent ?? header?.extra}
|
||||
styles={{ header: headerStyle, body: bodyStyle }}
|
||||
styles={{ header: headerStyle, body: bodyStyle, ...props.styles }}
|
||||
>
|
||||
{props.children}
|
||||
{footer && <div className='ui-card-footer'>{footer}</div>}
|
||||
@@ -151,15 +151,15 @@ export const Card = forwardRef(function Card(
|
||||
export const Space = ({ spacing, vertical, size, ...props }) => (
|
||||
<Ant.Space
|
||||
{...props}
|
||||
direction={vertical ? 'vertical' : 'horizontal'}
|
||||
orientation={vertical ? 'vertical' : 'horizontal'}
|
||||
size={spacing === 'medium' ? 'middle' : (spacing ?? size)}
|
||||
/>
|
||||
);
|
||||
export const Divider = ({ margin, align, layout, style, ...props }) => (
|
||||
<Ant.Divider
|
||||
{...props}
|
||||
orientation={align}
|
||||
type={layout === 'vertical' ? 'vertical' : 'horizontal'}
|
||||
titlePlacement={align}
|
||||
orientation={layout === 'vertical' ? 'vertical' : 'horizontal'}
|
||||
style={{ margin, ...style }}
|
||||
/>
|
||||
);
|
||||
@@ -174,6 +174,7 @@ export const Tag = forwardRef(function Tag(
|
||||
prefix,
|
||||
children,
|
||||
color,
|
||||
bordered,
|
||||
...props
|
||||
},
|
||||
ref,
|
||||
@@ -182,6 +183,7 @@ export const Tag = forwardRef(function Tag(
|
||||
<Ant.Tag
|
||||
{...props}
|
||||
ref={ref}
|
||||
variant={props.variant ?? (bordered === false ? 'filled' : 'outlined')}
|
||||
color={
|
||||
['white', 'grey', 'light-blue', 'light-green'].includes(color)
|
||||
? {
|
||||
@@ -231,6 +233,8 @@ export const Spin = ({
|
||||
style,
|
||||
className,
|
||||
'data-testid': testId,
|
||||
tip,
|
||||
wrapperClassName,
|
||||
...props
|
||||
}) =>
|
||||
children ? (
|
||||
@@ -239,14 +243,20 @@ export const Spin = ({
|
||||
className={`ui-spin-shell ${className || ''}`}
|
||||
data-testid={testId}
|
||||
>
|
||||
<Ant.Spin {...props} size={controlSize(size)}>
|
||||
<Ant.Spin
|
||||
{...props}
|
||||
description={tip ?? props.description}
|
||||
classNames={{ root: wrapperClassName, ...props.classNames }}
|
||||
size={size === 'default' ? 'medium' : size}
|
||||
>
|
||||
<div style={childStyle}>{children}</div>
|
||||
</Ant.Spin>
|
||||
</div>
|
||||
) : (
|
||||
<Ant.Spin
|
||||
{...props}
|
||||
size={controlSize(size)}
|
||||
size={size === 'default' ? 'medium' : size}
|
||||
description={tip ?? props.description}
|
||||
style={style}
|
||||
className={className}
|
||||
data-testid={testId}
|
||||
@@ -556,8 +566,8 @@ export const Timeline = Object.assign(
|
||||
.filter(React.isValidElement)
|
||||
.map((child) => ({
|
||||
color: child.props.type === 'ongoing' ? 'blue' : undefined,
|
||||
label: child.props.time,
|
||||
children: (
|
||||
title: child.props.time,
|
||||
content: (
|
||||
<>
|
||||
{child.props.children}
|
||||
{child.props.extra}
|
||||
@@ -634,7 +644,7 @@ export const Banner = ({
|
||||
return (
|
||||
<Component
|
||||
{...props}
|
||||
message={title}
|
||||
title={title}
|
||||
type={type === 'danger' ? 'error' : type}
|
||||
showIcon
|
||||
closable={!!closeIcon}
|
||||
@@ -642,9 +652,9 @@ export const Banner = ({
|
||||
/>
|
||||
);
|
||||
};
|
||||
export const Alert = (props) => {
|
||||
export const Alert = ({ message, ...props }) => {
|
||||
const Component = useConsolePage() ? ConsoleAlert : Ant.Alert;
|
||||
return <Component {...props} />;
|
||||
return <Component {...props} title={props.title ?? message} />;
|
||||
};
|
||||
|
||||
function modalProps({
|
||||
@@ -659,20 +669,23 @@ function modalProps({
|
||||
type,
|
||||
bodyStyle,
|
||||
maskStyle,
|
||||
mask,
|
||||
maskClosable,
|
||||
destroyOnClose,
|
||||
...props
|
||||
}) {
|
||||
return {
|
||||
...props,
|
||||
maskClosable: overlayMaskClosable(props.maskClosable),
|
||||
mask: overlayMask(mask, maskClosable),
|
||||
open: visible,
|
||||
title: header === null ? null : (props.title ?? header),
|
||||
keyboard: closeOnEsc,
|
||||
forceRender: lazyRender === false,
|
||||
destroyOnHidden: keepDOM === false || destroyOnClose,
|
||||
destroyOnHidden:
|
||||
keepDOM === false || destroyOnClose || props.destroyOnHidden,
|
||||
width: size === 'full-width' ? '100%' : props.width,
|
||||
okButtonProps: { danger: okType === 'danger', ...props.okButtonProps },
|
||||
styles: { body: bodyStyle, mask: maskStyle },
|
||||
styles: { body: bodyStyle, mask: maskStyle, ...props.styles },
|
||||
};
|
||||
}
|
||||
export const Modal = Object.assign(
|
||||
@@ -702,18 +715,31 @@ export const SideSheet = ({
|
||||
headerStyle,
|
||||
maskStyle,
|
||||
destroyOnClose,
|
||||
mask,
|
||||
maskClosable,
|
||||
width,
|
||||
height,
|
||||
...props
|
||||
}) => {
|
||||
const Component = useConsolePage() ? ConsoleDrawer : Ant.Drawer;
|
||||
return (
|
||||
<Component
|
||||
{...props}
|
||||
maskClosable={overlayMaskClosable(props.maskClosable)}
|
||||
mask={overlayMask(mask, maskClosable)}
|
||||
size={
|
||||
props.size ??
|
||||
(['top', 'bottom'].includes(props.placement) ? height : width)
|
||||
}
|
||||
open={visible}
|
||||
onClose={onCancel}
|
||||
keyboard={closeOnEsc}
|
||||
destroyOnHidden={destroyOnClose}
|
||||
styles={{ body: bodyStyle, header: headerStyle, mask: maskStyle }}
|
||||
destroyOnHidden={destroyOnClose ?? props.destroyOnHidden}
|
||||
styles={{
|
||||
body: bodyStyle,
|
||||
header: headerStyle,
|
||||
mask: maskStyle,
|
||||
...props.styles,
|
||||
}}
|
||||
/>
|
||||
);
|
||||
};
|
||||
@@ -727,7 +753,12 @@ export const ImagePreview = ({
|
||||
}) => (
|
||||
<Ant.Image.PreviewGroup
|
||||
items={Array.isArray(src) ? src : [src]}
|
||||
preview={{ visible, onVisibleChange, current: currentIndex, onChange }}
|
||||
preview={{
|
||||
open: visible,
|
||||
onOpenChange: onVisibleChange,
|
||||
current: currentIndex,
|
||||
onChange,
|
||||
}}
|
||||
/>
|
||||
);
|
||||
|
||||
@@ -747,11 +778,12 @@ Toast.destroyAll = Ant.message.destroy;
|
||||
export const Notification = Object.fromEntries(
|
||||
['success', 'info', 'warning', 'error', 'open'].map((method) => [
|
||||
method,
|
||||
(config) =>
|
||||
({ title, message, content, description, btn, actions, ...config }) =>
|
||||
Ant.notification[method]({
|
||||
...config,
|
||||
message: config.title ?? config.message,
|
||||
description: config.content ?? config.description,
|
||||
title: title ?? message,
|
||||
description: content ?? description,
|
||||
actions: actions ?? btn,
|
||||
}),
|
||||
]),
|
||||
);
|
||||
|
||||
@@ -32,3 +32,16 @@ export function overlayMaskClosable(
|
||||
pathname.startsWith('/user-center/');
|
||||
return scoped ? true : configured;
|
||||
}
|
||||
|
||||
export function overlayMask(mask, maskClosable, pathname) {
|
||||
const config =
|
||||
typeof mask === 'object' && mask !== null
|
||||
? mask
|
||||
: mask === undefined
|
||||
? {}
|
||||
: { enabled: mask };
|
||||
return {
|
||||
...config,
|
||||
closable: overlayMaskClosable(config.closable ?? maskClosable, pathname),
|
||||
};
|
||||
}
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "Please enter the account number",
|
||||
"请输入折扣率": "Please enter a discount rate",
|
||||
"请输入整数": "Enter an integer",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "The quantity cannot exceed 10000. It has been adjusted to 10000.",
|
||||
"请输入整数,如 1、5、10": "Enter an integer, e.g. 1, 5, 10",
|
||||
"请输入证书序列号": "Enter the certificate serial number",
|
||||
"请输入支付宝应用 ID": "Enter Alipay App ID",
|
||||
|
||||
@@ -4204,6 +4204,7 @@
|
||||
"请输入原密码和新密码": "",
|
||||
"请输入账号": "",
|
||||
"请输入折扣率": "Please enter a discount rate",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "La quantité ne peut pas dépasser 10000. Elle a été ramenée à 10000.",
|
||||
"请输入整数,如 1、5、10": "",
|
||||
"请输入证书序列号": "",
|
||||
"请输入支付宝应用 ID": "",
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "口座番号を入力してください",
|
||||
"请输入折扣率": "割引率を入力してください",
|
||||
"请输入整数": "整数を入力してください",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "入力数量の上限は10000です。10000に自動調整しました。",
|
||||
"请输入整数,如 1、5、10": "整数を入力してください(例:1、5、10)",
|
||||
"请输入证书序列号": "証明書のシリアル番号を入力してください",
|
||||
"请输入支付宝应用 ID": "Alipay アプリ ID を入力してください",
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "계좌번호를 입력하세요",
|
||||
"请输入折扣率": "할인율을 입력하세요",
|
||||
"请输入整数": "정수를 입력하세요",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "입력 수량은 10000을 초과할 수 없습니다. 10000으로 자동 조정되었습니다.",
|
||||
"请输入整数,如 1、5、10": "정수를 입력하세요. 예: 1, 5, 10",
|
||||
"请输入证书序列号": "인증서 일련번호를 입력하세요",
|
||||
"请输入支付宝应用 ID": "Alipay 앱 ID를 입력하세요",
|
||||
|
||||
@@ -4236,6 +4236,7 @@
|
||||
"请输入原密码和新密码": "",
|
||||
"请输入账号": "",
|
||||
"请输入折扣率": "Please enter a discount rate",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "Количество не может превышать 10000. Установлено значение 10000.",
|
||||
"请输入整数,如 1、5、10": "",
|
||||
"请输入证书序列号": "",
|
||||
"请输入支付宝应用 ID": "",
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "โปรดกรอกเลขที่บัญชี",
|
||||
"请输入折扣率": "โปรดกรอกอัตราส่วนลด",
|
||||
"请输入整数": "โปรดกรอกจำนวนเต็ม",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "จำนวนต้องไม่เกิน 10000 ระบบปรับเป็น 10000 แล้ว",
|
||||
"请输入整数,如 1、5、10": "กรอกจำนวนเต็ม เช่น 1, 5, 10",
|
||||
"请输入证书序列号": "กรอกหมายเลขซีเรียลของใบรับรอง",
|
||||
"请输入支付宝应用 ID": "กรอก App ID ของ Alipay",
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "Vui lòng nhập tài khoản",
|
||||
"请输入折扣率": "Vui lòng nhập tỷ lệ chiết khấu",
|
||||
"请输入整数": "Vui lòng nhập số nguyên",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "Số lượng không được vượt quá 10000. Đã tự động điều chỉnh thành 10000.",
|
||||
"请输入整数,如 1、5、10": "Vui lòng nhập số nguyên, ví dụ 1, 5, 10",
|
||||
"请输入证书序列号": "Vui lòng nhập số sê-ri chứng chỉ",
|
||||
"请输入支付宝应用 ID": "Vui lòng nhập ID ứng dụng Alipay",
|
||||
|
||||
@@ -4403,6 +4403,7 @@
|
||||
"请输入账号": "請輸入帳號",
|
||||
"请输入折扣率": "請輸入折扣率",
|
||||
"请输入整数": "請輸入整數",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "輸入數量不能超過 10000,已自動調整為 10000",
|
||||
"请输入整数,如 1、5、10": "請輸入整數,如 1、5、10",
|
||||
"请输入证书序列号": "請輸入證書序列號",
|
||||
"请输入支付宝应用 ID": "請輸入支付寶應用 ID",
|
||||
|
||||
@@ -4351,6 +4351,7 @@
|
||||
"请输入账号": "请输入账号",
|
||||
"请输入折扣率": "请输入折扣率",
|
||||
"请输入整数": "请输入整数",
|
||||
"输入数量不能超过 10000,已自动调整为 10000": "输入数量不能超过 10000,已自动调整为 10000",
|
||||
"请输入整数,如 1、5、10": "请输入整数,如 1、5、10",
|
||||
"请输入证书序列号": "请输入证书序列号",
|
||||
"请输入支付宝应用 ID": "请输入支付宝应用 ID",
|
||||
|
||||
@@ -147,7 +147,7 @@ const ImageDetailModal = ({
|
||||
footer={
|
||||
// wrap 必须开:三个中文按钮(用作参考图/在此基础上微调/下载图片)合计 ~370px,
|
||||
// 而 modalWidth 是 viewportWidth-48,390px 屏上扣掉 content 的 padding 只剩 ~294px。
|
||||
// Space 默认 wrap:false + .ant-modal-content{overflow:hidden},
|
||||
// Space 默认 wrap:false + .ant-modal-container{overflow:hidden},
|
||||
// 溢出部分向左溢出并被裁掉 —— 「用作参考图」整个点不到。
|
||||
<Space wrap style={{ justifyContent: 'flex-end', width: '100%' }}>
|
||||
{onUseAsReference && task.imageUrl && (
|
||||
|
||||
@@ -926,10 +926,10 @@ const ImageTaskList = ({
|
||||
<Image
|
||||
src={previewImageUrl}
|
||||
preview={{
|
||||
visible: previewVisible,
|
||||
open: previewVisible,
|
||||
src: previewImageUrl,
|
||||
onDownload: handlePreviewDownload,
|
||||
onVisibleChange: (visible) => {
|
||||
onOpenChange: (visible) => {
|
||||
setPreviewVisible(visible);
|
||||
if (!visible) {
|
||||
setPreviewImageUrl('');
|
||||
|
||||
@@ -208,6 +208,6 @@
|
||||
padding: 12px 16px;
|
||||
}
|
||||
|
||||
.vip-advanced .ant-collapse-content-box {
|
||||
.vip-advanced .ant-collapse-body {
|
||||
padding: 4px 16px 16px;
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ const VideoModelPanel = ({
|
||||
<Card
|
||||
title={t('选择模型')}
|
||||
style={{ marginBottom: '16px' }}
|
||||
bodyStyle={{ padding: '12px' }}
|
||||
styles={{ body: { padding: '12px' } }}
|
||||
>
|
||||
<ModelSelector
|
||||
key={mode}
|
||||
@@ -74,7 +74,7 @@ const VideoModelPanel = ({
|
||||
<Card
|
||||
title={t('模型信息')}
|
||||
style={{ marginBottom: '16px' }}
|
||||
bodyStyle={{ padding: '12px' }}
|
||||
styles={{ body: { padding: '12px' } }}
|
||||
>
|
||||
<Space vertical spacing='medium' style={{ width: '100%' }}>
|
||||
{/* 厂商 */}
|
||||
@@ -125,7 +125,7 @@ const VideoModelPanel = ({
|
||||
<span>{t('模型价格')}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '12px' }}
|
||||
styles={{ body: { padding: '12px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
|
||||
@@ -889,12 +889,14 @@ const VideoPreviewPanel = ({
|
||||
return (
|
||||
<Card
|
||||
style={{ height: '100%', display: 'flex', flexDirection: 'column' }}
|
||||
bodyStyle={{
|
||||
flex: 1,
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
overflow: 'hidden',
|
||||
padding: 0,
|
||||
styles={{
|
||||
body: {
|
||||
flex: 1,
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
overflow: 'hidden',
|
||||
padding: 0,
|
||||
},
|
||||
}}
|
||||
>
|
||||
{/* 始终显示的顶部操作栏 */}
|
||||
|
||||
@@ -173,7 +173,7 @@ const KeyTable = ({
|
||||
: group
|
||||
}
|
||||
>
|
||||
<Tag color='blue' bordered={false}>
|
||||
<Tag color='blue' variant='filled'>
|
||||
{group === 'auto' ? t('智能熔断') : group || t('默认')}
|
||||
</Tag>
|
||||
</Tooltip>
|
||||
@@ -196,7 +196,7 @@ const KeyTable = ({
|
||||
onChange={() => onToggle(token)}
|
||||
/>
|
||||
{extra ? (
|
||||
<Tag color={extra.color} bordered={false}>
|
||||
<Tag color={extra.color} variant='filled'>
|
||||
{t(extra.label)}
|
||||
</Tag>
|
||||
) : null}
|
||||
@@ -220,7 +220,7 @@ const KeyTable = ({
|
||||
key: 'quota',
|
||||
render: (_, token) =>
|
||||
token.unlimited_quota === true || token.remain_quota < 0 ? (
|
||||
<Tag color='success' bordered={false}>
|
||||
<Tag color='success' variant='filled'>
|
||||
{t('无限制')}
|
||||
</Tag>
|
||||
) : (
|
||||
@@ -319,10 +319,10 @@ const DesensitizeNotice = ({ t }) => {
|
||||
type='success'
|
||||
showIcon
|
||||
icon={<ShieldCheck size={18} />}
|
||||
message={
|
||||
title={
|
||||
<>
|
||||
{t('您的敏感数据已自动脱敏保护')}{' '}
|
||||
<Tag color='success' bordered={false}>
|
||||
<Tag color='success' variant='filled'>
|
||||
{t('已开启')}
|
||||
</Tag>
|
||||
</>
|
||||
@@ -412,10 +412,10 @@ const ModelsDrawer = ({ visible, onClose, token, t }) => {
|
||||
title={t('可用模型列表')}
|
||||
open={visible}
|
||||
onClose={onClose}
|
||||
maskClosable
|
||||
placement='right'
|
||||
width={440}
|
||||
size={440}
|
||||
rootClassName='km-models-drawer'
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
<dl className='km-models-info'>
|
||||
<dt>{t('密钥名称')}</dt>
|
||||
@@ -452,7 +452,7 @@ const ModelsDrawer = ({ visible, onClose, token, t }) => {
|
||||
{categoryModels.map((model) => (
|
||||
<Tooltip key={model} title={t('点击复制模型名称')}>
|
||||
<Tag
|
||||
bordered={false}
|
||||
variant='filled'
|
||||
className='km-model-chip'
|
||||
role='button'
|
||||
tabIndex={0}
|
||||
|
||||
@@ -74,7 +74,7 @@ const LogoShowcase = () => {
|
||||
<Card
|
||||
key={style.name}
|
||||
className='overflow-hidden shadow-lg hover:shadow-2xl transition-all duration-300 hover:scale-105'
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
<div
|
||||
className='flex flex-col items-center justify-center p-12'
|
||||
|
||||
@@ -133,7 +133,7 @@ const AdminMonitor = () => {
|
||||
borderRadius: '12px',
|
||||
height: '100%',
|
||||
}}
|
||||
bodyStyle={{ padding: '24px' }}
|
||||
styles={{ body: { padding: '24px' } }}
|
||||
>
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: '16px' }}>
|
||||
<div
|
||||
@@ -665,7 +665,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('请求趋势')} (24h)</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{renderBarChart(
|
||||
data.requestTrend,
|
||||
@@ -684,7 +684,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('成本分布')}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{renderDonutChart(data.costDistribution)}
|
||||
</Card>
|
||||
@@ -700,7 +700,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('Token消耗趋势')} (24h)</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{renderStackedAreaChart(data.tokenTrend)}
|
||||
</Card>
|
||||
@@ -716,7 +716,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('配额使用情况')}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{renderGaugeChart(data.quotaUsage)}
|
||||
</Card>
|
||||
@@ -735,7 +735,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('错误类型分布')} (24h)</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{renderHorizontalBar(data.errorTypes)}
|
||||
</Card>
|
||||
@@ -754,7 +754,7 @@ const AdminMonitor = () => {
|
||||
<span>{t('渠道详细数据')}</span>
|
||||
</div>
|
||||
}
|
||||
bodyStyle={{ padding: 0 }}
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
<Table
|
||||
columns={columns}
|
||||
|
||||
@@ -328,8 +328,8 @@ const ChannelMonitor = () => {
|
||||
<Col key={channel.id} xs={24} sm={12} lg={8} xl={6}>
|
||||
<Card
|
||||
className='channel-card'
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
style={{ height: '100%' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
{/* 渠道名称和状态 */}
|
||||
<div style={{ marginBottom: '16px' }}>
|
||||
|
||||
@@ -152,7 +152,6 @@ const ChannelMonitorView = ({ channelStatus, onRefresh }) => {
|
||||
</div>
|
||||
}
|
||||
headerStyle={{ borderBottom: '2px solid #f0f0f0' }}
|
||||
bodyStyle={{ padding: 16 }}
|
||||
style={{
|
||||
height: '100%',
|
||||
border: `2px solid ${
|
||||
@@ -163,6 +162,7 @@ const ChannelMonitorView = ({ channelStatus, onRefresh }) => {
|
||||
: '#faad1420'
|
||||
}`,
|
||||
}}
|
||||
styles={{ body: { padding: 16 } }}
|
||||
>
|
||||
{/* 1. 渠道状态 */}
|
||||
<div style={{ marginBottom: 16 }}>
|
||||
|
||||
@@ -716,7 +716,7 @@ const OrgMembers = ({
|
||||
className='oc-block-gap'
|
||||
type='info'
|
||||
showIcon
|
||||
message={t(
|
||||
title={t(
|
||||
'当前企业仅有您一位成员。为员工创建成员账号后,即可在此管理成员角色、额度上限和访问权限。',
|
||||
)}
|
||||
/>
|
||||
|
||||
@@ -363,7 +363,7 @@ const OrgPersonalSettings = ({ orgId }) => {
|
||||
</>
|
||||
) : (
|
||||
<div className='oc-ps-unlimited'>
|
||||
<AntTag color='gold' bordered={false}>
|
||||
<AntTag color='gold' variant='filled'>
|
||||
{t('不限额')}
|
||||
</AntTag>
|
||||
<span>{t('企业未对你设置配额上限')}</span>
|
||||
@@ -450,7 +450,7 @@ const OrgPersonalSettings = ({ orgId }) => {
|
||||
<div className='ui-profile-meta'>
|
||||
<div className='ui-profile-name'>
|
||||
<strong>{displayName || t('未设置')}</strong>
|
||||
<AntTag color='gold' bordered={false}>
|
||||
<AntTag color='gold' variant='filled'>
|
||||
{roleLabel(t, member.role)}
|
||||
</AntTag>
|
||||
</div>
|
||||
|
||||
@@ -20,17 +20,14 @@ import { Check as ActionCheck } from '@/components/common/icons/ActionIcons';
|
||||
import React, { useEffect, useState, useCallback, useMemo } from 'react';
|
||||
import { timestamp2string } from '../../helpers/utils';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import {
|
||||
Typography,
|
||||
Button,
|
||||
Spin,
|
||||
Table,
|
||||
Tag,
|
||||
InputNumber,
|
||||
Select,
|
||||
} from '@/components/ui';
|
||||
import { useThrottledCallback } from 'use-debounce';
|
||||
import { Typography, Button, Spin, Table, Tag, Select } from '@/components/ui';
|
||||
import { CheckCircle, Clock, XCircle } from 'lucide-react';
|
||||
import { Button as AntButton } from 'antd';
|
||||
import { Button as AntButton, Input as AntInput } from 'antd';
|
||||
import {
|
||||
MAX_CUSTOM_AMOUNT,
|
||||
normalizeCustomAmount,
|
||||
} from './customRechargeAmount';
|
||||
import {
|
||||
API,
|
||||
showError,
|
||||
@@ -82,6 +79,17 @@ const OrgRecharge = ({ orgId }) => {
|
||||
// 自定义充值(与预设档位互斥;自定义金额无折扣,原价到账)
|
||||
const [isCustomMode, setIsCustomMode] = useState(false);
|
||||
const [customAmount, setCustomAmount] = useState(null);
|
||||
const [customAmountExceeded, setCustomAmountExceeded] = useState(false);
|
||||
// Clamp the amount immediately; throttle feedback so payment state never lags.
|
||||
const reportCustomAmountExceeded = useThrottledCallback(
|
||||
() => setCustomAmountExceeded(true),
|
||||
200,
|
||||
{ leading: false, trailing: true },
|
||||
);
|
||||
const clearCustomAmountError = () => {
|
||||
reportCustomAmountExceeded.cancel();
|
||||
setCustomAmountExceeded(false);
|
||||
};
|
||||
const [customUnit, setCustomUnit] = useState(1000); // 1000=千 / 10000=万
|
||||
|
||||
const customEffectiveAmount = useMemo(() => {
|
||||
@@ -89,7 +97,11 @@ const OrgRecharge = ({ orgId }) => {
|
||||
return Math.floor(Number(customAmount)) * customUnit;
|
||||
}, [customAmount, customUnit]);
|
||||
|
||||
const customValid = customEffectiveAmount >= 1000;
|
||||
const customValid =
|
||||
Number.isInteger(customAmount) &&
|
||||
customAmount >= 1 &&
|
||||
customAmount <= MAX_CUSTOM_AMOUNT &&
|
||||
customEffectiveAmount >= 1000;
|
||||
|
||||
// 当前生效的金额/折扣/赠送(自定义优先)
|
||||
const effectiveAmountYuan = isCustomMode
|
||||
@@ -239,6 +251,7 @@ const OrgRecharge = ({ orgId }) => {
|
||||
}, []);
|
||||
|
||||
const selectPreset = (preset) => {
|
||||
clearCustomAmountError();
|
||||
setSelectedPreset(preset.id);
|
||||
setSelectedPresetObj(preset);
|
||||
setIsCustomMode(false);
|
||||
@@ -246,8 +259,15 @@ const OrgRecharge = ({ orgId }) => {
|
||||
};
|
||||
|
||||
const handleCustomAmountChange = (v) => {
|
||||
setCustomAmount(v);
|
||||
if (v && Number(v) > 0) {
|
||||
const result = normalizeCustomAmount(v);
|
||||
if (!result) return;
|
||||
if (result.exceeded) {
|
||||
reportCustomAmountExceeded();
|
||||
} else {
|
||||
clearCustomAmountError();
|
||||
}
|
||||
setCustomAmount(result.value);
|
||||
if (result.value) {
|
||||
setIsCustomMode(true);
|
||||
setSelectedPreset(null);
|
||||
setSelectedPresetObj(null);
|
||||
@@ -275,6 +295,7 @@ const OrgRecharge = ({ orgId }) => {
|
||||
];
|
||||
|
||||
const applyCustomQuickPick = (amount, unit) => {
|
||||
clearCustomAmountError();
|
||||
setCustomAmount(amount);
|
||||
setCustomUnit(unit);
|
||||
setIsCustomMode(true);
|
||||
@@ -616,16 +637,38 @@ const OrgRecharge = ({ orgId }) => {
|
||||
)}
|
||||
</h3>
|
||||
<div className='oc-rc-custom-input'>
|
||||
<InputNumber
|
||||
value={customAmount}
|
||||
onChange={handleCustomAmountChange}
|
||||
min={1}
|
||||
precision={0}
|
||||
hideButtons
|
||||
placeholder={t('请输入整数,如 1、5、10')}
|
||||
status={customInvalid ? 'error' : undefined}
|
||||
style={{ width: '100%' }}
|
||||
/>
|
||||
<div className='oc-rc-custom-field'>
|
||||
<AntInput
|
||||
value={customAmount ?? ''}
|
||||
onChange={(event) =>
|
||||
handleCustomAmountChange(event.target.value)
|
||||
}
|
||||
inputMode='numeric'
|
||||
pattern='[0-9]*'
|
||||
placeholder={t('请输入整数,如 1、5、10')}
|
||||
status={
|
||||
customAmountExceeded || customInvalid
|
||||
? 'error'
|
||||
: undefined
|
||||
}
|
||||
aria-invalid={customAmountExceeded || customInvalid}
|
||||
aria-describedby='org-recharge-custom-amount-error'
|
||||
style={{ width: '100%' }}
|
||||
/>
|
||||
<div className='oc-rc-custom-feedback' aria-live='polite'>
|
||||
<span
|
||||
id='org-recharge-custom-amount-error'
|
||||
className={
|
||||
customAmountExceeded ? undefined : 'is-hidden'
|
||||
}
|
||||
aria-hidden={!customAmountExceeded}
|
||||
>
|
||||
<Text type='danger'>
|
||||
{t('输入数量不能超过 10000,已自动调整为 10000')}
|
||||
</Text>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<Select
|
||||
value={customUnit}
|
||||
onChange={handleCustomUnitChange}
|
||||
|
||||
@@ -782,7 +782,7 @@ const OrgSettings = ({ orgId, orgRole }) => {
|
||||
className='oc-cs-alert'
|
||||
type='error'
|
||||
showIcon
|
||||
message={t('配置加载失败,为防止误覆盖已有配置,编辑已禁用。')}
|
||||
title={t('配置加载失败,为防止误覆盖已有配置,编辑已禁用。')}
|
||||
action={
|
||||
<Button size='small' type='danger' onClick={fetchPromptCfg}>
|
||||
{t('重试')}
|
||||
|
||||
@@ -406,7 +406,7 @@ const OrgTokens = ({ orgId, orgRole }) => {
|
||||
className='oc-block-gap'
|
||||
type='info'
|
||||
showIcon
|
||||
message={t(
|
||||
title={t(
|
||||
'作为普通成员,您只能管理自己创建的密钥。管理员可管理所有密钥。',
|
||||
)}
|
||||
/>
|
||||
|
||||
@@ -637,7 +637,7 @@ const OrgAnalyticsPanel = ({
|
||||
<h2>{t('{{dim}}消费分布', { dim: dimLabel })}</h2>
|
||||
<span>{t('Top 10')}</span>
|
||||
</div>
|
||||
<AntTag bordered={false}>{t('按消费排序')}</AntTag>
|
||||
<AntTag variant='filled'>{t('按消费排序')}</AntTag>
|
||||
</div>
|
||||
{loading ? (
|
||||
<div className='oc-ea-loading'>
|
||||
|
||||
@@ -221,7 +221,7 @@ const OrgTaskRecords = () => {
|
||||
{/* 只有真实存在进行中任务时才显示,避免误导 */}
|
||||
{pageStats.pendingCount > 0 && (
|
||||
<Tag
|
||||
bordered={false}
|
||||
variant='filled'
|
||||
color='processing'
|
||||
icon={<Clock size={12} />}
|
||||
>
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
Copyright (C) 2025 QuantumNous
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as
|
||||
published by the Free Software Foundation, either version 3 of the
|
||||
License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
For commercial licensing, please contact support@quantumnous.com
|
||||
*/
|
||||
|
||||
export const MAX_CUSTOM_AMOUNT = 10000;
|
||||
|
||||
export function normalizeCustomAmount(input) {
|
||||
if (input === '') return { value: null, exceeded: false };
|
||||
// Reject the whole edit so pasted decimals or signs cannot change its meaning.
|
||||
if (!/^[0-9]+$/.test(input)) return null;
|
||||
const value = Number(input);
|
||||
if (value === 0) return null;
|
||||
return {
|
||||
value: Math.min(value, MAX_CUSTOM_AMOUNT),
|
||||
exceeded: value > MAX_CUSTOM_AMOUNT,
|
||||
};
|
||||
}
|
||||
@@ -112,7 +112,10 @@ export default function PartnerConsole() {
|
||||
// mt-[60px]:顶栏 fixed 定位需自行让位(跑马灯由 PageLayout 占位补偿)
|
||||
<div className='console-content'>
|
||||
{portalClosed && (
|
||||
<Card className='!rounded-2xl shadow-sm' bodyStyle={{ padding: 40 }}>
|
||||
<Card
|
||||
className='!rounded-2xl shadow-sm'
|
||||
styles={{ body: { padding: 40 } }}
|
||||
>
|
||||
<div className='flex flex-col items-center text-center gap-3 max-w-md mx-auto'>
|
||||
<div className='p-3 rounded-full bg-brand/10 text-brand'>
|
||||
<Clock size={32} />
|
||||
@@ -134,7 +137,10 @@ export default function PartnerConsole() {
|
||||
)}
|
||||
|
||||
{!portalClosed && phase === 'error' && (
|
||||
<Card className='!rounded-2xl shadow-sm' bodyStyle={{ padding: 40 }}>
|
||||
<Card
|
||||
className='!rounded-2xl shadow-sm'
|
||||
styles={{ body: { padding: 40 } }}
|
||||
>
|
||||
<div className='flex flex-col items-center text-center gap-3 max-w-md mx-auto'>
|
||||
<div className='p-3 rounded-full bg-orange-50 dark:bg-orange-900/20 text-orange-500'>
|
||||
<AlertTriangle size={32} />
|
||||
@@ -217,7 +223,7 @@ function BenefitItem({ icon, title, desc }) {
|
||||
|
||||
function ApplyCard({ t, onSubmit }) {
|
||||
return (
|
||||
<Card className='!rounded-2xl shadow-sm' bodyStyle={{ padding: 24 }}>
|
||||
<Card className='!rounded-2xl shadow-sm' styles={{ body: { padding: 24 } }}>
|
||||
<Title heading={5} style={{ marginBottom: 4 }}>
|
||||
{t('申请成为合作伙伴')}
|
||||
</Title>
|
||||
@@ -300,7 +306,7 @@ function ApplyCard({ t, onSubmit }) {
|
||||
function StatusCard({ t, self, onRefresh, onReapply }) {
|
||||
const pending = self?.status === 'pending';
|
||||
return (
|
||||
<Card className='!rounded-2xl shadow-sm' bodyStyle={{ padding: 40 }}>
|
||||
<Card className='!rounded-2xl shadow-sm' styles={{ body: { padding: 40 } }}>
|
||||
<div className='flex flex-col items-center text-center gap-3 max-w-md mx-auto'>
|
||||
{pending ? (
|
||||
<div className='p-3 rounded-full bg-brand/10 text-brand'>
|
||||
|
||||
@@ -208,7 +208,7 @@ export default function Workbench({ self, dashboard }) {
|
||||
return (
|
||||
<Card
|
||||
className='!rounded-2xl shadow-sm'
|
||||
bodyStyle={{ padding: '20px 24px' }}
|
||||
styles={{ body: { padding: '20px 24px' } }}
|
||||
>
|
||||
<div className='flex flex-wrap items-center justify-between gap-3 mb-3'>
|
||||
<div className='flex items-center gap-2.5 min-w-0'>
|
||||
@@ -273,7 +273,7 @@ function StatCard({ icon, title, value, iconBg, bgColor, onClick }) {
|
||||
<div onClick={onClick} className={onClick ? 'cursor-pointer' : ''}>
|
||||
<Card
|
||||
className={`${bgColor} border-none shadow-sm hover:shadow-md transition-shadow !rounded-xl`}
|
||||
bodyStyle={{ padding: 16 }}
|
||||
styles={{ body: { padding: 16 } }}
|
||||
>
|
||||
<div className='flex items-start justify-between gap-2'>
|
||||
<div className='flex-1 min-w-0'>
|
||||
@@ -1136,7 +1136,7 @@ function PayoutAccount({ t, readOnly }) {
|
||||
/>
|
||||
)}
|
||||
{!editing && account && (
|
||||
<Card className='!rounded-xl' bodyStyle={{ padding: 20 }}>
|
||||
<Card className='!rounded-xl' styles={{ body: { padding: 20 } }}>
|
||||
<div className='flex items-start justify-between gap-3'>
|
||||
<div className='flex items-center gap-3 min-w-0'>
|
||||
<div className='p-2.5 bg-brand/10 text-brand rounded-lg flex-shrink-0'>
|
||||
@@ -1171,7 +1171,7 @@ function PayoutAccount({ t, readOnly }) {
|
||||
</Card>
|
||||
)}
|
||||
{!editing && !account && (
|
||||
<Card className='!rounded-xl' bodyStyle={{ padding: 24 }}>
|
||||
<Card className='!rounded-xl' styles={{ body: { padding: 24 } }}>
|
||||
<div className='flex flex-col items-center text-center gap-2 py-4'>
|
||||
<div className='p-2.5 bg-brand/10 text-brand rounded-lg'>
|
||||
<CreditCard size={22} />
|
||||
@@ -1194,7 +1194,7 @@ function PayoutAccount({ t, readOnly }) {
|
||||
</Card>
|
||||
)}
|
||||
{editing && (
|
||||
<Card className='!rounded-xl' bodyStyle={{ padding: 20 }}>
|
||||
<Card className='!rounded-xl' styles={{ body: { padding: 20 } }}>
|
||||
{/* key 随开合重挂载,避免上次输入残留;账号后端返回掩码,修改需重新完整填写 */}
|
||||
<Form key={editing ? 'open' : 'closed'} onSubmit={save}>
|
||||
{({ formState }) => (
|
||||
@@ -1364,7 +1364,7 @@ function Notices({ t, onRead, readOnly }) {
|
||||
key={n.id}
|
||||
className='!rounded-xl'
|
||||
style={{ marginBottom: 8 }}
|
||||
bodyStyle={{ padding: 12 }}
|
||||
styles={{ body: { padding: 12 } }}
|
||||
>
|
||||
<div className='flex items-center justify-between'>
|
||||
<span className='flex items-center gap-2'>
|
||||
@@ -1394,7 +1394,7 @@ function Notices({ t, onRead, readOnly }) {
|
||||
key={a.id}
|
||||
className='!rounded-xl'
|
||||
style={{ marginBottom: 8 }}
|
||||
bodyStyle={{ padding: 12 }}
|
||||
styles={{ body: { padding: 12 } }}
|
||||
>
|
||||
<div className='flex items-center justify-between'>
|
||||
<Text strong>{a.title}</Text>
|
||||
|
||||
@@ -118,7 +118,7 @@ const HistoryPanel = ({ t, refreshTrigger }) => {
|
||||
key: status,
|
||||
};
|
||||
return (
|
||||
<AntTag bordered={false} color={config.color}>
|
||||
<AntTag variant='filled' color={config.color}>
|
||||
{t(config.key)}
|
||||
</AntTag>
|
||||
);
|
||||
|
||||
@@ -175,7 +175,7 @@ const RechargePanel = ({
|
||||
<Alert
|
||||
type='info'
|
||||
showIcon
|
||||
message={t(
|
||||
title={t(
|
||||
'管理员未开启在线充值功能,请联系管理员开启或使用兑换码充值。',
|
||||
)}
|
||||
/>
|
||||
|
||||
@@ -229,9 +229,9 @@ const RechargeV2 = () => {
|
||||
<Col span={8} key={option.id}>
|
||||
<Card
|
||||
className={`amount-card ${selectedAmountOption?.id === option.id ? 'selected' : ''}`}
|
||||
bodyStyle={{ padding: 20 }}
|
||||
onClick={() => handleSelectAmount(option)}
|
||||
hoverable
|
||||
styles={{ body: { padding: 20 } }}
|
||||
>
|
||||
{option.badge && (
|
||||
<Tag color={option.badge_color || 'blue'} className='badge'>
|
||||
|
||||
@@ -700,13 +700,13 @@ const GroupMonitor = () => {
|
||||
<Modal
|
||||
open={modalVisible}
|
||||
onCancel={handleCloseModal}
|
||||
maskClosable
|
||||
afterClose={handleAfterClose}
|
||||
footer={null}
|
||||
width={950}
|
||||
title={selectedGroup?.name}
|
||||
centered
|
||||
className='group-monitor-modal'
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
{selectedGroup && (
|
||||
<>
|
||||
|
||||
@@ -503,7 +503,7 @@ const GroupMonitorAdmin = () => {
|
||||
<Col xs={12} sm={6}>
|
||||
<Card
|
||||
className='overview-card'
|
||||
bodyStyle={{ padding: '20px', textAlign: 'center' }}
|
||||
styles={{ body: { padding: '20px', textAlign: 'center' } }}
|
||||
>
|
||||
<div className='text-3xl font-bold text-blue-500'>
|
||||
{overview.total_groups}
|
||||
@@ -514,7 +514,7 @@ const GroupMonitorAdmin = () => {
|
||||
<Col xs={12} sm={6}>
|
||||
<Card
|
||||
className='overview-card'
|
||||
bodyStyle={{ padding: '20px', textAlign: 'center' }}
|
||||
styles={{ body: { padding: '20px', textAlign: 'center' } }}
|
||||
>
|
||||
<div className='text-3xl font-bold text-green-500'>
|
||||
{overview.healthy_groups}
|
||||
@@ -525,7 +525,7 @@ const GroupMonitorAdmin = () => {
|
||||
<Col xs={12} sm={6}>
|
||||
<Card
|
||||
className='overview-card'
|
||||
bodyStyle={{ padding: '20px', textAlign: 'center' }}
|
||||
styles={{ body: { padding: '20px', textAlign: 'center' } }}
|
||||
>
|
||||
<div className='text-3xl font-bold text-orange-500'>
|
||||
{overview.warning_groups}
|
||||
@@ -536,7 +536,7 @@ const GroupMonitorAdmin = () => {
|
||||
<Col xs={12} sm={6}>
|
||||
<Card
|
||||
className='overview-card'
|
||||
bodyStyle={{ padding: '20px', textAlign: 'center' }}
|
||||
styles={{ body: { padding: '20px', textAlign: 'center' } }}
|
||||
>
|
||||
<div
|
||||
className='text-3xl font-bold'
|
||||
@@ -577,7 +577,10 @@ const GroupMonitorAdmin = () => {
|
||||
|
||||
return (
|
||||
<Col key={group.name} xs={24}>
|
||||
<Card className='group-admin-card' bodyStyle={{ padding: 0 }}>
|
||||
<Card
|
||||
className='group-admin-card'
|
||||
styles={{ body: { padding: 0 } }}
|
||||
>
|
||||
{/* 分组头部 */}
|
||||
<div
|
||||
className='p-4 cursor-pointer hover:bg-gray-50 dark:hover:bg-gray-800 transition-colors'
|
||||
|
||||
@@ -403,8 +403,8 @@ export default function SettingsHeaderNavModules(props) {
|
||||
background: 'var(--ui-color-bg-1)',
|
||||
minHeight: '80px',
|
||||
}}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
shadows='hover'
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
@@ -557,8 +557,8 @@ export default function SettingsHeaderNavModules(props) {
|
||||
background: 'var(--ui-color-bg-1)',
|
||||
minHeight: '80px',
|
||||
}}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
shadows='hover'
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
@@ -635,8 +635,8 @@ export default function SettingsHeaderNavModules(props) {
|
||||
background: 'var(--ui-color-bg-1)',
|
||||
minHeight: '80px',
|
||||
}}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
shadows='hover'
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
|
||||
@@ -165,8 +165,8 @@ export default function SettingsOrgUserNavModules(props) {
|
||||
background: 'var(--ui-color-bg-1)',
|
||||
minHeight: '64px',
|
||||
}}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
shadows='hover'
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
|
||||
@@ -694,12 +694,12 @@ export default function SettingsSidebarModulesAdmin(props) {
|
||||
return (
|
||||
<Col key={module.key} xs={24} sm={12} md={8} lg={6} xl={6}>
|
||||
<Card
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
shadows='hover'
|
||||
style={{
|
||||
opacity: sectionConfig.enabled ? 1 : 0.5,
|
||||
transition: 'opacity 0.2s',
|
||||
}}
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
|
||||
@@ -870,7 +870,7 @@ function PresetGrid({
|
||||
transition: 'all 0.2s ease',
|
||||
background: 'var(--ui-color-bg-1)',
|
||||
}}
|
||||
bodyStyle={{ padding: 16 }}
|
||||
styles={{ body: { padding: 16 } }}
|
||||
>
|
||||
<div
|
||||
style={{
|
||||
|
||||
@@ -409,8 +409,8 @@ export default function SettingsSidebarModulesUser() {
|
||||
className={`!rounded-xl border border-gray-200 hover:border-blue-300 transition-all duration-200 ${
|
||||
sidebarModulesUser[section.key]?.enabled ? '' : 'opacity-50'
|
||||
}`}
|
||||
bodyStyle={{ padding: '16px' }}
|
||||
hoverable
|
||||
styles={{ body: { padding: '16px' } }}
|
||||
>
|
||||
<div className='flex justify-between items-center h-full'>
|
||||
<div className='flex-1 text-left'>
|
||||
|
||||
@@ -748,7 +748,7 @@ const SkillMarket = () => {
|
||||
type='info'
|
||||
showIcon
|
||||
icon={<Building2 size={15} aria-hidden='true' />}
|
||||
message={
|
||||
title={
|
||||
<span className='sm-org-context'>
|
||||
<span>
|
||||
{t('当前操作企业')}:<strong>{orgName}</strong>
|
||||
|
||||
@@ -255,7 +255,7 @@ export default function MockSkillMarket() {
|
||||
onReset={resetFilters}
|
||||
extra={
|
||||
<>
|
||||
<Tag color='processing' bordered={false}>
|
||||
<Tag color='processing' variant='filled'>
|
||||
{t('本地演示')}
|
||||
</Tag>
|
||||
<Text type='secondary'>
|
||||
@@ -275,7 +275,7 @@ export default function MockSkillMarket() {
|
||||
className='sm-notice'
|
||||
type='warning'
|
||||
showIcon
|
||||
message={t('浏览器存储不可用,修改仅在本次页面有效')}
|
||||
title={t('浏览器存储不可用,修改仅在本次页面有效')}
|
||||
/>
|
||||
) : null
|
||||
}
|
||||
@@ -302,7 +302,7 @@ export default function MockSkillMarket() {
|
||||
onOpen={() => setDetailId(skill.id)}
|
||||
badges={
|
||||
<Tag
|
||||
bordered={false}
|
||||
variant='filled'
|
||||
color={STATUS_TAG_COLOR[skill.enterprise_status]}
|
||||
>
|
||||
{statusLabel(skill.enterprise_status)}
|
||||
@@ -359,7 +359,7 @@ export default function MockSkillMarket() {
|
||||
title={t(editor?.id ? '编辑技能' : '新增技能')}
|
||||
open={Boolean(editor)}
|
||||
onClose={() => setEditor(null)}
|
||||
width={560}
|
||||
size={560}
|
||||
rootClassName='sm-form-drawer'
|
||||
footer={
|
||||
<Space>
|
||||
|
||||
@@ -96,7 +96,7 @@ export const SkillCard = ({
|
||||
<div className='sm-card-tags'>
|
||||
{badges}
|
||||
{tags.map((tag) => (
|
||||
<Tag key={tag} className='sm-tag' bordered={false}>
|
||||
<Tag key={tag} className='sm-tag' variant='filled'>
|
||||
{tagLabel(tag)}
|
||||
</Tag>
|
||||
))}
|
||||
|
||||
@@ -42,8 +42,7 @@ const SkillDetailDrawer = ({
|
||||
title={skill?.name}
|
||||
open={open}
|
||||
onClose={onClose}
|
||||
maskClosable
|
||||
width={620}
|
||||
size={620}
|
||||
rootClassName='sm-detail-drawer sm-theme'
|
||||
rootStyle={themeStyle}
|
||||
footer={
|
||||
@@ -54,6 +53,7 @@ const SkillDetailDrawer = ({
|
||||
</div>
|
||||
) : null
|
||||
}
|
||||
mask={{ closable: true }}
|
||||
>
|
||||
{skill ? (
|
||||
<>
|
||||
@@ -70,7 +70,7 @@ const SkillDetailDrawer = ({
|
||||
<h3>{t('标签')}</h3>
|
||||
<div className='sm-detail-tags'>
|
||||
{skill.tags.map((tag) => (
|
||||
<Tag key={tag} bordered={false}>
|
||||
<Tag key={tag} variant='filled'>
|
||||
{tagLabel(tag)}
|
||||
</Tag>
|
||||
))}
|
||||
@@ -93,7 +93,7 @@ const SkillDetailDrawer = ({
|
||||
<p>{t('任务描述中出现这些词时,该技能会自动生效。')}</p>
|
||||
<div className='sm-detail-tags'>
|
||||
{skill.triggers.map((item) => (
|
||||
<Tag key={item} bordered={false}>
|
||||
<Tag key={item} variant='filled'>
|
||||
{item}
|
||||
</Tag>
|
||||
))}
|
||||
|
||||
@@ -71,14 +71,16 @@ const SkillFilterSidebar = ({
|
||||
</div>
|
||||
<Select
|
||||
className='sm-tag-select'
|
||||
showSearch
|
||||
showSearch={{
|
||||
enabled: true,
|
||||
optionFilterProp: 'label',
|
||||
}}
|
||||
allowClear
|
||||
mode='multiple'
|
||||
maxTagCount={0}
|
||||
maxTagPlaceholder={() =>
|
||||
t('已选 {{count}} 个标签', { count: selectedTags.length })
|
||||
}
|
||||
optionFilterProp='label'
|
||||
aria-label={t('搜索并选择标签')}
|
||||
placeholder={t('搜索并选择标签')}
|
||||
value={selectedTags}
|
||||
|
||||
@@ -185,7 +185,7 @@ const Status = () => {
|
||||
headerStyle={{
|
||||
borderBottom: '1px solid var(--ui-color-border)',
|
||||
}}
|
||||
bodyStyle={{ padding: '20px' }}
|
||||
styles={{ body: { padding: '20px' } }}
|
||||
>
|
||||
<Row gutter={[16, 16]}>
|
||||
{group.monitors.map((item, mIndex) => (
|
||||
|
||||
@@ -420,7 +420,10 @@ const Invoice = () => {
|
||||
<TabPane tab={t('申请开票')} itemKey='apply'>
|
||||
<div className='space-y-4 mt-4'>
|
||||
{/* 可开票充值记录 */}
|
||||
<Card title={t('选择充值记录')} bodyStyle={{ padding: '12px' }}>
|
||||
<Card
|
||||
title={t('选择充值记录')}
|
||||
styles={{ body: { padding: '12px' } }}
|
||||
>
|
||||
<Table
|
||||
columns={topupColumns}
|
||||
dataSource={availableTopups}
|
||||
@@ -444,7 +447,7 @@ const Invoice = () => {
|
||||
</Card>
|
||||
|
||||
{/* 开票信息 */}
|
||||
<Card title={t('开票信息')} bodyStyle={{ padding: '16px' }}>
|
||||
<Card title={t('开票信息')} styles={{ body: { padding: '16px' } }}>
|
||||
<div className='space-y-3'>
|
||||
{/* 常用开票信息选择 */}
|
||||
{titles.length > 0 && (
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user