Bug in Beta 14 regarding collection-repeat and modal opening

Let’s suppose a tab presenting the view MyList: a list of item using a collection-repeat.
Click on an item, its detail is shown.
Now, go back and…cool the scroll has kept the position ! Everything Ok, since MyList is a cached view .

Now this scenario:
Click on an item, and in its detail page, open a modal (assuming there’s button/link opening a modal).
Now, close the modal and go back to the list (through the back button too).
Wow! The scroll has lost the previous position, it’s at the top ! => issue

It doesn’t happen when using classic ng-repeat.
Any idea?
Is it known?

Thanks

2 Likes

Can you provide a codepen for this @Mik378?

Yes, will do it tomorrow :wink:

Hi,

Here’s my codepen showing the issue: http://codepen.io/mica16/pen/EaygJa?editors=101

Basically, you just have to click on an item, let’s say the item 16.
Then click on “open a modal” and close it.
Then go back and you will notice that the list is scroll automatically to the top…frustrating :wink:

You can change the collection-repeat keyword by a traditional ng-repeat.
In this case, this works fine, however, I can’t use ng-repeat smoothly with 1000 data :wink:
Also, this works fine if you don’t click on the modal but go back directly.

Is it a bug?

Hi @mhartington,

Any news about this?
Might the reason be obvious?

Thanks a lot

Michael

Hey, sorry, will look at this tonight.

I can confirm my app has the same problem.

What’s more, opening the modal become extremely slow when the collection-repeat list become larger than a couple of hundreds items. The modal dialog in other tabs also become very slow to open when the collection-repeat list become large.

Seems to me when opening modal dialog, it has force all tabs to refresh.

Your modal is in the same view than the list ?!

I have two modals in two separate tabs, if the collection-repeat list become large, both are affected.

Where is this collection-repeat? Inside a modal?
If yes, it’s not similar to my issue at all.

In the list views, modals in separate detail views.

@mhartington May we assert that this a real bug in the actual release?

Thanks

1 Like

I’m having the exact same issue

1 Like

@mhartington Sorry to alert you again, but will the fix of this bug be part of any nightly soon ?
Indeed, some users find that very “annoying”… (they have to scroll again and again…) thanks a lot :wink:

Hey sorry about the delay, yes @Mik378 can you open an issue for this?

1 Like

+1 for the issue regarding the scroll position but mostly for the one regarding the really poor performance when opening a modal over a collection repeat list (almost no animation on a nexus 5 on open and close + high latency)

1 Like

Hi @mhartington.

Here’s the created entry: https://github.com/driftyco/ionic/issues/2865

1 Like

@Mik378 Would you mind adding the slow performance issue along with your issue, or should I open an entry for this exact problem?

Hi @WidawskiJ

I do think it’s two completely distinct bugs, so you may want to create another distinct bug entry.

Thanks :wink:

Thanks for opening that @Mik378