bitshares / bitshares/bitshares-ui
Define Logic for Margin Position Status
- Dominant language
- JavaScript
- Stars
- 520
- Forks
- 575
- Avg merge
- 12h 7m
- Merged PRs (30d)
- 5
Description
Applies to Asset Details -> Margin Positions for positions near or below the threshold.
Currently
```
if (cr < mr) {
return "danger";
} else if (cr < mr + 0.5) {
return "warning";
} else {
return "";
}
```
_Originally posted by @sschiessl-bcp in https://github.com/bitshares/bitshares-ui/issues/2779#issuecomment-502967658_
Contributor guide
Research direction
Start by tracing the Asset Details → Margin Positions view and locate the code represented by the issue’s margin-ratio snippet. Review the referenced issue discussion for the intended behavior near and below the threshold, then define the status outcomes and verify each boundary case in the relevant UI tests or manually in the margin-position view.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100