mirror of
https://github.com/NoCrypt/migu.git
synced 2026-03-11 17:45:32 +00:00
chore: update jassub
feat: losssy subtitle rendering feat: support cat proxies fix: reduce references to cat
This commit is contained in:
parent
37d0d8dece
commit
c92eb1bf23
9 changed files with 49 additions and 26 deletions
|
|
@ -33,7 +33,7 @@ No. This app cannot be ported to android in any way.
|
|||
Yes. For the home menu you can specify a different RSS feed to check when the app looks for new releases. Additionally you can just paste a torrent file/magnet link anywhere when using the app, and it will auto-detect what anime is playing.
|
||||
|
||||
## **Can I change what tracker torrents are found from?**
|
||||
Not really. No other tracker has the kind of API/search functionality that Nyaa does, which the app uses to the fullest extent to make sure it finds the torrents it's looking for without false-positives.
|
||||
Not really. No other tracker has the kind of API/search functionality which is required, which Miru uses to the fullest extent to make sure it finds the torrents it's looking for without false-positives.
|
||||
|
||||
## **How is this different from sequential qBit?**
|
||||
Unlike qBit's sequential, this will prioritise downloading torrent pieces directly needed for playback, which with the user seeking isn't always just sequential.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "Miru",
|
||||
"version": "3.10.8",
|
||||
"version": "3.11.0",
|
||||
"author": "ThaUnknown_ <ThaUnknown@users.noreply.github.com>",
|
||||
"description": "Stream anime torrents, real-time with no waiting for downloads.",
|
||||
"main": "src/index.js",
|
||||
|
|
@ -111,7 +111,7 @@
|
|||
"discord-rpc": "4.0.1",
|
||||
"electron-log": "^4.4.8",
|
||||
"electron-updater": "^4.6.5",
|
||||
"jassub": "1.6.2",
|
||||
"jassub": "1.7.1",
|
||||
"js-levenshtein": "^1.1.6",
|
||||
"matroska-subtitles": "github:ThaUnknown/matroska-subtitles#redist",
|
||||
"mime": "^3.0.0",
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ specifiers:
|
|||
electron-log: ^4.4.8
|
||||
electron-notarize: ^1.2.2
|
||||
electron-updater: ^4.6.5
|
||||
jassub: 1.6.2
|
||||
jassub: 1.7.1
|
||||
js-levenshtein: ^1.1.6
|
||||
matroska-subtitles: github:ThaUnknown/matroska-subtitles#redist
|
||||
mime: ^3.0.0
|
||||
|
|
@ -35,7 +35,7 @@ dependencies:
|
|||
discord-rpc: 4.0.1
|
||||
electron-log: 4.4.8
|
||||
electron-updater: 4.6.5
|
||||
jassub: 1.6.2
|
||||
jassub: 1.7.1
|
||||
js-levenshtein: 1.1.6
|
||||
matroska-subtitles: github.com/ThaUnknown/matroska-subtitles/446d0628ff0bcf13eb95184777615f3a0e6d8ae8
|
||||
mime: 3.0.0
|
||||
|
|
@ -1858,8 +1858,8 @@ packages:
|
|||
minimatch: 3.1.2
|
||||
dev: true
|
||||
|
||||
/jassub/1.6.2:
|
||||
resolution: {integrity: sha512-xmQlG+Dzs6jHouCFw6VjWAl01PSkCA/1w91zDgCsWXMPFWvsMdcx65UohxL2RsZoEn/mSTSLHnaPHSCJvTaaWg==}
|
||||
/jassub/1.7.1:
|
||||
resolution: {integrity: sha512-xvrF/4/4ifJCxyF9wgmNW/fzvKuqrvU3OKl1B4373STaCPhblMHkRCHDN6DnRdeI9jUyriWDPcKT97cg38YbNw==}
|
||||
dependencies:
|
||||
rvfc-polyfill: 1.0.4
|
||||
dev: false
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@
|
|||
import Menubar from './lib/Menubar.svelte'
|
||||
import Toasts from './lib/Toasts.svelte'
|
||||
import 'quartermoon/css/quartermoon-variables.css'
|
||||
import NyaaBlock from './lib/NyaaBlock.svelte'
|
||||
import CatBlock from './lib/CatBlock.svelte'
|
||||
import { wrapEnter } from '@/modules/util.js'
|
||||
|
||||
setContext('view', view)
|
||||
|
|
@ -44,7 +44,7 @@
|
|||
on:click={() => ($sidebar = !$sidebar)} on:keydown={wrapEnter(() => ($sidebar = !$sidebar))}
|
||||
tabindex='0'
|
||||
role='button' />
|
||||
<NyaaBlock />
|
||||
<CatBlock />
|
||||
<Menubar />
|
||||
<Sidebar bind:page={$page} />
|
||||
<Router bind:page={$page} />
|
||||
|
|
|
|||
|
|
@ -1,11 +1,12 @@
|
|||
<script>
|
||||
import { set } from '@/lib/Settings.svelte'
|
||||
let block = false
|
||||
|
||||
async function testConnection () {
|
||||
try {
|
||||
for (let i = 0; i < 2; ++i) {
|
||||
// fetch nyaa twice, sometimes it will go tru once if ISP is shitty
|
||||
await fetch('https://nyaa.si')
|
||||
// fetch cat twice, sometimes it will go tru once if ISP is shitty
|
||||
await fetch(set.catURL)
|
||||
}
|
||||
block = false
|
||||
} catch (e) {
|
||||
|
|
@ -86,9 +86,9 @@
|
|||
return DOMPARSER(await res.text(), 'text/xml')
|
||||
}
|
||||
const rssmap = {
|
||||
SubsPlease: 'https://nyaa.si/?page=rss&c=0_0&f=0&u=subsplease&q=',
|
||||
'Erai-raws [Multi-Sub]': 'https://nyaa.si/?page=rss&c=0_0&f=0&u=Erai-raws&q=',
|
||||
'NC-Raws': 'https://nyaa.si/?page=rss&c=0_0&f=0&u=BraveSail&q='
|
||||
SubsPlease: `${set.catURL}/?page=rss&c=0_0&f=0&u=subsplease&q=`,
|
||||
'Erai-raws [Multi-Sub]': `${set.catURL}/?page=rss&c=0_0&f=0&u=Erai-raws&q=`,
|
||||
'NC-Raws': `${set.catURL}/?page=rss&c=0_0&f=0&u=BraveSail&q=`
|
||||
}
|
||||
const epstring = ep => `"E${zeropad(ep)}+"|"E${zeropad(ep)}v"|"+${zeropad(ep)}+"|"+${zeropad(ep)}v"`
|
||||
export function getReleasesRSSurl (val) {
|
||||
|
|
@ -131,7 +131,7 @@
|
|||
|
||||
const excl = exclusions.join('|')
|
||||
const quality = (!ignoreQuality && (`"${settings.rssQuality}"` || '"1080"')) || ''
|
||||
const url = new URL(`https://nyaa.si/?page=rss&c=1_2&f=0&s=seeders&o=desc&q=(${titles})${ep}${quality}-(${excl})`)
|
||||
const url = new URL(`${set.catURL}/?page=rss&c=1_2&f=0&s=seeders&o=desc&q=(${titles})${ep}${quality}-(${excl})`)
|
||||
|
||||
let nodes = [...(await getRSSContent(url)).querySelectorAll('item')]
|
||||
|
||||
|
|
@ -141,7 +141,7 @@
|
|||
// we want the dates of the target media as the S1 title might be used for SX releases
|
||||
const titles = createTitle(absolute.media).join(')|(')
|
||||
|
||||
const url = new URL(`https://nyaa.si/?page=rss&c=1_2&f=0&s=seeders&o=desc&q=(${titles})${epstring(absoluteep)}${quality}-(${excl})`)
|
||||
const url = new URL(`${set.catURL}/?page=rss&c=1_2&f=0&s=seeders&o=desc&q=(${titles})${epstring(absoluteep)}${quality}-(${excl})`)
|
||||
nodes = [...nodes, ...(await getRSSContent(url)).querySelectorAll('item')]
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,9 @@
|
|||
subtitleLanguage: 'eng',
|
||||
audioLanguage: 'jpn',
|
||||
enableDoH: false,
|
||||
doHURL: 'https://cloudflare-dns.com/dns-query'
|
||||
doHURL: 'https://cloudflare-dns.com/dns-query',
|
||||
disableSubtitleBlur: false,
|
||||
catURL: decodeURIComponent(atob('aHR0cHMlM0ElMkYlMkZueWFhLnNp'))
|
||||
}
|
||||
localStorage.removeItem('relations') // TODO: remove
|
||||
export const set = { ...defaults, ...(JSON.parse(localStorage.getItem('settings')) || {}) }
|
||||
|
|
@ -243,6 +245,14 @@
|
|||
<input type='checkbox' id='player-pause' bind:checked={settings.playerPause} />
|
||||
<label for='player-pause'>Pause When Tabbing Out</label>
|
||||
</div>
|
||||
<div
|
||||
class='custom-switch mb-10 pl-10 font-size-16 w-300'
|
||||
data-toggle='tooltip'
|
||||
data-placement='bottom'
|
||||
data-title='Disables Blur When Rendering Subtitles Reducing Lag, Will Cause Text And Subtitle Edges To Appear Sharper'>
|
||||
<input type='checkbox' id='player-sub-blur' bind:checked={settings.disableSubtitleBlur} />
|
||||
<label for='player-sub-blur'>Fast Subtitle Rendering</label>
|
||||
</div>
|
||||
<div class='col p-10 d-flex flex-column justify-content-end'>
|
||||
<div class='font-size-24 font-weight-semi-bold d-flex'>
|
||||
<div class='material-icons mr-10 font-size-30'>list</div>
|
||||
|
|
@ -332,11 +342,11 @@
|
|||
<span class='input-group-text w-100 justify-content-center'>Feed</span>
|
||||
</div>
|
||||
<input type='text' class='form-control form-control-lg w-150 flex-reset' placeholder='New Releases' autocomplete='off' bind:value={settings.rssFeeds[i][0]} />
|
||||
<input id='rss-feed-{i}' type='text' list='rss-feed-list-{i}' class='w-400 form-control form-control-lg' placeholder='https://nyaa.si/?page=rss&c=0_0&f=0&q=' autocomplete='off' bind:value={settings.rssFeeds[i][1]} />
|
||||
<input id='rss-feed-{i}' type='text' list='rss-feed-list-{i}' class='w-400 form-control form-control-lg' placeholder={set.catURL + '/?page=rss&c=0_0&f=0&q='} autocomplete='off' bind:value={settings.rssFeeds[i][1]} />
|
||||
<datalist id='rss-feed-list-{i}'>
|
||||
<option value='SubsPlease'>https://nyaa.si/?page=rss&c=0_0&f=0&u=subsplease&q=</option>
|
||||
<option value='NC-Raws'>https://nyaa.si/?page=rss&c=0_0&f=0&u=BraveSail&q=</option>
|
||||
<option value='Erai-raws [Multi-Sub]'>https://nyaa.si/?page=rss&c=0_0&f=0&u=Erai-raws&q=</option>
|
||||
<option value='SubsPlease'>{set.catURL + '/?page=rss&c=0_0&f=0&u=subsplease&q='}</option>
|
||||
<option value='NC-Raws'>{set.catURL + '/?page=rss&c=0_0&f=0&u=BraveSail&q='}</option>
|
||||
<option value='Erai-raws [Multi-Sub]'>{set.catURL + '/?page=rss&c=0_0&f=0&u=Erai-raws&q='}</option>
|
||||
</datalist>
|
||||
<div class='input-group-append'>
|
||||
<button type='button' on:click={() => { settings.rssFeeds.splice(i, 1); settings.rssFeeds = settings.rssFeeds }} class='btn btn-danger btn-lg input-group-append'>Remove</button>
|
||||
|
|
@ -370,7 +380,7 @@
|
|||
class='custom-switch mb-10 pl-10 font-size-16 w-300'
|
||||
data-toggle='tooltip'
|
||||
data-placement='bottom'
|
||||
data-title='Enables DNS Over HTTPS, useful if your ISP blocks certain domains'>
|
||||
data-title='Enables DNS Over HTTPS, Useful If Your ISP Blocks Certain Domains'>
|
||||
<input type='checkbox' id='rss-dohtoggle' bind:checked={settings.enableDoH} />
|
||||
<label for='rss-dohtoggle'>Enable DoH</label>
|
||||
</div>
|
||||
|
|
@ -378,12 +388,22 @@
|
|||
class='input-group input-group-lg form-control-lg mb-10 w-500'
|
||||
data-toggle='tooltip'
|
||||
data-placement='bottom'
|
||||
data-title='Path To Folder Which To Use To Store Torrent Files'>
|
||||
data-title='What URL To Use For DoH'>
|
||||
<div class='input-group-prepend'>
|
||||
<span class='input-group-text w-150 justify-content-center'>DoH URL</span>
|
||||
</div>
|
||||
<input type='text' class='form-control' bind:value={settings.doHURL} placeholder={defaults.doHURL} />
|
||||
</div>
|
||||
<div
|
||||
class='input-group input-group-lg form-control-lg mb-10 w-500'
|
||||
data-toggle='tooltip'
|
||||
data-placement='bottom'
|
||||
data-title='URL For The Cat, Change If You Want To Use Your Own Proxy'>
|
||||
<div class='input-group-prepend'>
|
||||
<span class='input-group-text w-150 justify-content-center'>Cat URL</span>
|
||||
</div>
|
||||
<input type='text' class='form-control' bind:value={settings.catURL} placeholder={defaults.catURL} />
|
||||
</div>
|
||||
</div>
|
||||
</Tab>
|
||||
<Tab>
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
import { add } from './torrent.js'
|
||||
import { DOMPARSER, PromiseBatch } from './util.js'
|
||||
import { alRequest, alSearch } from './anilist.js'
|
||||
import anitomyscript from 'anitomyscript'
|
||||
import 'anitomyscript/dist/anitomyscript.wasm?url'
|
||||
import anitomyscript from 'anitomyscript'
|
||||
import { media } from '@/lib/Player/MediaHandler.svelte'
|
||||
import { addToast } from '@/lib/Toasts.svelte'
|
||||
import { view } from '@/App.svelte'
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import JASSUB from 'jassub'
|
||||
import workerUrl from 'jassub/dist/jassub-worker.js?url'
|
||||
import 'jassub/dist/jassub-worker.wasm?url'
|
||||
import modernWasmUrl from 'jassub/dist/jassub-worker-modern.wasm?url'
|
||||
import { toTS, videoRx, subRx } from './util.js'
|
||||
import { set } from '@/lib/Settings.svelte'
|
||||
|
||||
|
|
@ -163,7 +163,9 @@ export default class Subtitles {
|
|||
'roboto medium': './Roboto.ttf'
|
||||
},
|
||||
workerUrl,
|
||||
useLocalFonts: set.missingFont
|
||||
modernWasmUrl,
|
||||
useLocalFonts: set.missingFont,
|
||||
dropAllBlur: set.disableSubtitleBlur
|
||||
}
|
||||
if (set.font) {
|
||||
options.availableFonts[set.font.name.toLowerCase()] = new Uint8Array(set.font.data)
|
||||
|
|
|
|||
Loading…
Reference in a new issue