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
[MdTabs] content height is not set with async data #1513
Comments
This can be related with #1500 |
Not exactly. In my case the calculation for the height of MdTab should be done after async data was loaded. |
If you try |
I can confirm that even with |
Seems like |
It can be because |
Well, but `ResizeObserver` only gets fired once, you can check it out by
adding some `console.log()`.
Strangely, if I initialize another `ResizeObserver` in Devtools, calling
`observe`, it works normally. Even doing another `observe($vm0.$el)` call
to `$vm0.resizeObserver` would work.
No idea about what went wrong in here.
…On Sun, Feb 25, 2018 at 23:14 Samuell ***@***.***> wrote:
It can be because calculateTabPos its not called with ResizeObserver
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1513 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMeDEgICMCFvqzzsoOnhk8Gugj91HDWkks5tYXjigaJpZM4SHJlE>
.
|
I'm running into this exact same issue. Using the same Vue/Vue-Material versions as OP, loading the data dynamically via Vue-Resource. I get the exact same behavior on Firefox (data does not show on initial load/page reload, but if I go to another tab and then back it shows OK), but different in Chrome - the data is never shown (not in initial load, nor when changing tabs and back). |
It's still broken for me (exactly as before). I am using the very latest dev branch, which includes that fix. |
@alexaandru do you rebuilded dist? |
@Samuell1 Of course. I modified package.json to point to it, ran
Then I ran the frontend as usual |
@alexaandru do you rebuilded dist of vue-material repository? |
@Samuell1 is there else I need to do beyond
The dist was rebuild 2h ago as you can see as an effect of doing the |
To use DEV branch you need to rebuild vue-material, not only your app. |
I understand that and the listing above is for vue-material, not for my app. And just to be clear I've rebuild them both. |
I am also still seeing this issue. Vue: v2.5.13 The .md-tabs-content div is getting an incorrect height set on load, then when switching to a different tab, then switching back, the height corrects itself. What is the suggested fix here? Setting md-dynamic-height on the tabs element has no effect. |
@gwilakers because still is not new release that is fixing this bug... |
@Samuell1 When is that release planned to go out? |
I am still able to reproduce the issue in chrome. |
@pranayrauthu yeah if you read messages again you find its fixed only in DEV branch. |
Any news about this issue ? |
here is a temporary workaround for the issue:
it works for me as intended. |
Another fix I found was to do this:
This is basically does the swapping tabs for you. |
Does the bug exists in 1.0.0-beta-15?
|
Steps to reproduce
When filling a MdList into MdTab content from an async source, the height is not set correctly for initial tab.
eg I have this in my template.
events
is filled in vuex, after calling an axios.get(...).Initial view is this: (where md-tabs-content is set to style="height: 16px;")
When changing tab and return back to this tab:
Which browser?
Vue v2.5.13
Vue-material 1.0.0-beta-8
Any browser
What is expected?
When content is changed, a redraw should happen, so correct height is generated.
What is actually happening?
Content height was computed before async data was loaded.
So height is set to 16px;
Reproduction Link
The text was updated successfully, but these errors were encountered: