joyent-portal/packages/icons/src/arrow.js

34 lines
700 B
JavaScript
Raw Normal View History

import React from 'react';
2017-11-23 14:18:38 +02:00
import Rotate from './rotate';
import calcFill from './fill';
2017-11-23 14:18:38 +02:00
export default ({
fill = null,
light = false,
disabled = false,
direction = 'down',
2018-01-17 21:10:39 +02:00
colors = {},
2017-11-23 14:18:38 +02:00
style = {},
...rest
}) => (
2018-01-17 21:10:39 +02:00
<Rotate direction={direction}>
{({ style: rotateStyle }) => (
<svg
width="9"
height="6"
viewBox="0 0 9 6"
xmlns="http://www.w3.org/2000/svg"
style={{ ...style, ...rotateStyle }}
{...rest}
>
<path
fill={calcFill({ fill, disabled, light, colors })}
fillRule="evenodd"
d="M9 1.386L7.648 0 4.5 3.228 1.352 0 0 1.386 4.5 6z"
/>
</svg>
)}
2018-01-17 21:10:39 +02:00
</Rotate>
);