mirror of
https://github.com/router-for-me/Cli-Proxy-API-Management-Center.git
synced 2026-02-03 03:10:50 +08:00
feat(auth-files): add disabled state styling for file cards
This commit is contained in:
@@ -446,6 +446,16 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.fileCardDisabled {
|
||||||
|
opacity: 0.6;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
transform: none;
|
||||||
|
box-shadow: none;
|
||||||
|
border-color: var(--border-color);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.cardHeader {
|
.cardHeader {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|||||||
@@ -1349,19 +1349,22 @@ export function AuthFilesPage() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// 渲染单个认证文件卡片
|
// 渲染单个认证文件卡片
|
||||||
const renderFileCard = (item: AuthFileItem) => {
|
const renderFileCard = (item: AuthFileItem) => {
|
||||||
const fileStats = resolveAuthFileStats(item, keyStats);
|
const fileStats = resolveAuthFileStats(item, keyStats);
|
||||||
const isRuntimeOnly = isRuntimeOnlyAuthFile(item);
|
const isRuntimeOnly = isRuntimeOnlyAuthFile(item);
|
||||||
const isAistudio = (item.type || '').toLowerCase() === 'aistudio';
|
const isAistudio = (item.type || '').toLowerCase() === 'aistudio';
|
||||||
const showModelsButton = !isRuntimeOnly || isAistudio;
|
const showModelsButton = !isRuntimeOnly || isAistudio;
|
||||||
const typeColor = getTypeColor(item.type || 'unknown');
|
const typeColor = getTypeColor(item.type || 'unknown');
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div key={item.name} className={styles.fileCard}>
|
<div
|
||||||
<div className={styles.cardHeader}>
|
key={item.name}
|
||||||
<span
|
className={`${styles.fileCard} ${item.disabled ? styles.fileCardDisabled : ''}`}
|
||||||
className={styles.typeBadge}
|
>
|
||||||
style={{
|
<div className={styles.cardHeader}>
|
||||||
|
<span
|
||||||
|
className={styles.typeBadge}
|
||||||
|
style={{
|
||||||
backgroundColor: typeColor.bg,
|
backgroundColor: typeColor.bg,
|
||||||
color: typeColor.text,
|
color: typeColor.text,
|
||||||
...(typeColor.border ? { border: typeColor.border } : {}),
|
...(typeColor.border ? { border: typeColor.border } : {}),
|
||||||
|
|||||||
Reference in New Issue
Block a user