feat: iOS glassmorphism console cards (corner gradient edge + inner sheen + backdrop blur)

This commit is contained in:
Aisland
2026-08-21 12:05:20 +08:00
parent 62b5deb552
commit 6834ba3fd7
3 changed files with 34 additions and 4 deletions
+6
View File
@@ -169,6 +169,12 @@ const sleep = (ms) => new Promise((r) => setTimeout(r, ms));
var cr = cardEl.getBoundingClientRect();
out.cardAspect = Math.round((cr.width / Math.max(1, cr.height)) * 100) / 100;
out.cardWidth = Math.round(cr.width);
var gs0 = getComputedStyle(cardEl);
out.cardSheen = gs0.backgroundImage ? gs0.backgroundImage.slice(0, 70) : null;
out.cardBlur = gs0.backdropFilter ? gs0.backdropFilter.slice(0, 40) : null;
var ge = getComputedStyle(cardEl, '::after');
out.glassEdge = ge.backgroundImage ? ge.backgroundImage.slice(0, 70) : null;
out.glassEdgeOpacity = ge.opacity;
var statusEl = cardEl.querySelector('.dsh-wt_consoleStatus');
out.statusFont = statusEl ? getComputedStyle(statusEl).fontSize : null;
cardEl.classList.add('dsh-wt_consoleCard-busy');