修改分享页样式

This commit is contained in:
chenruiye
2025-03-18 14:11:18 +08:00
parent ecff8b6635
commit c1f4feb337
3 changed files with 56 additions and 7 deletions

View File

@@ -42,7 +42,14 @@ body {
}
.zh_content {
margin-bottom: 2.6666666667rem;
padding-bottom: 2.6666666667rem;
position: absolute;
top: 5.3333333333rem;
}
.wai_content {
position: absolute;
top: 5.2rem;
}
.game_boxwrap {
@@ -85,6 +92,7 @@ body {
}
.game_boxwrap .wrap .game_content .flex_box .info {
text-align: center;
overflow: visible;
}
.game_boxwrap .wrap .game_content .flex_box .info img {
width: 1.0666666667rem;
@@ -97,6 +105,7 @@ body {
font-size: 0.32rem;
color: #381600;
margin-top: 0.1066666667rem;
width: 0.9066666667rem;
}
.game_boxwrap .wrap .game_content .flex_box .right {
display: flex;
@@ -119,6 +128,10 @@ body {
color: #D9000A;
margin: 0 0.2133333333rem;
}
.game_boxwrap .wrap .game_content .flex_box .right .coins_img img {
width: 0.6933333333rem;
height: 0.6933333333rem;
}
.game_boxwrap .wrap .game_content .tip {
font-family: PingFang SC;
font-weight: 400;
@@ -253,6 +266,7 @@ body {
.invite_boxwrap .wrap .invite_content #txt11 {
color: #D9000A;
box-shadow: 0 -0.2133333333rem 0 #FFDF6F inset;
font-weight: 600;
}
.bottom_boxwrap {

View File

@@ -11,6 +11,7 @@ body {
.header {
position: relative;
.headerImg {
width: 100%;
// height: px2rem(458);
@@ -32,6 +33,7 @@ body {
right: 0;
margin: 0 auto;
padding: px2rem(6) 0;
span {
font-family: PingFang SC;
font-weight: 600;
@@ -47,9 +49,17 @@ body {
}
}
}
.zh_content{
margin-bottom: px2rem(200);
.zh_content {
padding-bottom: px2rem(200);
position: absolute;
top: px2rem(400);
}
.wai_content{
position: absolute;
top: px2rem(390);
}
.game_boxwrap {
margin: 0 px2rem(30);
position: relative;
@@ -102,7 +112,7 @@ body {
.info {
text-align: center;
overflow: visible;
img {
width: px2rem(80);
height: px2rem(80);
@@ -115,7 +125,9 @@ body {
font-size: px2rem(24);
color: #381600;
margin-top: px2rem(8);
width: px2rem(68);
}
}
.right {
@@ -141,6 +153,12 @@ body {
color: #D9000A;
margin: 0 px2rem(16);
}
.coins_img{
img{
width: px2rem(52);
height: px2rem(52);
}
}
}
}
@@ -317,6 +335,8 @@ body {
#txt11 {
color: #D9000A;
box-shadow: 0 px2rem(-16) 0 #FFDF6F inset;
font-weight: 600;
}
// #txt9 ,#txt11::after{
@@ -345,6 +365,7 @@ body {
box-sizing: border-box;
padding: 0 0 0 px2rem(30);
z-index: 99;
.logo {
img {
width: px2rem(106);

View File

@@ -116,10 +116,18 @@ function translateFun() {
$('#txt14').html(langReplace(localLang.demoModule.txt14))
}
// 截取字符串首字母的方法
function getFirstLetter(str) {
if (!str || typeof str !== 'string') {
return ''; // 如果输入不是字符串或为空,返回空字符串
}
return str.charAt(0); // 返回字符串的第一个字符
}
function renderGameOption() {
var currentIndex = 0;
var contentHtml = '';
function createGiftItem(item) {
const firstLetter = getFirstLetter(item.nick); // 获取首字母
return `
<div class="swiper-slide">
<div class="game_content">
@@ -129,7 +137,7 @@ function renderGameOption() {
src="${item.avatar}"
alt=""
/>
<div class="name">${item.nick}</div>
<div class="name">${firstLetter}****</div>
</div>
<div class="right">
<img src="./images/win.png" alt="" class="win" />
@@ -139,6 +147,12 @@ function renderGameOption() {
class="game_link"
/>
<div class="coins">${item.win}</div>
<div class="coins_img">
<img
src="./images/jinbi.png"
alt=""
/>
</div>
</div>
</div>
<div class="tip">${langReplace(localLang.demoModule.Send)} ${item.pay} ${langReplace(localLang.demoModule.Won)} ${item.rate} ${langReplace(localLang.demoModule.Times)}</div>
@@ -167,8 +181,8 @@ function renderLuckGiftOption() {
/>
</div>
<div class="right">
<div class="txt">${langReplace(localLang.demoModule.Send)} ${langReplace(localLang.demoModule[item.gift_name])}</div>
<div class="txt2">${langReplace(localLang.demoModule.Won)} ${item.rate} ${langReplace(localLang.demoModule.Times)}</div>
<div class="txt">${langReplace(localLang.demoModule.Send)} <span style="color: #FDF565;"> ${langReplace(localLang.demoModule[item.gift_name])}</span></div>
<div class="txt2">${langReplace(localLang.demoModule.Won)} <span style="color: #FDF565;">${item.rate}</span> ${langReplace(localLang.demoModule.Times)}</div>
</div>
</div>
<div class="yuan_box">