@dev-crew-berlin/enter-js-utils 0.23.0 → 0.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { colors } from '../../lib/theme';
|
|
3
|
+
export const Caret = ({
|
|
4
|
+
color = colors.enterDarkGrey,
|
|
5
|
+
rotateDeg = 0
|
|
6
|
+
}) => {
|
|
7
|
+
return /*#__PURE__*/React.createElement("svg", {
|
|
8
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
9
|
+
width: "100%",
|
|
10
|
+
height: "auto",
|
|
11
|
+
viewBox: "0 0 16 16",
|
|
12
|
+
transform: `rotate(${rotateDeg})`,
|
|
13
|
+
fill: color
|
|
14
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
15
|
+
color: color,
|
|
16
|
+
fillRule: "evenodd",
|
|
17
|
+
transform: "translate(0,0)",
|
|
18
|
+
d: "M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z"
|
|
19
|
+
}));
|
|
20
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
+
declare const _default: ComponentMeta<React.FunctionComponent<{
|
|
4
|
+
color?: string | undefined;
|
|
5
|
+
rotateDeg: number;
|
|
6
|
+
}>>;
|
|
7
|
+
export default _default;
|
|
8
|
+
export declare const Basic: ComponentStory<React.FunctionComponent<{
|
|
9
|
+
color?: string | undefined;
|
|
10
|
+
rotateDeg: number;
|
|
11
|
+
}>>;
|
|
12
|
+
export declare const White: ComponentStory<React.FunctionComponent<{
|
|
13
|
+
color?: string | undefined;
|
|
14
|
+
rotateDeg: number;
|
|
15
|
+
}>>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Caret } from './caret';
|
|
3
|
+
export default {
|
|
4
|
+
title: 'Icons/Caret',
|
|
5
|
+
component: Caret
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
const Template = args => /*#__PURE__*/React.createElement(Caret, args);
|
|
9
|
+
|
|
10
|
+
export const Basic = Template.bind({});
|
|
11
|
+
Basic.args = {};
|
|
12
|
+
export const White = Template.bind({});
|
|
13
|
+
White.parameters = {
|
|
14
|
+
backgrounds: {
|
|
15
|
+
default: 'dark'
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
White.args = {
|
|
19
|
+
color: '#fff'
|
|
20
|
+
};
|