mirror of
https://github.com/discountry/ritmex-bot.git
synced 2026-09-10 08:48:07 +00:00
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:
@@ -79,10 +79,6 @@ export function MakerPointsApp({ onExit }: MakerPointsAppProps) {
|
||||
const spreadDisplay =
|
||||
snapshot.spread != null ? `${formatNumber(snapshot.spread, spreadDigits)} USDT` : "-";
|
||||
const hasPosition = Math.abs(snapshot.position.positionAmt) > 1e-5;
|
||||
const markDisplay = Number.isFinite(snapshot.markPrice) ? formatNumber(snapshot.markPrice, priceDigits) : "-";
|
||||
const dislocationDisplay =
|
||||
snapshot.dislocationBps != null ? formatNumber(snapshot.dislocationBps, 2) : "-";
|
||||
const blockDisplay = snapshot.blockedBps > 0 ? String(snapshot.blockedBps) : "-";
|
||||
|
||||
const sortedOrders = [...snapshot.openOrders].sort((a, b) =>
|
||||
(Number(b.updateTime ?? 0) - Number(a.updateTime ?? 0)) || Number(b.orderId) - Number(a.orderId)
|
||||
@@ -153,13 +149,6 @@ export function MakerPointsApp({ onExit }: MakerPointsAppProps) {
|
||||
spread: spreadDisplay,
|
||||
})}
|
||||
</Text>
|
||||
<Text>
|
||||
{t("makerPoints.markLine", {
|
||||
mark: markDisplay,
|
||||
bps: dislocationDisplay,
|
||||
block: blockDisplay,
|
||||
})}
|
||||
</Text>
|
||||
<Text color="gray">{t("trend.statusLine", { status: readyStatus })}</Text>
|
||||
<Text>
|
||||
{t("makerPoints.quoteLine", {
|
||||
@@ -247,4 +236,3 @@ export function MakerPointsApp({ onExit }: MakerPointsAppProps) {
|
||||
</Box>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user