This repository was archived by the owner on Sep 8, 2020. It is now read-only.
Fixed to work with deep descendants#494
Closed
yenoh2 wants to merge 2 commits intoangular-ui:masterfrom
Closed
Conversation
modifies the sortable.js file at line 198, in order for the ui-sortable directive to work on other directives that have isolated scopes.
Contributor
|
I have already merged this one on a local branch that is going to be v0.16. Have written some v transclusion test cases and trying to make them work. |
Contributor
|
Merged with #496 |
Contributor
|
Thanks for your contribution on this 👍 |
Contributor
Author
|
Thank you. I enjoyed collaborating on it. Thank you for running with it.
It's awesome!
…On Dec 4, 2016 4:10 PM, "Thodoris Greasidis" ***@***.***> wrote:
Thanks for your contribution on this 👍
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#494 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AWduHRKASMHlh6GsvlpA2zG8aybNvRa3ks5rEtf5gaJpZM4K_PLQ>
.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In trying to use ui-sortable with Angular Material tabs, I found that it didn't work for two reasons. First you can't have two directives with an isolated scope on the same element. Second, ui-sortable didn't support items that aren't a direct decendant. I modified the "getElementScope" function to get the applicable scope for the draggable item, if the normal code results in null. I also wrapped the md-tabs directive in a div containing the ui-sortable directive to circumvent the two directives with isolated scopes issues.
As far as I can tell, this works. Can you see any issues with my change?
See the following example:
http://codepen.io/yenoh2/pen/rWxxVJ
This seems to be related to "Using ui.sortable with angular ui.bootstrap.tabs have a weird interaction #248"