-
Notifications
You must be signed in to change notification settings - Fork 284
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
Events for selecting #491
base: main
Are you sure you want to change the base?
Events for selecting #491
Conversation
I used (Tests works fine with #493) |
Hey @tsparksh are you working on this? The task is open on Github |
@Uzay-G, on the gci dashboard for some reason there are two identical tasks with a link to this issue, my task is marked as accepted |
Ok alright thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is optional, but instead of using jQuery and adding it to the test dependecies you could have done this in JavaScript: var selectImageEvent = new Event('selectImage');
this.dispatchEvent(selectImageEvent); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@VladimirMikulic thank you for reviewing! @tsparksh haven't gotten the chance to review this yet but for now can you please implement the suggestion regarding jQuery.
jQuery is already a dependency so using it was fair game but I actually have been wanting to update the few lines in the repo that use it to vanilla JS and remove it
also I think running this and pushing will fix your travis build:
|
I can’t fix it in the next week, but I’ll definitely do it as I return, thanks!
… On 10 Jan 2020, at 13:49, Sasha Boginsky ***@***.***> wrote:
also I think running this and pushing will fix your travis build:
$ rm -rf package-lock.json node_modules
$ npm install
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
@tsparksh okay no problem! Please note that the mentor approved the task for you so that you could move on to others in my absence, but you still need to complete them (merged PR) to actually get the points! |
@sashadev-sky, can you check, please |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the best thing to do here woudl be to use leaflet's fire
(it's pretty much like trigger
) so sorry didnt look into this more thoroughly before.
This would be an example of the sort of syntax looking for:
Leaflet.DistortableImage/src/edit/handles/EditHandle.js
Lines 33 to 35 in e0b5130
_onHandleDragStart: function() { | |
this._handled.fire('editstart'); | |
}, |
so maybe something like this.fire("select")
and putting it up higher in the method like after the line:
if (!edit.enabled()) { return false; }
@sagarpreet-chadha @VladimirMikulic @jywarren @sidntrivedi012 what do ya'll think
** as background ** i think these methods will be utilized by MK to allow for synchronous editing.
I agree @sashadev-sky. Consistency is important. |
Fixes #460
Make sure these boxes are checked before your pull request (PR) is ready to be reviewed and merged. Thanks!
grunt
Example: