subtitle update, FAQ, minor changes

This commit is contained in:
ThaUnknown 2020-09-24 03:16:25 +02:00
parent fbe7d65172
commit 1a2fae2dfc
9 changed files with 222 additions and 45 deletions

View file

@ -13,7 +13,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
<meta name="viewport" content="width=device-width" />
<title>Miru - Torrent streaming made simple!</title>
<title>Miru</title>
<link href="https://cdn.jsdelivr.net/npm/halfmoon@1.1.0/css/halfmoon-variables.min.css" rel="stylesheet">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">

File diff suppressed because one or more lines are too long

View file

@ -1,10 +1,10 @@
let tracks = [],
subtitleStream
function parseSubs(range, stream) {
function parseSubs(stream) {
if (video.src.endsWith(".mkv")) {
if (subtitleStream) {
subtitleStream = subtitleStream.seekTo(range.start)
subtitleStream = new SubtitleStream(subtitleStream)
} else {
subtitleStream = new SubtitleStream()
subtitleStream.once('tracks', function (pTracks) {

View file

@ -130,7 +130,7 @@ function serveFile(file, req) {
res.body = req.method === 'HEAD' ? '' : 'stream'
// parser is really a passthrough mkv stream now
let stream = file.createReadStream(range)
parseSubs(range, stream)
parseSubs(stream)
return [res, req.method === 'GET' && subtitleStream || stream]
}

View file

@ -4,7 +4,7 @@ const CACHE_NAME = 'static-cache-v1';
const FILES_TO_CACHE = [
'offline.html',
'app.html',
'index.html',
'js/animeHandler.js',
'js/bundle.min.js',
'js/playerHandler.js',

71
css.css Normal file

File diff suppressed because one or more lines are too long

92
faq.html Normal file
View file

@ -0,0 +1,92 @@
<!DOCTYPE html>
<html lang="en">
<head>
<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="black">
<meta name="apple-mobile-web-app-title" content="Miru">
<meta name="description" content="Anime torrent streaming, ad free in a simple solution.">
<meta name="theme-color" content="#111417" />
<link rel="apple-touch-icon" href="logo.png">
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
<meta name="viewport" content="width=device-width" />
<link rel="icon" href="logo.png">
<title>Miru - FAQ</title>
<link href="https://cdn.jsdelivr.net/npm/halfmoon@1.1.0/css/halfmoon-variables.min.css" rel="stylesheet" />
</head>
<body class="with-custom-webkit-scrollbars with-custom-css-scrollbars">
<div class="page-wrapper">
<div class="content-wrapper d-flex flex-column">
<a href="/" class="w-200 align-self-center"><img src="logo.png" class="w-200" alt="logo"></a>
<div class="container-lg">
<div class="content">
<h2 class="content-title">
How does it work?
</h2>
<p>
Miru uses WebTorrent and black magic to turn your browser into a P2P client which allows you to
stream existing torrents created by other people, without any third-party servers.
</p>
</div>
<div class="content">
<h2 class="content-title">
Is it legal?
</h2>
<p>
Miru only provides the tools for people to share anime with eachother. Miru doesn't host or
transmit any data.
</p>
</div>
<div class="content">
<h2 class="content-title">
Is it safe?
</h2>
<p>
Since the user downloads and shares copyrighted content, in theory their ISP might be angry
about, in practice streaming a single episode won't do much, however if you want to be safe you
can use a VPN.
</p>
</div>
<div class="content">
<h2 class="content-title">
Are there any limitations?
</h2>
<p>
Yes, since this relies on P2P streaming, sharing content entirely depends on the download and
upload speed of the user and how many available peers a torrent has. You can help increase the
number of initial peers by upvoting *this* pull request on GitHub.
</p>
</div>
<div class="content">
<h2 class="content-title">
What's your subtitle support?
</h2>
<p>
Miru uses VTTCues inside the video element itself to display softcoded subtitles, meaning it
should work on any platform and support many devices however it doesn't display subtitles inside
PiP windows. Miru only supports subtitles embedded inside the video file [SSA, UTF8, VTT, SRT*]
in almost any video format, but doesn't support external subtitle files [yet].
</p>
</div>
<div class="content">
<h2 class="content-title">
How do you download?
</h2>
<p>
As you select an anime to play it automatically starts downloading, then you need to wait for
WebTorrent to download it fully to be able to save it to your drive.
</p>
</div>
</div>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/halfmoon@1.1.0/js/halfmoon.min.js"></script>
</body>
</html>

View file

@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" class="auto-scaling-disabled">
<html lang="en">
<head>
<link rel="manifest" href="manifest.json">
@ -17,57 +17,71 @@
<link rel="icon" href="logo.png">
<title>Miru - Torrent streaming made simple!</title>
<link href="css.css" rel="stylesheet">
<link href="https://cdn.jsdelivr.net/npm/halfmoon@1.1.0/css/halfmoon-variables.min.css" rel="stylesheet" />
<script>
window.onload = ()=> {
let deferredPrompt;
window.addEventListener('beforeinstallprompt', (e) => {
e.preventDefault();
deferredPrompt = e;
});
document.querySelector(".btn").addEventListener('click', (e) => {
deferredPrompt.prompt();
deferredPrompt.userChoice.then((choiceResult) => {
if (choiceResult.outcome === 'accepted') {
document.location.href = "/app/app.html"
}
window.onload = () => {
navigator.serviceWorker.register('sw.js')
let deferredPrompt;
window.addEventListener('beforeinstallprompt', (e) => {
e.preventDefault();
deferredPrompt = e;
});
});
}
document.querySelector(".btn").addEventListener('click', (e) => {
deferredPrompt.prompt();
deferredPrompt.userChoice.then((choiceResult) => {
if (choiceResult.outcome === 'accepted') {
document.location.href = "/app/#browse"
}
});
});
}
</script>
</head>
<body class="with-custom-webkit-scrollbars with-custom-css-scrollbars">
<div class="page-wrapper">
<div class="content-wrapper">
<div class="content-wrapper d-lg-flex align-items-lg-center">
<div class="container-lg">
<div class="row">
<div class="col-lg-8">
<div class="content">
<h1 class="font-weight-medium">
Miru - Anime torrent streaming, ad free in a simple solution.
</h1>
<p class="font-size-18">
Miru is an otaku's dream, a website which allows you to stream and download anime torrents
directly in the browser as soon as they are released. Accessible on any platform and device. Anime in original quality with
no buffering, no ads, no delays, everything done client-side for free.
</p>
<div class="mt-20">
<div class="btn btn-primary" role="button">
Add app
</div>
<div class="page-wrapper with-navbar-fixed-bottom">
<div class="par particle-1"></div>
<div class="par particle-2"></div>
<div class="par particle-3"></div>
<div class="par particle-4"></div>
<div class="content-wrapper d-lg-flex align-items-lg-center">
<div class="container-lg">
<div class="row">
<div class="col-lg-8">
<div class="content">
<h1 class="font-weight-medium">
Miru - Anime torrent streaming, ad free in a simple solution.
</h1>
<p class="font-size-18">
Miru is an otaku's dream, a website which allows you to stream and download anime
torrents
directly in the browser as soon as they are released. Accessible on any platform and
device. Anime in original quality with
no buffering, no ads, no delays, everything done client-side for free.
</p>
<div class="mt-20">
<div class="btn btn-primary" role="button">
Add app
</div>
</div>
</div>
<div class="col-lg-4 d-flex align-items-center justify-content-center">
<img class="w-400" alt="char" src="/char.png">
</div>
</div>
<div class="col-lg-4 d-flex align-items-center justify-content-center">
<img class="w-400" alt="char" src="/char.png">
</div>
</div>
</div>
</div>
<nav class="navbar navbar-fixed-bottom justify-content-center">
<a href="/faq.html">
FAQ
</a>
<span class="navbar-text">
© Copyright 2020, Miru
</span>
</nav>
</div>
<script src="https://cdn.jsdelivr.net/npm/halfmoon@1.1.0/js/halfmoon.min.js"></script>
</body>

View file

@ -1,7 +1,7 @@
{
"name": "Miru",
"short_name": "Miru",
"start_url": "/app/app.html",
"start_url": "/app/#browse",
"display": "fullscreen",
"categories": [
"entertainment"