-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBottom.js
107 lines (103 loc) · 11.2 KB
/
Bottom.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
let bottom=document.querySelector(".bottom");
let imge=document.createElement("img")
imge.setAttribute("src","https://images.macrumors.com/t/2KynFWrcdcF6WciQG2i-s61Gf_g=/800x0/article-new/2019/09/appletv.jpg?lossy")
let heading1=document.createElement("h2")
heading1.innerText="Watch Apple TV+ here or anywhere."
let para1=document.createElement("p")
para1.innerText="Find Apple TV+ on the Apple TV app, available on Apple devices, smart TVs, and more."
let anch1=document.createElement("a")
anch1.innerText="See all supported devices >"
anch1.href="https://support.apple.com/en-in/guide/tvplus/welcome/web"
let data=[
{
name:"Apple TV",
url:"https://www.mac2sell.net/medias/categories/apple-tv.svg",
redirect:"https://support.apple.com/en-in/guide/tvplus/apdec6a74b4c/1.0/web/1.0"
},
{
name:"iPhone",
url:"https://www.mac2sell.net/medias/categories/iphones.svg",
redirect:"https://support.apple.com/en-in/guide/tvplus/apd5a38547d1/1.0/web/1.0"
},
{
name:"iPad",
url:"https://www.mac2sell.net/medias/categories/ipads.svg",
redirect:"https://support.apple.com/en-in/guide/tvplus/apd5a38547d1/1.0/web/1.0"
},
{
name:"Mac",
url:"https://www.mac2sell.net/medias/categories/macbook-pro-13.svg",
redirect:"https://support.apple.com/en-in/guide/tvplus/apd53158ab1f/1.0/web/1.0"
},
{
name:"AirPlay",
url:"https://www.mac2sell.net/medias/categories/apple-tv.svg",
redirect:"https://support.apple.com/en-in/guide/tvplus/welcome/web"
}
];
let divMain=document.createElement("div")
divMain.setAttribute("class","botdiv")
divInDivImg(data,divMain)
function divInDivImg(data,appendIn){
data.forEach(function(elem){
let div=document.createElement("div");
let imge=document.createElement("img")
imge.setAttribute("src",elem.url)
imge.addEventListener("click",function(){
if(elem.redirect!=undefined){
window.location.href=elem.redirect;
}
})
let para=document.createElement("p")
para.innerText=elem.name;
div.append(imge,para)
appendIn.append(div)
})
}
let heading2=document.createElement("h2")
heading2.innerText="See it on your big screen."
let anch2=document.createElement("a")
anch2.innerText="Set up your device >"
anch2.href="https://support.apple.com/en-in/guide/tvplus/welcome/web"
let anch3=document.createElement("a")
anch3.innerText="Explore compatible devices >"
anch3.href="https://www.apple.com/apple-tv-app/devices/"
let br=document.createElement("br")
let divMain2=document.createElement("div")
divMain2.setAttribute("id","botdiv2")
Data2=[
{
name:"Streaming Devices",
url:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOEAAADhCAMAAAAJbSJIAAAAeFBMVEUAAADu7u7z8/OoqKj09PTBwcGMjIz39/daWlp9fX2ysrLt7e3g4ODj4+O2trbq6uodHR3Q0NAlJSVMTEx3d3ehoaGamppHR0dgYGDIyMhubm47OzuIiIirq6u/v78zMzOVlZUsLCxAQEAWFhZSUlIYGBhoaGgNDQ2Zco50AAAFpklEQVR4nO2da3fyKhCFG8RiNDHircZb0+v7///hUc86pwyg9RUGdK39fI0tbMnAzA7BpycAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4M7ZzJe9PCznG355r4tKSSnyIKWqFq+8ApcjWeRFjpaM+iZaZdZ3ROkJl8BpJXKrOyGqKZNCfR8CDxI1j8Be7hD8QfY4BL7klkV4YVA4vJd79IgYxhc4rXOrItTxJ5vVPSwUP6hVdIXP9zPPHJHP0RWSMMyUtZk9iB+IfeP/izZL4t2aXeizKpTb6P/+GrYyncL4QXANz1AYBhQmAAoDgcIEQGEgUJgAKAwEChMAhYFAYQKgMJBWGXTR//01MCucDX5YMT/DOwOzwjsACh8fKHx8oPDxgcLHBwofHygMpBv2ls/z1WzDtR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bNoYWUMyrKln1xhafL2tSfmMM3/CWYn6d0Pl71CzEpmhZA3JsPoi17WGRSP6UbmCtVWMY7ioNUyvKaV+X+25cmGDkjMsw7yyFuwGlVdsQ+3dHdaVC0iFFGtFuLoj87JbLF6+FzQJzdc/qx0K2l44kmF+jcsZ5FvN+5hii5MxvFX9mi7xVyB1hhHi7trPNta+A2lMCqAZDlENEV/dx9shrZ1AHHO0mnMpGeaL7ViGZrq++y7n4ygH6qeLZTZImbJg7nKPL+f7a4n3G8XFhWf8HETDNHq6UAD1+1e66PHS6zYTu36DBu67GPmZqaCZ7J3seY7O1ccp1limANMQ/vSDpC7bSXVtYzKvSxiPI9wIhnivbVwZYq7rm8Zqwh5uDXSEeHOv9VLK+/rlfN82W5bGa+v2nwB5CWDoi9ifwWKzWQy+z3QLEr4Owv3bzM3/Oy84bEgfNqQPG9KHDenDhvRhQ/qwIX3YkD5sSB82pA8b0ocN6cOG9GFD+rAhfdiQPmxIHzakDxvShw3pw4b0YUP6sCF92JA+bEgfNqQPG9KHDenDhvRhQ/qwIX3YkD5sSB82pA8b0ocN6cOG9Mke/nP+AjlKPpsnk2gWAAAAAElFTkSuQmCC"
}
]
divInDivImg(Data2,divMain2)
bottom.append(imge,heading1,para1,anch1,divMain,heading2,anch2,br,anch3,divMain2);
let sd=document.querySelector("#botdiv2 div:first-child")
sdData=["Roku","Fire TV","Google TV","Android TV"];
addPara(sdData,sd)
let st=document.querySelector("#botdiv2 div:first-child+div")
stData=["Samsung","LG","VIZIO","Sony"];
addPara(stData,st)
let gc=document.querySelector("#botdiv2 div:first-child+div+div")
gcData=["PlayStation","Xbox"]
addPara(gcData,gc)
function addPara(data1,appendIn){
data1.forEach(function(ele){
let para=document.createElement("p")
para.innerText=ele;
appendIn.append(para)
})
}
let last=document.createElement("p")
last.innerText="Device availability varies by country or region"
last.setAttribute("class","last")
bottom.append(last)