import stringToHTML from "../stringToHTML";
import { openPopup } from "./PopupManager";
export function OpenMinecraftServerPopup() {
if (!document.querySelector('link[href*="minecraftia"]')) {
const fontLink = document.createElement("link");
fontLink.href = "https://fonts.cdnfonts.com/css/minecraftia";
fontLink.rel = "stylesheet";
document.head.appendChild(fontLink);
}
const header = stringToHTML(
/* html */
`
`,
).firstChild as HTMLElement;
const imageContainer = document.createElement("div");
imageContainer.classList.add("whatsnewImgContainer");
const video = document.createElement("video");
video.style.aspectRatio = "16/9";
video.style.background = "black";
const source = document.createElement("source");
source.setAttribute(
"src",
"https://raw.githubusercontent.com/BetterSEQTA/BetterSEQTA-Plus/main/src/resources/server-video.mp4",
);
video.autoplay = true;
video.muted = true;
video.loop = true;
video.appendChild(source);
video.classList.add("whatsnewImg");
imageContainer.appendChild(video);
const text = stringToHTML(/* html */ `
Join our community in Minecraft!
Join the official BetterSEQTA+ Minecraft Server community now!
Server Features
- SMP as our first release gamemode
- Community events and competitions
- Custom world generation
- Shop system with buying and selling
- Regular updates and maintenance
- The End dimension will be enabled during an upcoming live event
mc.betterseqta.org
Version: 1.21.4
`).firstChild as HTMLElement;
const footer = stringToHTML(/* html */ `
`).firstChild as HTMLElement;
openPopup({
header,
content: [imageContainer, text, footer],
});
}