-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
demo/stock-orderbook #20885
demo/stock-orderbook #20885
Conversation
Webpack monitoringLGTM 👍 |
File size comparisonNo differences found |
Visual test results - No difference foundSamples changed
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pawelfus Thank you!
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Neat! Just a few minor things:
- Is it
Orderbook
orOrder Book
? I mean the title. - Exporting throws errors
- Missing a11y chart's descriptions (in chart config and in demo itselft)
- Let's improve the labels further:
- enable the thousands-separator
- if the righthand labels have decimal point, then the left hand should too. I would say
XXX XXX.00
andXXX XXX.50
should be fine. Perhaps one decimal place could be better, hard to say
In terms of "Orderbook" vs "Order book", I've seen both but the second one seems to be more popular and correct, therefore I went with this one. Thanks :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice orderbook demo and great work! 👍
Just a visual thing: When the asks exceed 1 million increases order of magnitude, the data label jumps and creates visual noise. On the bids side it looks fine and steady.
Other than that, see small comment.
To discuss: Does it update overwhelmingly fast, or is it intended to work this way?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Good job 🎉
@DJTechnoo Yes, it should update that fast :D |
I saw that too. It's probably a matter of preference, but I would also rather see it without jumping. However, I'm not sure how to fix it. Maybe @TorsteinHonsi has an idea |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpicking 🧵
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, it looks great! Some change requests inline.
@pawelfus Not a good one. Clearly it comes from re-aligning to the right. But instead of keeping the right edge fixed, it animates the |
Good point. It seems to be exactly as you said: aligning items animates We could disable animations for dataLabels, but accidentally we missed that (we can disable the Chart's animation, but that's not the point of this demo). Setting However, I don't think it's a good & clean workaround to include in the official demo. Until we support nice labels/numbers animations should we just set a hard max for the value? To be 999 999? And hard min (100 000)? |
Merge #20993 first, before merging the demo. |
@pawelfus @kamil-musialowski I merged in the fix for the jumping right label, but it turns out it is still jumping. Any ideas? It probably still has to do with the alignment, but the animateX flag returns true for these cases. |
I had a look into that, but I couldn't come up with anything reasonable 🤔 |
Found the reason: https://jsfiddle.net/BlackLabel/zf1q7cdb/2/ In short, we have two |
Another problem is that the right-justified data label actually has |
@pawelfus I give up :( Any more ideas? Or should we modify the data so we don't get this situation? |
Wait a minute, just want to try one more thing, to implement alignTo for other series than pie. In addition to fixing this issue, the config will also look much cleaner, and avoid the hacky nature of setting x to -999 or 999. Draft PR: #21117 |
@TorsteinHonsi Thank you, the alignTo looks perfect. I will merge the master and add the property to the demo, once #21117 is merged. |
@kamil-musialowski The |
Perfect, thank you! |
Created a live demo simulating stock orderbook charts.