feat: 站点媒体库与移动端底部导航,服务测试补强
- 新增媒体库:media_library/media_thumbs 服务(WebP 缩略图)、管理端 media 页面 - 移动端底部导航 MobileTabBar 替换 MobilePostBar - 旧数据导入增强与测试、路由与登录会话/板块侧边栏测试补强 - site-doc 组件精简(移除 Breadcrumb),文档新增迁移公告说明
This commit is contained in:
@@ -413,9 +413,9 @@ export default function MarkdownEditor({
|
||||
if (!file || disabled) return;
|
||||
retryFile.current = file;
|
||||
setUploadError("");
|
||||
if (!/^image\/(jpeg|png|webp)$/i.test(file.type)) {
|
||||
setUploadError("仅支持 JPEG / PNG / WebP");
|
||||
toast("仅支持 JPEG / PNG / WebP", "error");
|
||||
if (!/^image\/(jpeg|png|webp|gif)$/i.test(file.type)) {
|
||||
setUploadError("仅支持 JPEG / PNG / WebP / GIF");
|
||||
toast("仅支持 JPEG / PNG / WebP / GIF", "error");
|
||||
return;
|
||||
}
|
||||
const maxBytes = Math.max(1, imageMaxMB) * 1024 * 1024;
|
||||
@@ -1254,7 +1254,7 @@ export default function MarkdownEditor({
|
||||
<input
|
||||
ref={fileRef}
|
||||
type="file"
|
||||
accept="image/jpeg,image/png,image/webp"
|
||||
accept="image/jpeg,image/png,image/webp,image/gif"
|
||||
className="hidden"
|
||||
onChange={(e) => void uploadImageFile(e.target.files?.[0] ?? null)}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user