feat: improve mobile native impl (#14481)

fix #13529 

#### PR Dependency Tree


* **PR #14481** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Mobile blob caching with file-backed storage for faster loads and
reduced network usage
* Blob decoding with lazy refresh on token-read failures for improved
reliability
  * Full-text search/indexing exposed to mobile apps
* Document sync APIs and peer clock management for robust cross-device
sync

* **Tests**
* Added unit tests covering payload decoding, cache safety, and
concurrency

* **Dependencies**
* Added an LRU cache dependency and a new mobile-shared package for
shared mobile logic
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
DarkSky
2026-02-21 04:13:24 +08:00
committed by GitHub
parent d8cc0acdd0
commit c9bffc13b5
37 changed files with 2325 additions and 866 deletions

View File

@@ -255,6 +255,7 @@ __metadata:
"@affine/core": "workspace:*"
"@affine/env": "workspace:*"
"@affine/i18n": "workspace:*"
"@affine/mobile-shared": "workspace:*"
"@affine/nbstore": "workspace:*"
"@affine/track": "workspace:*"
"@blocksuite/affine": "workspace:*"
@@ -703,6 +704,7 @@ __metadata:
"@affine/env": "workspace:*"
"@affine/graphql": "workspace:*"
"@affine/i18n": "workspace:*"
"@affine/mobile-shared": "workspace:*"
"@affine/native": "workspace:*"
"@affine/nbstore": "workspace:*"
"@affine/track": "workspace:*"
@@ -764,6 +766,17 @@ __metadata:
languageName: unknown
linkType: soft
"@affine/mobile-shared@workspace:*, @affine/mobile-shared@workspace:packages/frontend/apps/mobile-shared":
version: 0.0.0-use.local
resolution: "@affine/mobile-shared@workspace:packages/frontend/apps/mobile-shared"
dependencies:
"@affine/core": "workspace:*"
"@capacitor/core": "npm:^7.0.0"
typescript: "npm:^5.7.2"
vitest: "npm:^3.2.4"
languageName: unknown
linkType: soft
"@affine/mobile@workspace:packages/frontend/apps/mobile":
version: 0.0.0-use.local
resolution: "@affine/mobile@workspace:packages/frontend/apps/mobile"