修复 TypeScript 类型错误:将 MUI sx 语法改成标准 CSS 属性

This commit is contained in:
雨霖铃
2026-05-22 00:38:48 +08:00
parent 427e668e7c
commit 6711783975
7 changed files with 14 additions and 13 deletions
+1 -1
View File
@@ -80,7 +80,7 @@ export default function JsonFormatSection() {
value={indentSize}
onChange={(v) => setIndentSize(v)}
options={INDENT_OPTIONS.map((size) => ({ value: size, label: String(size) }))}
sx={{ width: 'auto', mb: 0, flexShrink: 0 }}
sx={{ width: 'auto', marginBottom: 0, flexShrink: 0 }}
size="small"
/>
+2 -2
View File
@@ -28,14 +28,14 @@ export default function Index() {
subtitle={t('qrCode:pageSubtitle')}
icon={<QrCode />}
iconColor={qrCodePageStyles.primaryColor}
sx={{ mb: 2.5 }}
sx={{ marginBottom: '0.625rem' }}
/>
<SwitchButtonGroup
value={qrCode.mode}
options={modeOptions}
onChange={qrCode.setMode}
sx={{ mb: 3 }}
sx={{ marginBottom: '0.75rem' }}
/>
{qrCode.mode === 'generate' ? <GeneratePanel /> : <ParsePanel />}
+8 -3
View File
@@ -43,7 +43,12 @@ export default function DomainHeader({ domain, totalSize }: DomainHeaderProps) {
</Box>
) : null
}
iconSx={storageCleanerPageStyles.DOMAIN_HEADER_ICON}
iconSx={{
padding: '0.3rem',
borderRadius: '0.75rem',
boxShadow: '0 2px 8px rgba(245, 158, 11, 0.15)',
transition: 'all 0.2s',
}}
titleSx={{
fontSize: '1rem',
}}
@@ -53,10 +58,10 @@ export default function DomainHeader({ domain, totalSize }: DomainHeaderProps) {
overflow: 'hidden',
textOverflow: 'ellipsis',
whiteSpace: 'nowrap',
mt: 0.3,
marginTop: '0.3rem',
fontSize: '0.75rem',
}}
sx={{ mb: 3 }}
sx={{ marginBottom: '0.75rem' }}
/>
);
}
+1 -1
View File
@@ -52,7 +52,7 @@ export default function Index() {
minRows={8}
maxRows={15}
showClear={false}
sx={{ mb: 3 }}
sx={{ marginBottom: '0.75rem' }}
/>
{/* 统计结果展示区域 */}
+1 -1
View File
@@ -77,7 +77,7 @@ export default function Index() {
{ value: 's', label: t('timestamp:unitS') },
]}
onChange={(v) => setUnit(v as 'ms' | 's')}
sx={{ width: 'auto', mb: 0, flexShrink: 0 }}
sx={{ width: 'auto', marginBottom: 0, flexShrink: 0 }}
size="small"
/>