From 851d0cff44d7a3822b4b72c9cb091e7fedf007b4 Mon Sep 17 00:00:00 2001 From: nanguiyixin Date: Mon, 25 May 2026 22:22:00 +0800 Subject: [PATCH] Update fourth-wall.html --- modules/fourth-wall/fourth-wall.html | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/modules/fourth-wall/fourth-wall.html b/modules/fourth-wall/fourth-wall.html index 4f5953da..b6bb403d 100644 --- a/modules/fourth-wall/fourth-wall.html +++ b/modules/fourth-wall/fourth-wall.html @@ -2184,13 +2184,14 @@

API配置

} function hydrateImageSlots(container) { - initImageObserver(); - container.querySelectorAll('.fw-img-slot:not([data-observed])').forEach(slot => { - slot.setAttribute('data-observed', '1'); - if (!slot.dataset.loaded && !slot.dataset.loading) { - slot.innerHTML = `
滚动加载
`; - } - imageObserver.observe(slot); + container.querySelectorAll('.fw-img-slot:not([data-loaded]):not([data-loading])').forEach(slot => { + const tags = parseImageToken(decodeURIComponent(slot.dataset.raw || '')); + if (!tags) return; + slot.dataset.loading = '1'; + const requestId = 'fwimg_' + Date.now() + '_' + Math.random().toString(36).slice(2, 8); + pendingImages.set(requestId, { slot, tags }); + slot.innerHTML = `
查询缓存...
`; + postToParent({ type: 'CHECK_IMAGE_CACHE', requestId, tags }); }); }