Add benchmarks update test for react-jss

Close #785
This commit is contained in:
Oleg Slobodskoi
2018-01-21 20:45:06 +01:00
committed by Nicolas Gallagher
parent 9d8d4057f6
commit 985c1d63b6
2 changed files with 28 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
/* eslint-disable react/prop-types */
import injectSheet from 'react-jss';
import React from 'react';
const Dot = ({ classes, children }) => <div className={classes.root}>{children}</div>;
const styles = {
root: {
position: 'absolute',
cursor: 'pointer',
width: 0,
height: 0,
borderColor: 'transparent',
borderStyle: 'solid',
borderTopWidth: 0,
transform: 'translate(50%, 50%)',
borderBottomColor: ({ color }) => color,
borderRightWidth: ({ size }) => size / 2,
borderBottomWidth: ({ size }) => size / 2,
borderLeftWidth: ({ size }) => size / 2,
marginLeft: ({ x }) => x,
marginTop: ({ y }) => y
}
};
export default injectSheet(styles)(Dot);

View File

@@ -1,9 +1,11 @@
import Box from './Box';
import Dot from './Dot';
import Provider from './Provider';
import View from './View';
export default {
Box,
Dot,
Provider,
View
};