Commit Graph
19463 Commits
Author SHA1 Message Date
Timothy Yung 627d7eb669 Merge pull request #754 from spicyj/over-and-out
Add onMouseOver and onMouseOut events
2014-01-06 10:28:54 -08:00
Tim Yung 182a237fa7 Separate Module for Key Normalization
This moves key normalization into its own module so that it can be re-used elsewhere.
2014-01-06 10:07:49 -08:00
Christoph Pojer 22ba8b67f1 Silence console.error in ReactDOMInput-test
This test is expected to throw but because of ReactErrorUtils.guard
which uses console.error in __DEV__ it also logged the invariant error
to the console. This change fixes it by temporarily stubbing out
console.error.

Fixes #531
2014-01-06 10:07:49 -08:00
Tim Yung e65726cd04 Cleanup ReactEventEmitter Variable Naming
Minor follow-up to 80d7d2d0f8.
2014-01-06 10:07:49 -08:00
Isaac Salier-Hellendag 1584aaf746 Change global to window in SyntheticClipboardEvent
Replace `global` reference with `window` in `SyntheticClipboardEvent`.
2014-01-06 10:07:49 -08:00
Pete Hunt 089a494a1f Forbid full-page rendering without server rendering
Final part of server rendering cleanup. We should only support full-page rendering when server rendering is involved since
otherwise it's slow and can crash browsers when you start adding and removing document roots. This diff removes the magic
innerHTML code (since that will be handled by the server rendering piece) and adds the right assertions and errors.

Because there's no longer a dangerous of accidentally nuking the whole page, I removed allowFullPageRender which is yet another
internal we no longer need to expose.
2014-01-06 10:07:48 -08:00
Pete Hunt 9b3342ed34 Throw when unmounting <html>, <head>, <title> or <body>
These are dangerous from a cross-browser perspective. I think supporting efficient reactive updates will be prohibitively
expensive and we'll never prioritize it. Instead of killing this capability entirely, let's just throw on the dangerous cases.
There will be a few follow-up diffs
2014-01-06 10:07:48 -08:00
Christopher Chedeau 7630e56971 Merge pull request #804 from spicyj/examples-no-browserify
Remove mentions of browserify in examples
2014-01-06 10:03:10 -08:00
Christopher Chedeau 9cce0c2752 Merge pull request #823 from spicyj/key-docs
Add charCode/keyCode/which to key event docs
2014-01-06 09:40:18 -08:00
Thomas Aylott 91821007ed benchmark runner 2014-01-06 12:26:40 -05:00
Christopher Chedeau 6dd62b0e4f Merge pull request #688 from vjeux/community_14
Community Round-up #14
2014-01-06 09:11:09 -08:00
Matt Harrison 42262f5361 Aphabetized and wrapped tags/attributes docs 2014-01-06 08:15:46 +00:00
Timothy Yung 2c1a25411f Merge pull request #747 from spicyj/currentTarget
Set currentTarget on synthetic events
2014-01-05 20:41:48 -08:00
Timothy Yung 13230a3044 Merge pull request #643 from spicyj/scroll-pos
Fix scrollLeft/scrollTop warning in latest Chrome
2014-01-05 20:41:35 -08:00
Ben Alpert b366e36367 Add charCode/keyCode/which to key event docs 2014-01-05 21:24:17 -07:00
Christopher Chedeau ed3d5add76 Merge pull request #809 from passy/patch-1
Add gulp-react to Helpful OSS Projects
2014-01-05 18:16:20 -08:00
Christopher Chedeau 0e5b62a4c3 Merge pull request #818 from Daniel15/link-htmltojsx
Add link to HTML to JSX converter to “JSX In Depth” page
2014-01-05 18:16:06 -08:00
Cheng Lou 5b43a2e6d7 throw error when setState's arguments are bad 2014-01-05 18:01:07 -08:00
Matt Harrison c01f0a0487 Updated docs with new SVG elements 2014-01-05 12:18:30 +00:00
Matt Harrison c4d918aca0 Added support for 4 extra SVG tags: stop, defs, linearGradient, radialGradient 2014-01-05 11:17:04 +00:00
Daniel Lo Nigro ae9188db50 Change “not allowed” back to “discouraged” since you technically *can* use props called class or for… 2014-01-04 23:33:02 -08:00
Daniel Lo Nigro 202a3f184d Add link to HTML to JSX converter to “JSX In Depth” page 2014-01-04 23:25:28 -08:00
Christopher Chedeau 605b42e622 Merge pull request #811 from xixixao/issue793
Document displayName
2014-01-04 10:41:56 -08:00
xixixao ee0a4acfac Document displayName 2014-01-04 17:34:16 +01:00
Pascal Hartig e92d769a50 Add gulp-react to Helpful OSS Projects
Add @sindresorhus' JSX task for Gulp to the "Helpful Open-Source Projects" section of the tooling integration docs.
2014-01-04 11:20:45 +01:00
Ben Alpert 33dcf8a0b5 Set currentTarget on synthetic events
Fixes #658, fixes #659.
2014-01-04 00:27:11 -07:00
SanderSpies 80d7d2d0f8 Listen to events on demand
Fixes #381

