Skip exchange PnL sync on hub iframe soft nav to fix slow records tab.

Remove hover prefetch and mark soft-nav fetches so Gate/OKX render pages from local DB without blocking on exchange history sync.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-06-24 00:39:54 +08:00
parent b18b2143b5
commit 813ebf0e4e
10 changed files with 61 additions and 54 deletions
+21
View File
@@ -0,0 +1,21 @@
from instance_nav_lib import request_is_hub_soft_nav
def test_request_is_hub_soft_nav():
class Req:
args = {"embed": "1"}
headers = {"X-Instance-Soft-Nav": "1"}
assert request_is_hub_soft_nav(Req()) is True
class Req2:
args = {"embed": "1"}
headers = {}
assert request_is_hub_soft_nav(Req2()) is False
class Req3:
args = {}
headers = {"X-Instance-Soft-Nav": "1"}
assert request_is_hub_soft_nav(Req3()) is False