Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

fix(utils): add the ability to prevent the default action of onEvents#236

Closed
poxrud wants to merge 1 commit intoangular:masterfrom
poxrud:fix-utils-patchProperty
Closed

fix(utils): add the ability to prevent the default action of onEvents#236
poxrud wants to merge 1 commit intoangular:masterfrom
poxrud:fix-utils-patchProperty

Conversation

@poxrud
Copy link
Copy Markdown
Contributor

@poxrud poxrud commented Jan 26, 2016

Add the ability to prevent the default action of onEvent (onclick, onpaste, etc..) from occurring
by returning false.

For example, you should be able to stop text from being pasted into a textbox with:

textarea.onpaste = function() { 
  return false;
}

I discovered this during my investigation of issue #232, which this PR fixes.
I suspect it will also fix issue meteorhacks/zones#80

…(onclick, onpaste,etc..) by returning false.
@poxrud
Copy link
Copy Markdown
Contributor Author

poxrud commented Mar 18, 2016

@mhevery
This PR is now incompatible with POST-v0.6.0., however I've verified that this issue still exists.
Should I submit a new PR for this?

@mhevery
Copy link
Copy Markdown
Contributor

mhevery commented Mar 18, 2016

Yes please!

@mhevery
Copy link
Copy Markdown
Contributor

mhevery commented Mar 21, 2016

Any update on a rebase?

@mhevery
Copy link
Copy Markdown
Contributor

mhevery commented Mar 21, 2016

Actually, it applies cleanly, and tests, pass so I am merging it in.

@mhevery mhevery closed this in 3361603 Mar 21, 2016
mhevery pushed a commit that referenced this pull request Mar 21, 2016
…(onclick, onpaste,etc..) by returning false.

Closes #236
mhevery pushed a commit that referenced this pull request Mar 21, 2016
…(onclick, onpaste,etc..) by returning false.

Closes #236
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants