Skip to content

Commit

Permalink
optimized update in entry manager, and fixed entry filters
Browse files Browse the repository at this point in the history
  • Loading branch information
u-Kuro committed Jul 22, 2024
1 parent d901e5c commit 67a055a
Show file tree
Hide file tree
Showing 26 changed files with 33 additions and 37 deletions.
Binary file modified Kanshi.apk
Binary file not shown.
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ android {
applicationId "com.example.kanshi"
minSdk 21
targetSdk 34
versionCode 438
versionName "9.0.8"
versionCode 439
versionName "9.0.9"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
Expand Down
Binary file modified android/app/release/Kanshi.apk
Binary file not shown.
4 changes: 2 additions & 2 deletions android/app/release/output-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"type": "SINGLE",
"filters": [],
"attributes": [],
"versionCode": 438,
"versionName": "9.0.8",
"versionCode": 439,
"versionName": "9.0.9",
"outputFile": "app-release.apk"
}
],
Expand Down
2 changes: 1 addition & 1 deletion android/app/src/main/assets/build/bundle.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion android/app/src/main/assets/build/bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion android/app/src/main/assets/build/bundle.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion android/app/src/main/assets/webapi/worker/animeLoader.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion android/app/src/main/assets/webapi/worker/animeManager.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Binary file modified docs/Kanshi.apk
Binary file not shown.
2 changes: 1 addition & 1 deletion docs/build/bundle.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/build/bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/build/bundle.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/version.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
438
439
2 changes: 1 addition & 1 deletion docs/webapi/worker/animeLoader.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/webapi/worker/animeManager.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/webapi/worker/getFilterOptions.js

Large diffs are not rendered by default.

Binary file modified public/Kanshi.apk
Binary file not shown.
2 changes: 1 addition & 1 deletion public/version.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
438
439
2 changes: 1 addition & 1 deletion public/webapi/worker/animeLoader.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/webapi/worker/animeManager.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/webapi/worker/getFilterOptions.js

Large diffs are not rendered by default.

16 changes: 4 additions & 12 deletions src/components/Anime/AnimeGrid.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -659,25 +659,17 @@
{#if !$android && shouldShowGoBackInFullView && $loadedAnimeLists?.[mainCategory]?.animeList?.length}
<!-- svelte-ignore a11y-no-noninteractive-tabindex -->
<div
class="{'go-back-grid' +
(shouldShowGoBackInFullView ? ' fullView' : '')}"
class="go-back-grid fullView"
tabindex="{$menuVisible || $popupVisible ? '' : '0'}"
on:click="{goBackGrid}"
on:keyup="{(e) => e.key === 'Enter' && goBackGrid(e)}"
in:fade="{{ duration: 200, easing: sineOut }}"
out:fade="{{ duration: 200, easing: sineOut }}"
>
<svg
viewBox="{`0 0 ${
shouldShowGoBackInFullView ? '320' : '448'
} 512`}"
viewBox="0 0 320 512"
>
<path
d="{// angle left
shouldShowGoBackInFullView
? 'M41 233a32 32 0 0 0 0 46l160 160a32 32 0 0 0 46-46L109 256l138-137a32 32 0 0 0-46-46L41 233z'
: // angle up
'M201 137c13-12 33-12 46 0l160 160a32 32 0 0 1-46 46L224 205 87 343a32 32 0 0 1-46-46l160-160z'}"
<path d="M41 233a32 32 0 0 0 0 46l160 160a32 32 0 0 0 46-46L109 256l138-137a32 32 0 0 0-46-46L41 233z"
></path>
</svg>
</div>
Expand Down Expand Up @@ -968,7 +960,7 @@
.go-back-grid {
position: fixed !important;
top: unset !important;
bottom: 48px !important;
bottom: 80px !important;
right: 30px !important;
transform: translateZ(0) !important;
-webkit-transform: translateZ(0) !important;
Expand Down
10 changes: 7 additions & 3 deletions src/js/workerUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ function getAnimeLoaderWorker() {
if (animeLoaderWorker) return animeLoaderWorker
if (animeLoaderWorkerPromise) return animeLoaderWorkerPromise
animeLoaderWorkerPromise = new Promise(async (resolve) => {
resolve(new Worker(await cacheRequest("./webapi/worker/animeLoader.js", 19947, "Checking existing List")))
resolve(new Worker(await cacheRequest("./webapi/worker/animeLoader.js", 20298, "Checking existing List")))
animeLoaderWorkerPromise = null
})
return animeLoaderWorkerPromise
Expand Down Expand Up @@ -243,7 +243,7 @@ function getAnimeManagerWorker() {
if (animeManagerWorker) return animeManagerWorker
if (animeManagerWorkerPromise) return animeManagerWorkerPromise
animeManagerWorkerPromise = new Promise(async (resolve) => {
resolve(new Worker(await cacheRequest("./webapi/worker/animeManager.js", 60605, "Updating the List")))
resolve(new Worker(await cacheRequest("./webapi/worker/animeManager.js", 61028, "Updating the List")))
animeManagerWorkerPromise = null
})
return animeManagerWorkerPromise
Expand Down Expand Up @@ -305,10 +305,14 @@ const animeManager = (_data = {}) => {
animeIdxRemoved.set(removedIdx)
}
return
} else if (hasOwnProp.call(data, "removedPostWork")) {
--workerCount
return
}

let postId = data.postId
--workerCount
if (workerCount < 0) workerCount = 0

if (
hasOwnProp.call(data, "updateUserList") ||
Expand Down Expand Up @@ -1390,7 +1394,7 @@ const getFilterOptions = (_data) => {
return new Promise((resolve, reject) => {
if (getFilterOptionsTerminateTimeout) clearTimeout(getFilterOptionsTerminateTimeout)
getFilterOptionsWorker?.terminate?.()
cacheRequest("./webapi/worker/getFilterOptions.js", 60874, "Initializing Filters")
cacheRequest("./webapi/worker/getFilterOptions.js", 60341, "Initializing Filters")
.then(url => {
if (getFilterOptionsTerminateTimeout) clearTimeout(getFilterOptionsTerminateTimeout)
getFilterOptionsWorker?.terminate?.()
Expand Down
2 changes: 1 addition & 1 deletion src/version.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const version = 438;
const version = 439;
let webVersionPromise
export default async function getWebVersion() {
if (webVersionPromise) return webVersionPromise
Expand Down

0 comments on commit 67a055a

Please sign in to comment.