Skip to content
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

Add sortable-item and sortable-container attribute to elements #338

Closed
1 of 6 tasks
lukasoppermann opened this issue Mar 2, 2018 · 2 comments
Closed
1 of 6 tasks
Labels
feature New feature or enhancement good first issue This issue should be easy for new contributors. If you need help please reach out to us! help wanted

Comments

@lukasoppermann
Copy link
Owner

lukasoppermann commented Mar 2, 2018

To make it easier to get a sortable or the items inside one, the following should be changed:

  • element.closest(selectors) must be polyfilled (done by advising to use financial times polyfill)
  • sortable items need get an attribute sortable-item
  • when a new item is added to a sortable and it does not have the attribute sortable-item but it matches the option.items option, it needs to get the attribute
  • when a sortable is destroyed, its items need to have the sortable-item removed
  • sortables (e.g. ul or tbody) need get an attribute sortable-container
  • when a sortable is destroyed, the sortable-container attribute must be removed

This idea needs to be checked again. Does it make sense?

@lukasoppermann
Copy link
Owner Author

Polyfilled by financial times polyfill

@lukasoppermann lukasoppermann changed the title Polyfill closest to use to get parent sortable Add sortable-item and sortable-container attribute to elements Mar 4, 2018
@lukasoppermann lukasoppermann added the good first issue This issue should be easy for new contributors. If you need help please reach out to us! label Mar 4, 2018
@lukasoppermann
Copy link
Owner Author

Maybe it adds more complications than it solves

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or enhancement good first issue This issue should be easy for new contributors. If you need help please reach out to us! help wanted
Projects
None yet
Development

No branches or pull requests

1 participant