Commit Graph

21 Commits (e8c0d6ec7c38dac6eaffa2282acfafafcd496603)

Author SHA1 Message Date
Travis Ralston f1ac3d2f64 Convert imports to ES6 from CommonJS
This is needed because `require()` means something different in webpack - it ends up importing the module as something we didn't expect (and is occasionally async)
2019-12-22 21:16:06 -07:00
Travis Ralston 24843cf25e Convert Velociraptor to a class 2019-11-28 19:36:30 -07:00
Michael Telatynski aa98a6dfcb Start using create-react-class polyfill
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2019-08-05 10:08:30 +01:00
David Baker 1a8fe4dd43 Go back to using mainine velocity
We moved off to our own fork of velocity many moons ago to fix
a memory leak bug when velocity was being barely maintained. They
have now merged the bugfix, so go back to mainline.
2019-03-20 10:54:06 +00:00
Bruno Windels f360b2db90 forward prop updates to children in Velociraptor with React.cloneElement 2018-10-10 16:15:50 +02:00
David Baker ce74099698 Null check node before we pass it to velocity
As presumably sometimes the node wasn't actually in the DOM for
whatever reason, so don't propagate exceptions out into the app.

Should fix https://github.com/vector-im/riot-web/issues/6515
2018-04-13 10:44:37 +01:00
Aidan Gauland 35780f5ae0 Remove use of deprecated React.PropTypes
Replace all uses of React.PropTypes with PropTypes and importing PropTypes from
'prop-types'.
2017-12-26 14:03:18 +13:00
Luke Barnard d3f9a3aeb5 Run eslint --fix
Fixing 1000s of lint issues. Some rules cannot be `--fix`ed but this goes some way to linting the entire codebase.
2017-10-11 17:56:17 +01:00
Luke Barnard 66525f6826 Null-guard RR logic 2017-07-10 15:07:22 +01:00
David Baker 42f75e1740 Fix one read receipt randomly not appearing
The velociraptor was only actioning hidden -> visible transitions
if the position had changed, so the one RR that stayed in position
but became visible... didn't become visible.
2017-02-02 18:21:53 +00:00
David Baker 18d4d3392a Fix a bunch of linting errors
eslint --fix and a few manual ones
2017-01-20 14:22:27 +00:00
Richard van der Hoff 94a44bfec3 Fix warnings emanating from Velociraptor elements
We are no longer allowed to stick random properties on child properties, and
the Velociraptor animations were causing some React warnings.

Move the startStyles and enterTransitionOpts properties up to the Velociraptor
node, and avoid setting arbitrary props on the created children. This is less
flexible, as it assumes that all children will have the same start style;
however, we weren't using the flexibility, and we can always replace the array
with a map or a function or something if we need it in the future.
2016-08-01 16:56:25 +01:00
David Baker aca0e060a4 Also change velocity-vector commit & requires
Because it needs a versiob where the package name is actually updated and the requires need to use the right package name
2016-06-07 20:47:37 +01:00
David Baker d5a522fdfe Second attempt at fixing the Velocity memory leak
1) Correct fix for Velociraptor (we need to find the DOM node and pass that in)
2) Do the same leak fix for the read marker
3) Update the dependency to our fork which is fixed to make the call we do to release memory actually work.
4) Remove the velocity-ui-pack dependency which is unnecessary because velocity-ui is included in the velocity package
2016-06-07 18:22:01 +01:00
David Baker 1664f46180 Add comment 2016-05-26 16:30:04 +01:00
David Baker 3a5e37aa84 This actually shouldn't be necessary. 2016-05-26 16:22:40 +01:00
David Baker ed835752bc Hopefully fix memory leak with velocity 2016-05-26 13:51:51 +01:00
Richard van der Hoff f09861794d Avoid having react interface methods call each other
Factor out the common bits of componentWillMount and componentWillReceiveProps
to a common function.
2016-04-21 14:14:08 +01:00
Richard van der Hoff 04ef0262af Various fixes to the velociraptor
* handle having a single child, rather than an array of children

* Correctly animate children which are added at the same time as the
  Velociraptor, rather than added afterwards

* Set the child to hidden at the end of the initial animation, if that is
  required by the style property.
2016-04-20 22:21:07 +01:00
David Baker b37ea52a1f Some null checks in animation code 2016-01-08 16:47:13 +00:00
Kegan Dougal 5ba1ef5203 Move velocity stuff / contextual menu from Vector to React. 2015-11-27 15:37:40 +00:00