微件:Donation:修订间差异
跳转到导航
跳转到搜索
无编辑摘要 |
无编辑摘要 |
||
| 第22行: | 第22行: | ||
border: 1px solid #f5c6cb; | border: 1px solid #f5c6cb; | ||
color: #491217; | color: #491217; | ||
padding: 15px 20px; | |||
padding: | |||
border-radius: 4px; | border-radius: 4px; | ||
position: relative; | position: relative; | ||
| 第82行: | 第81行: | ||
.jr-banner-close { | .jr-banner-close { | ||
position: absolute; | position: absolute; | ||
top: | top: 5px; | ||
right: | right: 10px; | ||
font-size: | font-size: 18px; | ||
font-weight: bold; | font-weight: bold; | ||
cursor: pointer; | cursor: pointer; | ||
| 第90行: | 第89行: | ||
line-height: 1; | line-height: 1; | ||
z-index: 2; | z-index: 2; | ||
} | } | ||
| 第102行: | 第100行: | ||
flex-direction: column; | flex-direction: column; | ||
text-align: left; | text-align: left; | ||
} | } | ||
.jr-banner-qr { | .jr-banner-qr { | ||
margin-top: 15px; | margin-top: 15px; | ||
align-self: center; /* Center the QR code on mobile */ | align-self: center; /* Center the QR code on mobile */ | ||
} | } | ||
} | } | ||
| 第130行: | 第123行: | ||
<div class="jr-banner-body"> | <div class="jr-banner-body"> | ||
舰R百科不仅是舰R内容的集合,更是一项持续消耗算力的云端服务。<br><br> | 舰R百科不仅是舰R内容的集合,更是一项持续消耗算力的云端服务。<br><br> | ||
为了保障流畅体验,高质量信息的维护需要资源。如果您从R百中获取了价值,或者希望这项服务保持稳定在线,请考虑分担这一成本。 | |||
</div> | </div><br><br> | ||
<div class="jr-banner-footer"> | <div class="jr-banner-footer"> | ||
您的支持将直接用于云计算续费。 | 您的支持将直接用于云计算续费。 | ||
| 第159行: | 第152行: | ||
if (!isClosed) { | if (!isClosed) { | ||
// Show the banner | // Show the banner | ||
$(banner).fadeIn(); // Use jQuery for smooth fade if available, or just banner.style.display = 'block'; | |||
} | } | ||
// 2. Handle Close Click | // 2. Handle Close Click | ||
closeBtn.addEventListener('click', function() { | |||
// Hide visually | |||
$(banner).slideUp(); | |||
// Save to storage | |||
localStorage.setItem(storageKey, 'true'); | |||
}); | |||
})(); | })(); | ||
</script> | </script> | ||
</includeonly> | </includeonly> | ||
2025年12月8日 (一) 20:50的版本
Donation Banner Widget
Use this code in MediaWiki:Sitenotice to display the banner: