[mod] aspectMode 從cover改為fit

This commit is contained in:
建喵 2023-11-15 17:22:44 +08:00
parent f6b10993cc
commit af628a14bd

View File

@ -7,11 +7,11 @@ window.onload = function (_0xe315c8) {
if (!liff.isLoggedIn()) { if (!liff.isLoggedIn()) {
liff.login({ redirectUri: location.href }); liff.login({ redirectUri: location.href });
} else { } else {
getP(); getParameter();
} }
}); });
}; };
function getP() { function getParameter() {
var type = getParameterByName("type"); var type = getParameterByName("type");
if (!type) { if (!type) {
document.getElementById("textx").addEventListener("click", function () { document.getElementById("textx").addEventListener("click", function () {
@ -62,7 +62,7 @@ function getP() {
makeAudio(); makeAudio();
makeSticker(); makeSticker();
meProfile(); meProfile();
// makeTest(); makeTest();
// makeDouDou(); // makeDouDou();
makeBW(); makeBW();
} }
@ -167,7 +167,7 @@ function makeSticker() {
"type": "image", "type": "image",
"url": "https://stickershop.line-scdn.net/stickershop/v1/sticker/85913166/IOS/sticker_animation@2x.png", "url": "https://stickershop.line-scdn.net/stickershop/v1/sticker/85913166/IOS/sticker_animation@2x.png",
"size": "full", "size": "full",
"aspectMode": "cover", "aspectMode": "fit",
"animated": true, "animated": true,
"backgroundColor": "#FFFFFF00" "backgroundColor": "#FFFFFF00"
} }
@ -199,7 +199,7 @@ function makeSticker() {
"type": "image", "type": "image",
"url": "https://stickershop.line-scdn.net/stickershop/v1/sticker/" + sid + pngtype, "url": "https://stickershop.line-scdn.net/stickershop/v1/sticker/" + sid + pngtype,
"size": "full", "size": "full",
"aspectMode": "cover", "aspectMode": "fit",
"animated": true, "animated": true,
"backgroundColor": "#FFFFFF00" "backgroundColor": "#FFFFFF00"
} }
@ -277,26 +277,52 @@ function makeTest() {
{ {
"type": "bubble", "type": "bubble",
"size": "mega", "size": "mega",
"body": { "hero": {
"type": "box",
"layout": "vertical",
"contents": [
{
"type": "image", "type": "image",
"url": "https://i.imgur.com/BNF0CiC.png", "url": "https://i.imgur.com/BNF0CiC.png",
"size": "full", "size": "full",
"aspectRatio": "20:13", "aspectRatio": "20:13",
"aspectMode": "cover", "aspectMode": "cover",
"animated": false,
"backgroundColor": "#FFFFFF00"
}
],
"paddingAll": "none"
},
"action": { "action": {
"type": "uri", "type": "uri",
"label": "action", "uri": "https://liff.line.me/1656796140-BaDWXE29?GameId=147&Promotion=36tNMgn&RefAccount=BeH7585"
"uri": "https://i.imgur.com/BNF0CiC.png" }
},
"body": {
"type": "box",
"layout": "vertical",
"contents": [
{
"type": "text",
"text": "剛剛不小心在金爸爸尻到100倍大獎",
"weight": "bold",
"size": "md"
},
{
"type": "text",
"text": "實力不允許我低調",
"align": "center",
"weight": "bold"
}
]
},
"footer": {
"type": "box",
"layout": "vertical",
"spacing": "sm",
"contents": [
{
"type": "button",
"style": "link",
"height": "sm",
"action": {
"type": "uri",
"label": "點進來一起領獎金",
"uri": "https://liff.line.me/1656796140-BaDWXE29?GameId=147&Promotion=36tNMgn&RefAccount=BeH7585"
}
}
],
"flex": 0
} }
} }
}]; }];