Skip to content

Commit 0e5d306

Browse files
committed
ad
1 parent e828f1d commit 0e5d306

1 file changed

Lines changed: 28 additions & 3 deletions

File tree

‎pinterest-embed.html‎

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,26 @@
55
<!DOCTYPE html>
66
<html>
77
<head>
8-
8+
<style>
9+
body > span {
10+
width: 100% !important;
11+
height: 100% !important;
12+
max-width: 100% !important;
13+
max-height: 100% !important;
14+
}
15+
16+
span[class*="_bd"] {
17+
height: 100% !important;
18+
}
19+
20+
* {
21+
border: none !important;
22+
}
23+
</style>
924
</head>
1025
<body>
11-
<script type="text/javascript" async defer src="//assets.pinterest.com/js/pinit.js"></script>
12-
<a data-pin-do="embedBoard" data-pin-board-width="400" data-pin-scale-height="240" data-pin-scale-width="80" href="https://pinterest.com/"></a>
26+
<script type="text/javascript" async defer src="https://assets.pinterest.com/js/pinit.js"></script>
27+
<a data-pin-do="embedBoard" data-pin-board-width="400" data-pin-scale-width="100" href="https://pinterest.com/"></a>
1328
<script>
1429
const getJsonFromUrl = (url) => {
1530

@@ -32,6 +47,16 @@
3247
if (link) {
3348
document.querySelector('[data-pin-do="embedBoard"]').setAttribute("href", "https://www.pinterest.com/" + link);
3449
}
50+
51+
setTimeout(() => {
52+
if(document.querySelector('[data-pin-do="embedBoard"]') != null) {
53+
var p = document.createElement("p");
54+
p.innerHTML = "Error loading "+ "https://www.pinterest.com/" + link;
55+
p.style.width = "100%";
56+
p.style.textAlign = "center";
57+
document.body.appendChild(p)
58+
}
59+
}, 5000);
3560
</script>
3661
</body>
3762
</html>

0 commit comments

Comments
 (0)