|
@@ -401,9 +401,6 @@ function ParseProductSection(inContent) {
|
|
|
height: parseInt(tmph),
|
|
|
},
|
|
|
caption: "小寶優居 | " + $('#ctitle').val(),
|
|
|
- stretched: false,
|
|
|
- withBorder: true,
|
|
|
- withBackground: false,
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -417,10 +414,7 @@ function ParseProductSection(inContent) {
|
|
|
width: 300,
|
|
|
height: 300,
|
|
|
},
|
|
|
- caption: "小寶優居 | ",
|
|
|
- stretched: false,
|
|
|
- withBorder: true,
|
|
|
- withBackground: false,
|
|
|
+ caption: "小寶優居 | " + $('#ctitle').val(),
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -512,9 +506,6 @@ function ParseProductSection(inContent) {
|
|
|
height: parseInt(tmph),
|
|
|
},
|
|
|
caption: "小寶優居 | " + $('#ctitle').val(),
|
|
|
- stretched: false,
|
|
|
- withBorder: true,
|
|
|
- withBackground: false,
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -528,10 +519,7 @@ function ParseProductSection(inContent) {
|
|
|
width: 300,
|
|
|
height: 300,
|
|
|
},
|
|
|
- caption: "小寶優居 | ",
|
|
|
- stretched: false,
|
|
|
- withBorder: true,
|
|
|
- withBackground: false,
|
|
|
+ caption: "小寶優居 | " + $('#ctitle').val(),
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -560,6 +548,7 @@ function ParseProductSection(inContent) {
|
|
|
//console.log('something changed', block);
|
|
|
}
|
|
|
});
|
|
|
+ //$('.image-tool__caption').css('display', 'none');
|
|
|
}
|
|
|
|
|
|
function GenProductSection(mimg, specimg) {
|
|
@@ -659,15 +648,17 @@ function GenProductSection(mimg, specimg) {
|
|
|
block = mimg.blocks[i];
|
|
|
if (block.type == "image") {
|
|
|
iurl = block.data.file.url.split('/');
|
|
|
- if (firstimg) {
|
|
|
- $("#cimage").val($("#curl").val() + '/' + iurl[iurl.length - 1]);
|
|
|
- firstimg = false;
|
|
|
+ if (iurl[iurl.length - 1] != "logo2.png") {
|
|
|
+ if (firstimg) {
|
|
|
+ $("#cimage").val($("#curl").val() + '/' + iurl[iurl.length - 1]);
|
|
|
+ firstimg = false;
|
|
|
+ }
|
|
|
+ mimgstr += '<amp-img\n alt="小寶優居 | ' + $("#ctitle").val()
|
|
|
+ + '"\n src="' + iurl[iurl.length - 1]
|
|
|
+ + '"\n height="' + block.data.file.height
|
|
|
+ + '"\n width="' + block.data.file.width
|
|
|
+ + '"\n layout="responsive">\n</amp-img>';
|
|
|
}
|
|
|
- mimgstr += '<amp-img\n alt="' + block.data.caption
|
|
|
- + '"\n src="' + iurl[iurl.length - 1]
|
|
|
- + '"\n height="' + block.data.file.height
|
|
|
- + '"\n width="' + block.data.file.width
|
|
|
- + '"\n layout="responsive">\n</amp-img>';
|
|
|
}
|
|
|
}
|
|
|
tmpstr = tmpstr.replaceAll('##AMP-IMG##', mimgstr == "" ? " " : mimgstr);
|
|
@@ -678,7 +669,8 @@ function GenProductSection(mimg, specimg) {
|
|
|
block = mimg.blocks[i];
|
|
|
if (block.type == "image") {
|
|
|
iurl = block.data.file.url.split('/');
|
|
|
- previmgstr += (previmgstr == "" ? "" : '\n') + `<button on="tap:carousel-with-preview.goToSlide(index=` + i + `)">
|
|
|
+ if (iurl[iurl.length - 1] != "logo2.png") {
|
|
|
+ previmgstr += (previmgstr == "" ? "" : '\n') + `<button on="tap:carousel-with-preview.goToSlide(index=` + i + `)">
|
|
|
<amp-img
|
|
|
src="`+ iurl[iurl.length - 1] + `"
|
|
|
width="40"
|
|
@@ -686,6 +678,7 @@ function GenProductSection(mimg, specimg) {
|
|
|
alt="`+ block.data.caption + `"
|
|
|
></amp-img>
|
|
|
</button>`;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
tmpstr = tmpstr.replaceAll('##PREV-IMG##', previmgstr == "" ? " " : previmgstr);
|
|
@@ -696,11 +689,13 @@ function GenProductSection(mimg, specimg) {
|
|
|
block = specimg.blocks[i];
|
|
|
if (block.type == "image") {
|
|
|
iurl = block.data.file.url.split('/');
|
|
|
- specimgstr += '<amp-img\n alt="' + block.data.caption
|
|
|
- + '"\n src="' + iurl[iurl.length - 1]
|
|
|
- + '"\n height="' + block.data.file.height
|
|
|
- + '"\n width="' + block.data.file.width
|
|
|
- + '"\n layout="responsive">\n</amp-img>';
|
|
|
+ if (iurl[iurl.length - 1] != "logo2.png") {
|
|
|
+ specimgstr += '<amp-img\n alt="小寶優居 | ' + $("#ctitle").val()
|
|
|
+ + '"\n src="' + iurl[iurl.length - 1]
|
|
|
+ + '"\n height="' + block.data.file.height
|
|
|
+ + '"\n width="' + block.data.file.width
|
|
|
+ + '"\n layout="responsive">\n</amp-img>';
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
tmpstr = tmpstr.replaceAll('##SPEC-IMG##', specimgstr == "" ? " " : specimgstr);
|