This is a squashed version of https://github.com/facebook/react/pull/462
2014-01-03 23:09:59 -08:00
Ben Alpert 309a88bcf6 Prefer textContent to innerText
Fixes #807.
2014-01-04 00:01:03 -07:00
Pete Hunt a575e93ecd Merge pull request #806 from spicyj/patch-4
Fix typo
2014-01-03 22:19:35 -08:00
Ben Alpert ea40a6aedd Fix typo 2014-01-03 23:19:04 -07:00
Pete Hunt 047e962a55 Merge pull request #805 from spicyj/docs-mention-react-art
Mention react-art where we talk about SVG
2014-01-03 22:17:51 -08:00
Ben Alpert fdfd7c1853 Mention react-art where we talk about SVG 2014-01-03 23:15:50 -07:00
Ben Alpert be75e3be66 Remove mentions of browserify in examples 2014-01-03 22:58:51 -07:00
Timothy Yung c11d6d79f5 Merge pull request #721 from spicyj/change-bubble-ie
Make controlled components and bubbling work in IE
2014-01-03 18:10:16 -08:00
Nick Thompson d270e2b1c7 Don't add displayName in transform if already defined
This ensures we don't add displayName in the transform if it's already been
defined. This is especially important when in strict mode, where duplicate
properties in an object is an exception.
2014-01-03 16:07:10 -08:00
Christopher Chedeau e3e24500ae Merge pull request #795 from philix/master
Add jsx-requirejs-plugin to the tooling-integration page
2014-01-03 11:09:59 -08:00
Felipe Oliveira Carvalho 86f2dbe55d Remove the require-jsx plugin from the tooling-integration page
In favor of the r.js friendly jsx-requirejs-plugin
2014-01-03 16:03:42 -03:00
Felipe Oliveira Carvalho 344b5998a8 Add jsx-requirejs-plugin to the tooling-integration page 2014-01-03 15:45:03 -03:00
Andreas Svensson 4de2d39f63 Fix WheelEvent incorrectly inverting sign of deltaY 2014-01-03 19:09:09 +01:00
Andreas Svensson 7264cbcdfb Further cleanup of isEventSupported 2014-01-03 19:02:20 +01:00
Jeff Morrison 1b67ac90f2 Make sure the mock is cleared in the EventEmitter test 2014-01-02 20:09:50 -08:00
Isaac Salier-Hellendag 29190a2c79 Support clipboardData in IE
Use the `clipboardData` object available on `window`, if it's not available on the event object. This allows us to support including the `clipboardData` in cut/copy/paste events in IE.
2014-01-02 20:05:07 -08:00
Christoph Pojer bcfb476366 More tests for 77697f26e3 2014-01-02 20:05:03 -08:00
Ben Newman 1ee7f8131c Let components specify tag for ReactTestUtils.mockComponent to use.
If you're writing a test that involves a mocked component that normally
returns a `<li>` tag from its `render` method as the root element, mocking
it with a dummy `<div>` probably won't work, so you'll want to set

  MyListItemComponent.mockTagName = 'li';

The change to the `.mockImplementation` line makes sense because
`ConvenienceConstructor` is more or less synonymous (for these purposes)
with the wrapper that was previously used:

  function() {
    // This `this` used to be `null`, technically, but
    // ConvenienceConstructor doesn't pay attention to `this` anyway.
    return ConvenienceConstructor.apply(this, arguments);
  }
2014-01-02 20:03:55 -08:00
Ben Newman a00e4c840c Support ReactTestUtils.mockComponent. 2014-01-02 20:03:40 -08:00
Sebastian Markbage cbefc5a968 Add display names to controlled components
These show up as Unknown in the DevTools. They also wrap a native component,
so they show up double.
2014-01-02 20:03:26 -08:00
Fabio Costa f3e774559f adding warning about the lack of support for onScroll on IE8
Adding `console.warn` about the lack of support for `onScroll` event on IE8
Related to this issue on github https://github.com/facebook/react/issues/631
2014-01-02 20:01:33 -08:00
Pete Hunt 1733d42ded Rework ReactRootIndex generation
This had a higher probability of collision than originally thought (bad math). This makes the strategy injectable and provies a
no-collision version on the client and an unlikely-to-collide version on the server.
2014-01-02 20:00:30 -08:00
Pete Hunt cc005668b5 cloneWithProps()
what if you want to change the props of a child? This is my first attempt which lets you clone a child and transfer some custom props to it.

There is a fundamental issue with refs here. Since the component is cloned the ref will be broken. And since we can clone multiple times, it might not make sense to support repairing refs.
2014-01-02 19:46:50 -08:00
Pete Hunt 5661d5168e Add svg polygon 2014-01-02 19:45:55 -08:00