Spaces:
Running
Running
Update index.html
Browse files- index.html +34 -138
index.html
CHANGED
@@ -16,24 +16,6 @@
|
|
16 |
h1 {
|
17 |
margin-bottom: 40px;
|
18 |
}
|
19 |
-
.server-info {
|
20 |
-
background: #444;
|
21 |
-
padding: 20px;
|
22 |
-
border-radius: 10px;
|
23 |
-
display: inline-block;
|
24 |
-
margin-bottom: 20px;
|
25 |
-
}
|
26 |
-
.images {
|
27 |
-
display: flex;
|
28 |
-
justify-content: center;
|
29 |
-
gap: 20px;
|
30 |
-
margin-bottom: 20px;
|
31 |
-
}
|
32 |
-
.images img {
|
33 |
-
width: 200px;
|
34 |
-
height: auto;
|
35 |
-
border-radius: 10px;
|
36 |
-
}
|
37 |
.balloons {
|
38 |
display: flex;
|
39 |
justify-content: center;
|
@@ -53,139 +35,53 @@
|
|
53 |
min-width: 220px;
|
54 |
text-align: center;
|
55 |
}
|
56 |
-
.
|
57 |
-
|
58 |
-
background: #FF5722;
|
59 |
-
color: white;
|
60 |
-
padding: 10px 20px;
|
61 |
-
border-radius: 10px;
|
62 |
-
text-decoration: none;
|
63 |
-
font-size: 18px;
|
64 |
-
font-weight: bold;
|
65 |
-
margin-top: 20px;
|
66 |
-
width: 225px; /* Aqui definimos a largura fixa */
|
67 |
-
text-align: center;
|
68 |
-
}
|
69 |
-
|
70 |
-
/* Estilo para o mini botão */
|
71 |
-
.update-btn {
|
72 |
-
display: inline-block;
|
73 |
-
background: #00BFAE;
|
74 |
-
color: white;
|
75 |
-
padding: 8px 16px;
|
76 |
-
border-radius: 10px;
|
77 |
-
text-decoration: none;
|
78 |
-
font-size: 14px;
|
79 |
-
font-weight: bold;
|
80 |
-
margin-top: 40px;
|
81 |
-
width: auto;
|
82 |
-
text-align: center;
|
83 |
-
}
|
84 |
-
|
85 |
-
/* Estilo para a tela preta */
|
86 |
-
.overlay {
|
87 |
-
position: fixed;
|
88 |
-
top: 0;
|
89 |
-
left: 0;
|
90 |
-
width: 100%;
|
91 |
-
height: 100%;
|
92 |
-
background-color: rgba(0, 0, 0, 0.7);
|
93 |
-
display: none;
|
94 |
-
justify-content: center;
|
95 |
-
align-items: center;
|
96 |
-
z-index: 1000;
|
97 |
-
}
|
98 |
-
|
99 |
-
/* Caixa de conteúdo das atualizações */
|
100 |
-
.update-content {
|
101 |
-
background-color: #333;
|
102 |
-
color: white;
|
103 |
-
padding: 30px;
|
104 |
-
border-radius: 10px;
|
105 |
-
width: 80%;
|
106 |
-
max-width: 600px;
|
107 |
-
text-align: left;
|
108 |
-
font-size: 18px;
|
109 |
-
}
|
110 |
-
|
111 |
-
/* Botão de fechar */
|
112 |
-
.close-btn {
|
113 |
-
display: inline-block;
|
114 |
-
background: #FF5722;
|
115 |
-
color: white;
|
116 |
-
padding: 10px 20px;
|
117 |
-
border-radius: 10px;
|
118 |
-
text-decoration: none;
|
119 |
-
font-size: 18px;
|
120 |
-
font-weight: bold;
|
121 |
-
margin-top: 20px;
|
122 |
-
text-align: center;
|
123 |
}
|
124 |
</style>
|
125 |
</head>
|
126 |
<body>
|
127 |
-
<h1>Bem-vindo ao Servidor de Minecraft
|
128 |
-
|
129 |
-
<div class="images">
|
130 |
-
<img src="https://i.imgur.com/zsmEYPR.png" alt="Imagem 1">
|
131 |
-
<img src="https://i.imgur.com/SaNVNqS.jpeg" alt="Imagem 2">
|
132 |
-
</div>
|
133 |
-
|
134 |
-
<h2>Original</h2>
|
135 |
-
<div class="server-info">
|
136 |
-
<p><strong>Nome:</strong> THE DWELLERS (JAVA)</p>
|
137 |
-
<p><strong>IP:</strong> THEDWELLERS_.aternos.me</p>
|
138 |
-
</div>
|
139 |
-
|
140 |
-
<h2>Pirata</h2>
|
141 |
-
<div class="server-info">
|
142 |
-
<p><strong>Nome:</strong> Castles and Fortress (JAVA)</p>
|
143 |
-
<p><strong>IP:</strong> SOBREVIVENCIA_HARD.aternos.me:21355</p>
|
144 |
-
</div>
|
145 |
-
|
146 |
<h2>Canais</h2>
|
147 |
<div class="balloons">
|
148 |
-
<a href="https://www.twitch.tv/gui1325" target="_blank">Canal
|
149 |
-
<a href="https://www.twitch.tv/alatolouco" target="_blank">Canal
|
150 |
</div>
|
151 |
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
|
|
158 |
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
</div>
|
163 |
|
164 |
-
|
165 |
-
|
|
|
|
|
|
|
|
|
166 |
|
167 |
-
|
168 |
-
|
169 |
-
<div class="update-content">
|
170 |
-
<h2>Futuras Atualizações:</h2>
|
171 |
-
<p>1. Adição de novos servidores.</p>
|
172 |
-
<p>2. Melhorias no sistema de download.</p>
|
173 |
-
<p>3. Novas funcionalidades no servidor.</p>
|
174 |
-
<p>4. Status sobre os servdidores.</p>
|
175 |
-
<a href="#" class="close-btn" onclick="closeUpdates()">Fechar</a>
|
176 |
-
</div>
|
177 |
-
</div>
|
178 |
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
|
|
|
|
|
|
183 |
}
|
184 |
|
185 |
-
|
186 |
-
|
187 |
-
document.getElementById("updateOverlay").style.display = "none";
|
188 |
-
}
|
189 |
</script>
|
190 |
</body>
|
191 |
-
</html>
|
|
|
16 |
h1 {
|
17 |
margin-bottom: 40px;
|
18 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
.balloons {
|
20 |
display: flex;
|
21 |
justify-content: center;
|
|
|
35 |
min-width: 220px;
|
36 |
text-align: center;
|
37 |
}
|
38 |
+
.live {
|
39 |
+
background: red !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
}
|
41 |
</style>
|
42 |
</head>
|
43 |
<body>
|
44 |
+
<h1>Bem-vindo ao Servidor de Minecraft</h1>
|
45 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
<h2>Canais</h2>
|
47 |
<div class="balloons">
|
48 |
+
<a id="streamer1" href="https://www.twitch.tv/gui1325" target="_blank">Canal do gui1325</a>
|
49 |
+
<a id="streamer2" href="https://www.twitch.tv/alatolouco" target="_blank">Canal do alatolouco</a>
|
50 |
</div>
|
51 |
|
52 |
+
<script>
|
53 |
+
const clientId = "SEU_CLIENT_ID"; // Substitua pelo seu client_id da Twitch
|
54 |
+
const accessToken = "SEU_ACCESS_TOKEN"; // Gere um token temporário usando a API da Twitch
|
55 |
+
const streamers = [
|
56 |
+
{ id: "streamer1", name: "gui1325" },
|
57 |
+
{ id: "streamer2", name: "alatolouco" }
|
58 |
+
];
|
59 |
|
60 |
+
async function checkLiveStatus() {
|
61 |
+
const streamerNames = streamers.map(s => s.name).join("&user_login=");
|
62 |
+
const url = `https://api.twitch.tv/helix/streams?user_login=${streamerNames}`;
|
|
|
63 |
|
64 |
+
const response = await fetch(url, {
|
65 |
+
headers: {
|
66 |
+
"Client-ID": clientId,
|
67 |
+
"Authorization": `Bearer ${accessToken}`
|
68 |
+
}
|
69 |
+
});
|
70 |
|
71 |
+
const data = await response.json();
|
72 |
+
const liveStreamers = data.data.map(stream => stream.user_login);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
73 |
|
74 |
+
streamers.forEach(({ id, name }) => {
|
75 |
+
const button = document.getElementById(id);
|
76 |
+
if (liveStreamers.includes(name)) {
|
77 |
+
button.classList.add("live");
|
78 |
+
button.textContent = `🔴 ${name} - Assistir agora!`;
|
79 |
+
}
|
80 |
+
});
|
81 |
}
|
82 |
|
83 |
+
checkLiveStatus();
|
84 |
+
setInterval(checkLiveStatus, 60000); // Atualiza a cada 60 segundos
|
|
|
|
|
85 |
</script>
|
86 |
</body>
|
87 |
+
</html>
|