diff --git a/App.jsx b/App.jsx
index 6f8152f..16cea4e 100644
--- a/App.jsx
+++ b/App.jsx
@@ -5732,7 +5732,7 @@ const WEB_MAX_IMAGES = 6;
const WEB_MAX_DETAIL_IMAGES = 20;
// 网站图片列表(主图、详情图共用):多选上传、拖动排序、删除
-function WebImageList({ draft, set, onNotify, field, max, label, cover, tall }) {
+function WebImageList({ draft, set, onNotify, field, max, label, cover, tall, accept = 'image/*' }) {
const images = Array.isArray(draft[field]) ? draft[field] : [];
const [uploading, setUploading] = useState(false);
const [dragIdx, setDragIdx] = useState(null);
@@ -5786,7 +5786,9 @@ function WebImageList({ draft, set, onNotify, field, max, label, cover, tall })
onDrop={() => handleDrop(idx)}
onDragEnd={() => setDragIdx(null)}
>
-
+ {/\.(mp4|webm)$/i.test(f)
+ ?
+ :
}
{cover && idx === 0 && 封面}
{!cover && {idx + 1}}
@@ -5794,9 +5796,9 @@ function WebImageList({ draft, set, onNotify, field, max, label, cover, tall })
))}
{images.length < max && (
)}
@@ -5816,6 +5818,17 @@ const newTemplateId = () => 'tpl_' + Date.now().toString(36) + Math.random().toS
// 图片位的 id 必须和网站代码 src/lib/about-i18n.mjs 里用到的一致;以后网站新增图片位,在这里加一行。
const SITE_ASSET_DIR = 'site_assets';
const SITE_SLOT_GROUPS = [
+ { page: '首页动画(如果这个时候停电)', url: '/en/', groups: [
+ { title: '六个场景依次全屏 3 秒再缩小到两侧,然后停电变黑、UPS 出现、画面恢复。可以传写实照片,也可以传 MP4 短视频(静音循环,建议 5–10 秒、10MB 以内);没上传的场景显示占位插画', slots: [
+ { id: 'hp_hospital', name: '① 医院手术室', hint: '无影灯下医生做手术 · 左上', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_school', name: '② 晚上 11 点教室', hint: '高中生在明亮的教室里学习 · 左中', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_fab', name: '③ 芯片工厂车间', hint: '无尘车间生产线 · 左下', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_airport', name: '④ 机场航站楼', hint: '夜晚航站楼、值机柜台、航班屏 · 右上', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_esports', name: '⑤ 电竞比赛(PUBG)', hint: '比赛现场、大屏、选手 · 右中', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_family', name: '⑥ 家庭客厅看电视', hint: '晚上一家人在客厅看电视 · 右下', size: '1920×1080 横图或视频', video: true },
+ { id: 'hp_ups', name: 'UPS 产品图', hint: '最后出现在中间,建议白底或透明底 PNG', size: '竖图,透明背景最好' },
+ ] },
+ ] },
{ page: 'About Us 页面', url: '/en/about/', groups: [
{ title: '首屏', slots: [{ id: 'hero', name: '工厂外景', hint: '首屏右侧大图', size: '1600×1300 横图' }] },
{ title: '公司介绍(图集:可传多张并写标题,第一张是网站上显示的首图,访客点开可以翻看全部)', slots: [
@@ -5906,7 +5919,7 @@ function SiteAssetsEditor({ assets, setAssets, onNotify }) {
setSlot(sl.id, patch.images || [])}
- onNotify={onNotify} field="images" max={1} label="" />
+ onNotify={onNotify} field="images" max={1} label="" accept={sl.video ? 'image/*,video/mp4,video/webm' : 'image/*'} />
);
})}