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

feature: EventsManager Resolving delegate/capture targetEvents callbacks support navigation control attributes #559

Open
wesleyolis opened this issue Jan 9, 2017 · 2 comments

Comments

@wesleyolis
Copy link

I'm submitting a feature request
When resolving delegate/capture target events, the DOM will be transversed until from the current target through its parentNode until target.delegateCallbacks[event.type] is found.

feature: Change the behaviour of the two functions handleDelegatedEvent and handleCaptureEvent
such that they inspect the current target for property potentially call DelCapNav.
If this property is found then it is assumed the node tree under current element is virtual mirror implementation of another node element at the same level, which would contains the actual delegateCallBack events. The new behavior will then go iterate the correct node tree and identify
then delegateCallBack to call.

The DelCapNav Property needs to typically support a few options.

  • Top, means iterate list from top the positional count will be eqivalent.
  • Bottom, means iterate list from bottom the position count will be equivalent.
  • ID=[optionalattribue], their is id or another property that can be used to pair up the list.
  • undefined, same as TOP.

This would allow java script to dynamically create summary previews and over-layers for headers and footers in certain controls, with out extensively duplicate lots of HTML, using Aurelia templates
and then having to dynamic hide/show elements.
One could just simple clone a couple of nodes and the event model will still work.
An example could be seen here.

https://jsfiddle.net/wesley_olis/cvfswtm0/1/#&togetherjs=Jvc4rqH8iy

@fkleuver
Copy link
Member

@bigopon I was looking through some issues we might be able to tackle in vNext. This one sounds interesting but I'm not entirely sure I understand the desired functionality / use case. Do you have any idea?

@bigopon
Copy link
Member

bigopon commented Aug 31, 2018

@wesleyolis Am I right that you are proposing to have an alternative way, beside standard way, how Aurelia sees the event-path, by defining it somewhere using either attached / detached DOM tree and later lookup based on a special property on each element along the event.paths ?

If so, I think this feature goes too far away from how a standard event works, it should be only supported if we have a plug-able way to do this. @fkleuver

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants