Can't eliminate vertical and horizontal scroll bar on embedded canvas dashboard
Answered
I have a canvas layout dashboard embedded in a webpage. No matter what I try, I can't get rid of scroll bars. They're unneeded and only allow a tiny amount of travel.
I think it's related to it being canvas layout because when I switch just the dashboard slug, and embed a different dashboard that is fixed layout (I think 3 column), the scroll bars vanish. That's as far as I got isolating the problem.
It could be something about the dashboard itself but nothing I've tried has helped. I tried making every report and textbox 850px wide, and the dashboard 900px wide. I've tried fitting the dashboard to that 850px width. None of that makes a difference.
Can you offer any advice?
Hi Sam,
Can you try adding to your code, the option scaleCanvasTabs: false, where you're loading the dashboard, e.g.
yellowfin.loadDashboard({
dashboardUUID: '0ccb0402-a33e-47af-a324-f3ce9db8b250',
element: document.querySelector('div#dashDiv'),
showToolbar: false,
scaleCanvasTabs: false
});
In my testing, I also see extra scroll bars. 2 in Chrome (for vertical and horizontal), and 1 in Firefox (vertical only). If I use set scaleCanvasTabs to false, that seems to fix the issue for me.
Kind regards,
Chris
Hi Sam,
Can you try adding to your code, the option scaleCanvasTabs: false, where you're loading the dashboard, e.g.
yellowfin.loadDashboard({
dashboardUUID: '0ccb0402-a33e-47af-a324-f3ce9db8b250',
element: document.querySelector('div#dashDiv'),
showToolbar: false,
scaleCanvasTabs: false
});
In my testing, I also see extra scroll bars. 2 in Chrome (for vertical and horizontal), and 1 in Firefox (vertical only). If I use set scaleCanvasTabs to false, that seems to fix the issue for me.
Kind regards,
Chris
Thanks for the response. I might be embedding a different way than that, I have a line like this:
That call, in a plain HTML page, has the extra set of scrollbars. I tried adding scaleCanvasTabs=false to that URL string but no effect. How can I incorporate the yellowfin.loadDashboard({}) command into my JavaScript embed call?Thanks for the response. I might be embedding a different way than that, I have a line like this:
That call, in a plain HTML page, has the extra set of scrollbars. I tried adding scaleCanvasTabs=false to that URL string but no effect. How can I incorporate the yellowfin.loadDashboard({}) command into my JavaScript embed call?Also here's why I think it's something about the dashboard itself. I made a copy of the same HTML page, everything identical except I'm pointing to a different dashboard. That one does not yield an extra set of scroll bars.
Has extra set: https://www2.a2gov.org/publicyf/arpa_dashboard.html
No extra scroll bars: https://www2.a2gov.org/publicyf/dashboard_three_column.html
Also here's why I think it's something about the dashboard itself. I made a copy of the same HTML page, everything identical except I'm pointing to a different dashboard. That one does not yield an extra set of scroll bars.
Has extra set: https://www2.a2gov.org/publicyf/arpa_dashboard.html
No extra scroll bars: https://www2.a2gov.org/publicyf/dashboard_three_column.html
Hi Sam,
I wasn't able to view either of those links but looking at my browser console it seems there's a CORS error. I don't know if you've made the dashboards inaccessible since the other day but to fix that the cross origin domain needs to be added in the Admin Config of Yellowfin.
So that's the standard embed you're using there, which will work but yes it's possible it might display extra scroll bars.
The page HTML looks like:
and then reporting.js is a separate file that contains the code from below: We have some documentation on our Wiki that describes the various options for the API if you want to take a look.Kind regards,
Chris
Hi Sam,
I wasn't able to view either of those links but looking at my browser console it seems there's a CORS error. I don't know if you've made the dashboards inaccessible since the other day but to fix that the cross origin domain needs to be added in the Admin Config of Yellowfin.
So that's the standard embed you're using there, which will work but yes it's possible it might display extra scroll bars.
The page HTML looks like:
and then reporting.js is a separate file that contains the code from below: We have some documentation on our Wiki that describes the various options for the API if you want to take a look.Kind regards,
Chris
Hi Sam,
Hope you're having a good week.
Just wanted to check-in and see how it's all going. Was there anything you were needing from me to help get this resolved?
Regards,
Chris
Hi Sam,
Hope you're having a good week.
Just wanted to check-in and see how it's all going. Was there anything you were needing from me to help get this resolved?
Regards,
Chris
Hi Chris,
Now that the CORS thing is fixed, can you take a look at the two links I posted above? That kind of use of the API you shared, with separate files, is more complex than anything we're doing now so I'd first like to see if I can understand what's going on with this dashboard in particular. You'll see above that one of my dashboards does not have the scroll bar (we also have it public-facing). That makes me think it's something different about the dashboard that has the scroll bars. Can you think of anything on that front?
Thanks,
Sam
Hi Chris,
Now that the CORS thing is fixed, can you take a look at the two links I posted above? That kind of use of the API you shared, with separate files, is more complex than anything we're doing now so I'd first like to see if I can understand what's going on with this dashboard in particular. You'll see above that one of my dashboards does not have the scroll bar (we also have it public-facing). That makes me think it's something different about the dashboard that has the scroll bars. Can you think of anything on that front?
Thanks,
Sam
Hi Sam,
I'm still getting CORS errors when I try to access either of those links. Does that need checking?
Kind regards,
Chris
Hi Sam,
I'm still getting CORS errors when I try to access either of those links. Does that need checking?
Kind regards,
Chris
That is perplexing, sorry you got that message again. Those pages have been loading okay on various computers and networks here. Perhaps this is a manifestation of our infrastructure team having Cloudflare challenge non-US traffic, though I thought that was just supposed to be a CAPTCHA.
Let's close this ticket, given how tricky it has been to work on. If anything emerges in the future related to scroll bars for a canvas embedded dashboard vs. none for a 3-column layout embedded dashboard, we can reopen this.
I appreciate your help looking into this, Chris.
Thanks,
Sam
That is perplexing, sorry you got that message again. Those pages have been loading okay on various computers and networks here. Perhaps this is a manifestation of our infrastructure team having Cloudflare challenge non-US traffic, though I thought that was just supposed to be a CAPTCHA.
Let's close this ticket, given how tricky it has been to work on. If anything emerges in the future related to scroll bars for a canvas embedded dashboard vs. none for a 3-column layout embedded dashboard, we can reopen this.
I appreciate your help looking into this, Chris.
Thanks,
Sam
Hi Sam,
No worries. Yes, as you say, if you want to discuss this again in the future, you can reopen the ticket at any time.
Have a great remainder of your week!
Kind regards,
Chris
Hi Sam,
No worries. Yes, as you say, if you want to discuss this again in the future, you can reopen the ticket at any time.
Have a great remainder of your week!
Kind regards,
Chris
Replies have been locked on this page!