-
-
Notifications
You must be signed in to change notification settings - Fork 609
Fix the link on the upstream chart legend #3606
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
Conversation
The outer `if` (line 92) already guarantees only 2 possible values. If `isQueryTypeChart` is false, `isForwardDestinationChart` must be true. Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
This will avoid overwritting the IP when more than one upstream DNS server uses the same name Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
1478dbc
to
af471be
Compare
Hmmm, I hadn't noticed that item 3 in your previous comment... I will try to fix this tonight. |
The link must send the "upstream" parameter in exactly the same format used by the "suggestions" API. The format is: "upstream=<IP>#<port> (<servername>)". This will ensure that when a link is clicked, the correct server name will be highlighted in the SELECT element on the queries.lp page and no other OPTION element will be created. Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
I already changed the code. |
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.
That's working really well now.
Last nitpick: The tooltip of the doughnut chart contains name#port: percentage
but does not contain IP. So for the same upstream name one can only distinguish by color. Could you include the IP here as well?
Yeah, I feared this. But without including the IP the only way to distinguish the same names is by color - which affects accessibility :-/ |
Nice! |
We need to add a small padding to avoid "clipping" the arc/slice. This happens because when an arc/slice expands, it grows beyond the canvas limits and get clipped. Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
e754d4f
to
3959ded
Compare
Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
3959ded
to
c6a2e85
Compare
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.
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.
I think it's only a small detail, no need to fix it now.
What does this PR aim to accomplish?
When 2 or more upstream servers have the same name, both links on the chart legend point to the same IP:
Each link should point to the correct IP and show different queries, but the issue happens because the current code uses an object containing the server name (label) as
key
and thevalue
is the IP, but when there are 2 items with the same key, the first one is overwritten and its IP is lost.How does this PR accomplish the above?
Using an array of IPs with indexes will avoid the issue.
This PR also adds the IP to the legend tooltip, to make easier for users to identify different DNS servers, even when they have the same name:
Link documentation PRs if any are needed to support this PR:
none
By submitting this pull request, I confirm the following:
git rebase
)