Compare commits

...

10 commits

Author SHA1 Message Date
Omar Najjar
a4f5389fb1 Update manifest.json 2025-09-25 05:03:59 +10:00
Omar Najjar
c5b2059e91 Update manifest.json 2025-09-25 05:00:07 +10:00
Omar Najjar
b6ee887ecc Update index.html 2025-09-25 04:56:48 +10:00
Omar Najjar
369d7f3126 Update index.html 2025-09-25 04:56:28 +10:00
Omar Najjar
4c44e48c4b testing height on mobile 2025-09-25 04:37:00 +10:00
Omar Najjar
9b9c6c257e xx 2025-09-25 04:20:00 +10:00
Omar Najjar
760b34d878 Create .gitignore 2025-09-25 04:12:59 +10:00
Omar Najjar
f51877ea27 xxweb app 2025-09-25 04:12:20 +10:00
Omar Najjar
4e58f3a710
x 2025-04-04 19:41:43 +11:00
Omar Najjar
5028a0afbd
x 2025-04-04 19:38:58 +11:00
4 changed files with 69 additions and 6 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
.DS_Store

View file

@ -11,6 +11,13 @@
<title>Watermelon Movies 🍉</title>
<link rel="icon" type="image/x-icon" href="favicon_watermelon_icon.ico">
<link href="https://cdn.jsdelivr.net/npm/tailwindcss@2.2.19/dist/tailwind.min.css" rel="stylesheet">
<!-- iOS Meta Tags -->
<link rel="manifest" href="/manifest.json">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="default">
<meta name="apple-mobile-web-app-title" content="Watermelon Movies 🍉">
<link rel="apple-touch-icon" href="/icons/apple-touch-icon.png">
<style>
/* Custom styles for movie tiles */
.movie-tile {
@ -135,6 +142,7 @@
.video-modal-content {
padding: 10px;
font-size: 14px;
height: 70vh;
}
.close {
font-size: 24px;
@ -689,7 +697,7 @@
<span class="close">&times;</span>
<div style="border-radius: 10px; width: 100%; overflow: hidden;">
<div id="iframeContainer">
<iframe id="videoIframe" width="100%" height="500px" frameborder="0" allowfullscreen></iframe>
<iframe id="videoIframe" width="100%" height="300px" frameborder="0" allowfullscreen></iframe>
</div>
</div>
@ -752,7 +760,7 @@
let currentImdbId = null;
let currentSeason = 1;
let currentEpisode = 1;
let currentSource = 'player.vidsrc.co'; // Default source
let currentSource = 'vidsrc.cc'; // Default source
// Genre IDs mapping for creating meaningful categories
const genreMap = {
@ -1227,8 +1235,8 @@
// Function to load video from current source
function loadVideoSource() {
let videoUrl;
if (currentSource === 'player.vidsrc.co') {
videoUrl = 'https://player.vidsrc.co/embed/';
if (currentSource === 'vidsrc.cc') {
videoUrl = 'https://vidsrc.cc/v2/embed/';
if (currentMediaType === 'movie') {
videoUrl += `movie/${currentImdbId}`;
} else if (currentMediaType === 'tv') {
@ -1338,8 +1346,8 @@
// Set up alternate source button
document.getElementById('altSourceBtn').addEventListener('click', function() {
// Toggle between sources
currentSource = currentSource === 'player.vidsrc.co' ? 'vidsrc.xyz' : 'player.vidsrc.co';
this.textContent = `Try ${currentSource === 'player.vidsrc.co' ? 'vidsrc.xyz' : 'player.vidsrc.co'}`;
currentSource = currentSource === 'vidsrc.cc' ? 'vidsrc.xyz' : 'vidsrc.cc';
this.textContent = `Try ${currentSource === 'vidsrc.cc' ? 'vidsrc.xyz' : 'vidsrc.cc'}`;
// Reload with new source
loadVideoSource();
@ -1647,6 +1655,18 @@
}
});
}
//Web App, Add to homescreen Service Worker
if ('serviceWorker' in navigator) {
window.addEventListener('load', function() {
navigator.serviceWorker.register('/sw.js').then(function(registration) {
console.log('Service Worker registered with scope:', registration.scope);
}).catch(function(error) {
console.log('Service Worker registration failed:', error);
});
});
}
</script>
</body>
</html>

21
manifest.json Normal file
View file

@ -0,0 +1,21 @@
{
"name": "🍉",
"short_name": "🏴‍☠️",
"description": "The Jews took Hollywood, we're stealing it back",
"start_url": "/",
"display": "standalone",
"background_color": "#32cd32",
"theme_color": "#32cd32",
"icons": [
{
"src": "/icons/androis-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/icons/androis-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
]
}

21
sw.js Normal file
View file

@ -0,0 +1,21 @@
self.addEventListener('install', function(event) {
event.waitUntil(
caches.open('watermelon-movies-cache').then(function(cache) {
return cache.addAll([
'/',
'/index.html',
'/style.css',
'/icons/apple-touch-icon.png',
'/manifest.json'
]);
})
);
});
self.addEventListener('fetch', function(event) {
event.respondWith(
caches.match(event.request).then(function(response) {
return response || fetch(event.request);
})
);
});