mirror of
https://github.com/NoCrypt/migu.git
synced 2026-08-17 04:46:20 +00:00
fix: dashes in RSS
feat: selectable titles, synopsis and details feat: re-add maxConnections
This commit is contained in:
parent
005a6718f4
commit
d119243ad2
7 changed files with 26 additions and 7 deletions
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "Miru",
|
||||
"version": "3.5.5",
|
||||
"version": "3.5.6",
|
||||
"author": "ThaUnknown_ <ThaUnknown@users.noreply.github.com>",
|
||||
"description": "Stream anime torrents, real-time with no waiting for downloads.",
|
||||
"main": "src/index.js",
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ class TorrentClient extends WebTorrent {
|
|||
constructor (settings) {
|
||||
super({
|
||||
dht: !settings.torrentDHT,
|
||||
maxConns: settings.maxConns,
|
||||
downloadLimit: settings.torrentSpeed * 1048576 || 0,
|
||||
uploadLimit: settings.torrentSpeed * 1572864 || 0 // :trolled:
|
||||
})
|
||||
|
|
|
|||
|
|
@ -75,6 +75,9 @@
|
|||
:global(img) {
|
||||
-webkit-user-drag: none;
|
||||
}
|
||||
:global(.select-all) {
|
||||
user-select: all;
|
||||
}
|
||||
/* sidebar patches */
|
||||
.page-wrapper.with-sidebar[data-sidebar-hidden] {
|
||||
--sidebar-width: var(--sidebar-minimised);
|
||||
|
|
|
|||
|
|
@ -231,7 +231,7 @@
|
|||
)
|
||||
]
|
||||
const titles = []
|
||||
for (const t of grouped) {
|
||||
const appendTitle = t => {
|
||||
// replace & with encoded
|
||||
const title = t.replace(/&/g, '%26').replace(/\?/g, '%3F').replace(/#/g, '%23')
|
||||
titles.push(title)
|
||||
|
|
@ -246,6 +246,10 @@
|
|||
titles.push(title.replace(/(\d)(?:nd|rd|th) Season/i, `S${match1[1]}`))
|
||||
}
|
||||
}
|
||||
for (const t of grouped) {
|
||||
appendTitle(t)
|
||||
if (t.includes('-')) appendTitle(t.replaceAll('-', ''))
|
||||
}
|
||||
return titles
|
||||
}
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -12,10 +12,11 @@
|
|||
torrentPersist: false,
|
||||
torrentDHT: false,
|
||||
torrentPeX: false,
|
||||
missingFont: true
|
||||
missingFont: true,
|
||||
maxConns: 20
|
||||
}
|
||||
localStorage.removeItem('relations') // TODO: remove
|
||||
export const set = JSON.parse(localStorage.getItem('settings')) || { ...defaults }
|
||||
export const set = { ...defaults, ...(JSON.parse(localStorage.getItem('settings')) || {}) }
|
||||
if (!set.rssFeeds) { // TODO: remove ;-;
|
||||
if (set.rssFeed) {
|
||||
set.rssFeeds = [['New Releases', set.rssFeed]]
|
||||
|
|
@ -308,6 +309,16 @@
|
|||
<span class='input-group-text'>MB/s</span>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class='input-group w-300 form-control-lg mb-10'
|
||||
data-toggle='tooltip'
|
||||
data-placement='bottom'
|
||||
data-title='Max Amount Of Connections Per Torrent'>
|
||||
<div class='input-group-prepend'>
|
||||
<span class='input-group-text w-200 justify-content-center'>Max Connections</span>
|
||||
</div>
|
||||
<input type='number' bind:value={settings.maxConns} min='1' max='512' class='form-control text-right form-control-lg' />
|
||||
</div>
|
||||
<div
|
||||
class='custom-switch mb-10 pl-10 font-size-16 w-300'
|
||||
data-toggle='tooltip'
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@
|
|||
{detail.icon}
|
||||
</div>
|
||||
<div class='d-flex flex-column justify-content-center text-nowrap'>
|
||||
<div class='font-weight-bold'>
|
||||
<div class='font-weight-bold select-all'>
|
||||
{#if detail.custom === 'property'}
|
||||
{getCustomProperty(detail, media)}
|
||||
{:else if property.constructor === Array}
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@
|
|||
<div class='col-md-9 col-8 row align-content-end pl-20'>
|
||||
<div class='col-md-8 col-12 d-flex justify-content-end flex-column'>
|
||||
<div class='px-md-20 d-flex flex-column font-size-12'>
|
||||
<span class='title font-weight-bold pb-sm-15 text-white'>
|
||||
<span class='title font-weight-bold pb-sm-15 text-white select-all'>
|
||||
{media.title.userPreferred}
|
||||
</span>
|
||||
<div class='d-flex flex-row font-size-18 pb-sm-15'>
|
||||
|
|
@ -86,7 +86,7 @@
|
|||
<div class='row p-20 px-xl-0 flex-column-reverse flex-md-row'>
|
||||
<div class='col-md-9 px-20'>
|
||||
<h1 class='title font-weight-bold text-white'>Synopsis</h1>
|
||||
<div class='font-size-16 pr-15 pre-wrap'>
|
||||
<div class='font-size-16 pr-15 pre-wrap select-all'>
|
||||
{media.description?.replace(/<[^>]*>/g, '') || ''}
|
||||
</div>
|
||||
<ToggleList list={media.relations?.edges?.filter(({ node }) => node.type === 'ANIME')} let:item title='Relations'>
|
||||
|
|
|
|||
Loading…
Reference in a new issue