Refactor Maker Points logic by removing dislocation calculations and related UI elements. Update MakerPointsEngine to utilize new price fetching methods and streamline order synchronization. Adjust translations and tests accordingly to reflect these changes.

This commit is contained in:
discountry
2026-01-06 16:18:54 +08:00
parent 7aafc3b69d
commit 33b5407245
5 changed files with 11 additions and 132 deletions
+1 -9
View File
@@ -1,5 +1,5 @@
import { describe, expect, it } from "vitest";
import { buildBpsTargets, computeDislocationBps } from "./maker-points-logic";
import { buildBpsTargets } from "./maker-points-logic";
describe("maker points target builder", () => {
it("builds fixed bps targets per enabled band", () => {
@@ -20,11 +20,3 @@ describe("maker points target builder", () => {
expect(targets).toEqual([9, 99]);
});
});
describe("maker points dislocation", () => {
it("computes max bps dislocation from mark vs bid/ask", () => {
const bps = computeDislocationBps(100, 99.97, 100.02);
expect(bps).not.toBeNull();
expect(Number(bps?.toFixed(2))).toBe(3.0);
});
});