-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from AN0NCER/develop
October update
- Loading branch information
Showing
36 changed files
with
15,821 additions
and
625 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
let _ids = []; | ||
|
||
export async function ShowInfo(message, id) { | ||
if (_ids.findIndex(x => x == id) != -1) { | ||
return; | ||
} | ||
|
||
_ids.push(id); | ||
|
||
let ismenu = HasMenu() ? "visible" : "none"; | ||
$('body').append(genHtml({ text: message, id: id, menu: ismenu })); | ||
let h = $(`.popup-id-${id} > .popup-content`).height(); | ||
let h_menu = !HasMenu() ? 0 : $('.application-menu').outerHeight(); | ||
if ($('body').hasClass('menuver') && ($('body').attr("data-orientation") == "90" || $('body').attr("data-orientation") == "270")) { | ||
h_menu = 0; | ||
} | ||
|
||
anime({ | ||
targets: `.popup-id-${id}`, | ||
bottom: [-60, h + h_menu + 10], | ||
rotate: [30, 0], | ||
complete: () => { | ||
let i = setInterval(() => { | ||
anime({ | ||
targets: `.popup-id-${id}`, | ||
bottom: -h * 5, | ||
complete: () => { | ||
clearInterval(i); | ||
_ids.splice(_ids.findIndex(x => x == id), 1); | ||
$(`.popup-id-${id}`).remove(); | ||
} | ||
}) | ||
}, 3000); | ||
} | ||
}); | ||
} | ||
|
||
function genHtml({ menu = "visible", text, id } = {}) { | ||
const html = `<div class="popup unselectable popup-menu-${menu} popup-id-${id}"><div class="popup-content">${text}<img src="/images/popup.png" /></div></div>`; | ||
return html; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,39 @@ | ||
let _updateData = undefined; | ||
let _enabled = false; | ||
|
||
|
||
GetOnlineData(); | ||
setInterval(() => { | ||
GetOnlineData(); | ||
}, 299000); | ||
|
||
function GetOnlineData() { | ||
fetch('https://tunime.onrender.com/online').then((respnose) => { | ||
return respnose.json(); | ||
fetch('https://tunime.onrender.com/online').then((response) => { | ||
return response.json(); | ||
}).then((val) => { | ||
_updateData = val; | ||
_enabled = true; | ||
}); | ||
} | ||
|
||
export function GetM3U8(url) { | ||
return new Promise((resolve) => { | ||
fetch("https://anime-m3u8.onrender.com/link-anime", { body: new URLSearchParams({ 'link': 'https:' + url }), method: 'post' }) | ||
.then(function (response) { return response.json(); }) | ||
.then(function (data) { | ||
return resolve(data); | ||
}).catch((res)=>{ | ||
console.error(res); | ||
}); | ||
}); | ||
export const ApiTunime = { | ||
anime: async function (id) { | ||
fetch(`https://tunime.onrender.com/online/${id}/o`).then((response) => { | ||
return response.json(); | ||
}).then((val) => { | ||
console.log(val); | ||
}); | ||
}, | ||
|
||
online: function () { | ||
|
||
}, | ||
|
||
stream: function (url) { | ||
return new Promise((resolve) => { | ||
fetch(`https://anime-m3u8.onrender.com/link-anime`, { body: new URLSearchParams({ 'link': 'https:' + url }), method: 'post' }) | ||
.then(function (response) { return response.json(); }) | ||
.then(function (data) { return resolve(data); }) | ||
.catch((res) => { console.log(res) }); | ||
}); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.