@ledgerhq/lumen-ui-rnative 0.1.29 → 0.1.31
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.
- package/dist/module/i18n/i18n.js +5 -1
- package/dist/module/i18n/i18n.js.map +1 -1
- package/dist/module/i18n/locales/en.json +5 -0
- package/dist/module/lib/Components/Avatar/Avatar.js +4 -4
- package/dist/module/lib/Components/Avatar/Avatar.js.map +1 -1
- package/dist/module/lib/Components/Avatar/Avatar.test.js +8 -8
- package/dist/module/lib/Components/Avatar/Avatar.test.js.map +1 -1
- package/dist/module/lib/Components/Trend/Trend.js +103 -0
- package/dist/module/lib/Components/Trend/Trend.js.map +1 -0
- package/dist/module/lib/Components/Trend/Trend.mdx +106 -0
- package/dist/module/lib/Components/Trend/Trend.stories.js +79 -0
- package/dist/module/lib/Components/Trend/Trend.stories.js.map +1 -0
- package/dist/module/lib/Components/Trend/Trend.test.js +149 -0
- package/dist/module/lib/Components/Trend/Trend.test.js.map +1 -0
- package/dist/module/lib/Components/Trend/index.js +5 -0
- package/dist/module/lib/Components/Trend/index.js.map +1 -0
- package/dist/module/lib/Components/Trend/types.js +4 -0
- package/dist/module/lib/Components/Trend/types.js.map +1 -0
- package/dist/module/lib/Components/index.js +5 -4
- package/dist/module/lib/Components/index.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Ar.js +2 -2
- package/dist/module/lib/Symbols/Icons/Ar.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ArrowLeft.js +1 -1
- package/dist/module/lib/Symbols/Icons/ArrowLeft.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ArrowRight.js +1 -1
- package/dist/module/lib/Symbols/Icons/ArrowRight.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/BasketPutIn.js +1 -1
- package/dist/module/lib/Symbols/Icons/BasketPutIn.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Clip.js +1 -1
- package/dist/module/lib/Symbols/Icons/ClockFill.js +5 -14
- package/dist/module/lib/Symbols/Icons/ClockFill.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CloudDownload.js +1 -1
- package/dist/module/lib/Symbols/Icons/CloudDownload.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CloudUpload.js +1 -1
- package/dist/module/lib/Symbols/Icons/CloudUpload.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsAddPlus.js +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsAddPlus.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsCheck.js +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsCheck.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsCross.js +1 -1
- package/dist/module/lib/Symbols/Icons/CoinsCross.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ColorPalette.js +1 -1
- package/dist/module/lib/Symbols/Icons/ColorPalette.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/CryptoBitcoinCoin.js +1 -1
- package/dist/module/lib/Symbols/Icons/Csv.js +1 -1
- package/dist/module/lib/Symbols/Icons/Csv.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Discord.js +1 -1
- package/dist/module/lib/Symbols/Icons/Discord.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Download.js +1 -1
- package/dist/module/lib/Symbols/Icons/Download.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Exchange.js +1 -1
- package/dist/module/lib/Symbols/Icons/Exchange.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ExchangeFill.js +1 -1
- package/dist/module/lib/Symbols/Icons/ExchangeFill.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ExitLogout.js +1 -1
- package/dist/module/lib/Symbols/Icons/ExitLogout.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Expand.js +1 -1
- package/dist/module/lib/Symbols/Icons/Expand.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Experiment2.js +1 -1
- package/dist/module/lib/Symbols/Icons/Experiment2.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/ExternalLink.js +1 -1
- package/dist/module/lib/Symbols/Icons/ExternalLink.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/FileDownload.js +1 -1
- package/dist/module/lib/Symbols/Icons/FileDownload.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Github.js +1 -1
- package/dist/module/lib/Symbols/Icons/HandCard.js +1 -1
- package/dist/module/lib/Symbols/Icons/HandCard.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Infinite.js +1 -1
- package/dist/module/lib/Symbols/Icons/MobileArrow.js +1 -1
- package/dist/module/lib/Symbols/Icons/MobileArrow.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/NftHide.js +1 -1
- package/dist/module/lib/Symbols/Icons/NftHide.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Parachute.js +1 -1
- package/dist/module/lib/Symbols/Icons/Parachute.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/PictureImage.js +1 -1
- package/dist/module/lib/Symbols/Icons/Range.js +1 -1
- package/dist/module/lib/Symbols/Icons/Range.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Reddit.js +2 -2
- package/dist/module/lib/Symbols/Icons/Reduce.js +1 -1
- package/dist/module/lib/Symbols/Icons/Reduce.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Screens.js +1 -1
- package/dist/module/lib/Symbols/Icons/Screens.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Shapes.js +1 -1
- package/dist/module/lib/Symbols/Icons/Share.js +1 -1
- package/dist/module/lib/Symbols/Icons/Share.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/StarHalf.js +1 -1
- package/dist/module/lib/Symbols/Icons/StarHalf.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/TransferHorizontal.js +1 -1
- package/dist/module/lib/Symbols/Icons/TransferHorizontal.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/TransferVertical.js +1 -1
- package/dist/module/lib/Symbols/Icons/TransferVertical.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/Truck.js +1 -1
- package/dist/module/lib/Symbols/Icons/Usb.js +1 -1
- package/dist/module/lib/Symbols/Icons/Usb.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/UserArrowRight.js +1 -1
- package/dist/module/lib/Symbols/Icons/UserArrowRight.js.map +1 -1
- package/dist/module/lib/Symbols/Icons/WalletInput.js +1 -1
- package/dist/module/lib/Symbols/Icons/WalletInput.js.map +1 -1
- package/dist/typescript/src/i18n/i18n.d.ts.map +1 -1
- package/dist/typescript/src/lib/Components/Trend/Trend.d.ts +3 -0
- package/dist/typescript/src/lib/Components/Trend/Trend.d.ts.map +1 -0
- package/dist/typescript/src/lib/Components/Trend/index.d.ts +3 -0
- package/dist/typescript/src/lib/Components/Trend/index.d.ts.map +1 -0
- package/dist/typescript/src/lib/Components/Trend/types.d.ts +20 -0
- package/dist/typescript/src/lib/Components/Trend/types.d.ts.map +1 -0
- package/dist/typescript/src/lib/Components/index.d.ts +5 -4
- package/dist/typescript/src/lib/Components/index.d.ts.map +1 -1
- package/dist/typescript/src/lib/Symbols/Icons/ClockFill.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/i18n/i18n.ts +12 -1
- package/src/i18n/locales/en.json +5 -0
- package/src/lib/Components/Avatar/Avatar.test.tsx +8 -8
- package/src/lib/Components/Avatar/Avatar.tsx +4 -4
- package/src/lib/Components/Trend/Trend.mdx +106 -0
- package/src/lib/Components/Trend/Trend.stories.tsx +61 -0
- package/src/lib/Components/Trend/Trend.test.tsx +125 -0
- package/src/lib/Components/Trend/Trend.tsx +118 -0
- package/src/lib/Components/Trend/index.ts +2 -0
- package/src/lib/Components/Trend/types.ts +20 -0
- package/src/lib/Components/index.ts +5 -4
- package/src/lib/Symbols/Icons/Ar.tsx +2 -2
- package/src/lib/Symbols/Icons/ArrowLeft.tsx +1 -1
- package/src/lib/Symbols/Icons/ArrowRight.tsx +1 -1
- package/src/lib/Symbols/Icons/BasketPutIn.tsx +1 -1
- package/src/lib/Symbols/Icons/Clip.tsx +1 -1
- package/src/lib/Symbols/Icons/ClockFill.tsx +1 -9
- package/src/lib/Symbols/Icons/CloudDownload.tsx +1 -1
- package/src/lib/Symbols/Icons/CloudUpload.tsx +1 -1
- package/src/lib/Symbols/Icons/CoinsAddPlus.tsx +1 -1
- package/src/lib/Symbols/Icons/CoinsCheck.tsx +1 -1
- package/src/lib/Symbols/Icons/CoinsCross.tsx +1 -1
- package/src/lib/Symbols/Icons/ColorPalette.tsx +1 -1
- package/src/lib/Symbols/Icons/CryptoBitcoinCoin.tsx +1 -1
- package/src/lib/Symbols/Icons/Csv.tsx +1 -1
- package/src/lib/Symbols/Icons/Discord.tsx +1 -1
- package/src/lib/Symbols/Icons/Download.tsx +1 -1
- package/src/lib/Symbols/Icons/Exchange.tsx +1 -1
- package/src/lib/Symbols/Icons/ExchangeFill.tsx +1 -1
- package/src/lib/Symbols/Icons/ExitLogout.tsx +1 -1
- package/src/lib/Symbols/Icons/Expand.tsx +1 -1
- package/src/lib/Symbols/Icons/Experiment2.tsx +1 -1
- package/src/lib/Symbols/Icons/ExternalLink.tsx +1 -1
- package/src/lib/Symbols/Icons/FileDownload.tsx +1 -1
- package/src/lib/Symbols/Icons/Github.tsx +1 -1
- package/src/lib/Symbols/Icons/HandCard.tsx +1 -1
- package/src/lib/Symbols/Icons/Infinite.tsx +1 -1
- package/src/lib/Symbols/Icons/MobileArrow.tsx +1 -1
- package/src/lib/Symbols/Icons/NftHide.tsx +1 -1
- package/src/lib/Symbols/Icons/Parachute.tsx +1 -1
- package/src/lib/Symbols/Icons/PictureImage.tsx +1 -1
- package/src/lib/Symbols/Icons/Range.tsx +1 -1
- package/src/lib/Symbols/Icons/Reddit.tsx +2 -2
- package/src/lib/Symbols/Icons/Reduce.tsx +1 -1
- package/src/lib/Symbols/Icons/Screens.tsx +1 -1
- package/src/lib/Symbols/Icons/Shapes.tsx +1 -1
- package/src/lib/Symbols/Icons/Share.tsx +1 -1
- package/src/lib/Symbols/Icons/StarHalf.tsx +1 -1
- package/src/lib/Symbols/Icons/TransferHorizontal.tsx +1 -1
- package/src/lib/Symbols/Icons/TransferVertical.tsx +1 -1
- package/src/lib/Symbols/Icons/Truck.tsx +1 -1
- package/src/lib/Symbols/Icons/Usb.tsx +1 -1
- package/src/lib/Symbols/Icons/UserArrowRight.tsx +1 -1
- package/src/lib/Symbols/Icons/WalletInput.tsx +1 -1
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { Meta, Canvas, Controls } from '@storybook/addon-docs/blocks';
|
|
2
|
+
import * as TrendStories from './Trend.stories';
|
|
3
|
+
import { CustomTabs, Tab } from '../../../../.storybook/components';
|
|
4
|
+
import { DoVsDontRow, DoBlockItem, DontBlockItem } from '../../../../.storybook/components/DoVsDont';
|
|
5
|
+
import CommonRulesDoAndDont from '../../../../.storybook/components/DoVsDont/CommonRulesDoAndDont.mdx';
|
|
6
|
+
|
|
7
|
+
<Meta title='Communication/Trend' of={TrendStories} />
|
|
8
|
+
|
|
9
|
+
# Trend
|
|
10
|
+
|
|
11
|
+
<CustomTabs>
|
|
12
|
+
<Tab label="Overview">
|
|
13
|
+
|
|
14
|
+
## Introduction
|
|
15
|
+
|
|
16
|
+
A compact indicator used to communicate directional change in a numeric value, typically a percentage. It combines an icon and a formatted label to convey whether a value has gone up, down, or stayed flat.
|
|
17
|
+
|
|
18
|
+
> View in [Figma](https://www.figma.com/design/JxaLVMTWirCpU0rsbZ30k7/2.-Components-Library?node-id=892-5393).
|
|
19
|
+
|
|
20
|
+
## Anatomy
|
|
21
|
+
|
|
22
|
+
- **Icon:** A directional triangle (up or down) or a minus symbol that visually reinforces the direction of change at a glance.
|
|
23
|
+
- **Value:** The numeric percentage formatted to exactly two decimal places, ensuring consistent alignment across lists and tables.
|
|
24
|
+
|
|
25
|
+
## Properties
|
|
26
|
+
|
|
27
|
+
### Overview
|
|
28
|
+
|
|
29
|
+
<Canvas of={TrendStories.Base} />
|
|
30
|
+
<Controls of={TrendStories.Base} />
|
|
31
|
+
|
|
32
|
+
### Variants
|
|
33
|
+
|
|
34
|
+
The variant is derived automatically from the `value` prop. No manual selection needed! This ensures the color and icon always stay in sync with the actual data.
|
|
35
|
+
|
|
36
|
+
- **Positive** - value greater than 0: green color, triangle up icon
|
|
37
|
+
- **Negative** - value less than 0: red color, triangle down icon
|
|
38
|
+
- **Neutral** - value equal to 0: muted color, minus icon
|
|
39
|
+
|
|
40
|
+
<Canvas of={TrendStories.VariantShowcase} />
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
### Size
|
|
45
|
+
|
|
46
|
+
Two sizes are available to accommodate different layout densities. Use `md` in most contexts and `sm` when space is constrained, such as inside a table cell or a compact list item.
|
|
47
|
+
|
|
48
|
+
- **md** (default) - standard body text and icon sizes
|
|
49
|
+
- **sm** - smaller text and icon, suitable for dense UIs
|
|
50
|
+
|
|
51
|
+
<Canvas of={TrendStories.SizeShowcase} />
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
### Disabled
|
|
56
|
+
|
|
57
|
+
When `disabled` is `true`, the icon and text both render in a muted, non-interactive style regardless of the underlying value. Use this when the data is unavailable, loading, or the surrounding context is non-interactive.
|
|
58
|
+
|
|
59
|
+
<Canvas of={TrendStories.DisabledShowcase} />
|
|
60
|
+
|
|
61
|
+
</Tab>
|
|
62
|
+
<Tab label="Implementation">
|
|
63
|
+
|
|
64
|
+
## Setup
|
|
65
|
+
|
|
66
|
+
Install and set up the library with our [Setup Guide →](?path=/docs/getting-started-setup--docs).
|
|
67
|
+
|
|
68
|
+
### Basic Usage
|
|
69
|
+
|
|
70
|
+
Pass any numeric value - the component handles color, icon, and formatting automatically.
|
|
71
|
+
|
|
72
|
+
```tsx
|
|
73
|
+
import { Trend } from '@ledgerhq/lumen-ui-rnative';
|
|
74
|
+
|
|
75
|
+
function MyComponent() {
|
|
76
|
+
return <Trend value={5.25} />;
|
|
77
|
+
}
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Sizes
|
|
81
|
+
|
|
82
|
+
Choose `sm` for dense layouts like tables or compact list rows, and `md` for standard content areas.
|
|
83
|
+
|
|
84
|
+
```tsx
|
|
85
|
+
<Trend value={3.14} size='md' />
|
|
86
|
+
<Trend value={3.14} size='sm' />
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### Disabled State
|
|
90
|
+
|
|
91
|
+
Wrap or pass `disabled` when the value is unavailable or the parent context is non-interactive. The component style updates automatically - no extra styling needed.
|
|
92
|
+
|
|
93
|
+
```tsx
|
|
94
|
+
<Trend value={5.25} disabled />
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
### Layout Adjustments
|
|
98
|
+
|
|
99
|
+
Use `lx` for layout only - not for overriding colors or typography. The component's visual appearance is controlled exclusively via props.
|
|
100
|
+
|
|
101
|
+
```tsx
|
|
102
|
+
<Trend value={-1.5} lx={{ marginTop: 's4' }} />
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
</Tab>
|
|
106
|
+
</CustomTabs>
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react-native-web-vite';
|
|
2
|
+
import { Box } from '../Utility/Box';
|
|
3
|
+
import { Trend } from './Trend';
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof Trend> = {
|
|
6
|
+
component: Trend,
|
|
7
|
+
title: 'Communication/Trend',
|
|
8
|
+
argTypes: {
|
|
9
|
+
value: {
|
|
10
|
+
control: 'number',
|
|
11
|
+
},
|
|
12
|
+
size: {
|
|
13
|
+
control: 'radio',
|
|
14
|
+
options: ['sm', 'md'],
|
|
15
|
+
},
|
|
16
|
+
disabled: {
|
|
17
|
+
control: 'boolean',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
export default meta;
|
|
23
|
+
|
|
24
|
+
type Story = StoryObj<typeof Trend>;
|
|
25
|
+
|
|
26
|
+
export const Base: Story = {
|
|
27
|
+
args: {
|
|
28
|
+
value: 5.25,
|
|
29
|
+
size: 'md',
|
|
30
|
+
disabled: false,
|
|
31
|
+
},
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export const VariantShowcase: Story = {
|
|
35
|
+
render: () => (
|
|
36
|
+
<Box lx={{ flexDirection: 'column', gap: 's8' }}>
|
|
37
|
+
<Trend value={5.25} />
|
|
38
|
+
<Trend value={-3.14} />
|
|
39
|
+
<Trend value={0} />
|
|
40
|
+
</Box>
|
|
41
|
+
),
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export const SizeShowcase: Story = {
|
|
45
|
+
render: () => (
|
|
46
|
+
<Box lx={{ flexDirection: 'row', alignItems: 'center', gap: 's16' }}>
|
|
47
|
+
<Trend value={5.25} size='md' />
|
|
48
|
+
<Trend value={5.25} size='sm' />
|
|
49
|
+
</Box>
|
|
50
|
+
),
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
export const DisabledShowcase: Story = {
|
|
54
|
+
render: () => (
|
|
55
|
+
<Box lx={{ flexDirection: 'column', gap: 's8' }}>
|
|
56
|
+
<Trend value={5.25} disabled />
|
|
57
|
+
<Trend value={-3.14} disabled />
|
|
58
|
+
<Trend value={0} disabled />
|
|
59
|
+
</Box>
|
|
60
|
+
),
|
|
61
|
+
};
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import { describe, it, expect } from '@jest/globals';
|
|
2
|
+
import { ledgerLiveThemes } from '@ledgerhq/lumen-design-core';
|
|
3
|
+
import { render } from '@testing-library/react-native';
|
|
4
|
+
import { ThemeProvider } from '../ThemeProvider/ThemeProvider';
|
|
5
|
+
import { Trend } from './Trend';
|
|
6
|
+
|
|
7
|
+
const TestWrapper = ({ children }: { children: React.ReactNode }) => (
|
|
8
|
+
<ThemeProvider themes={ledgerLiveThemes} colorScheme='dark' locale='en'>
|
|
9
|
+
{children}
|
|
10
|
+
</ThemeProvider>
|
|
11
|
+
);
|
|
12
|
+
|
|
13
|
+
describe('Trend Component', () => {
|
|
14
|
+
it('should render positive value', () => {
|
|
15
|
+
const { getByText } = render(
|
|
16
|
+
<TestWrapper>
|
|
17
|
+
<Trend value={5.5} />
|
|
18
|
+
</TestWrapper>,
|
|
19
|
+
);
|
|
20
|
+
expect(getByText('5.50%')).toBeTruthy();
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
it('should render negative value', () => {
|
|
24
|
+
const { getByText } = render(
|
|
25
|
+
<TestWrapper>
|
|
26
|
+
<Trend value={-3.2} />
|
|
27
|
+
</TestWrapper>,
|
|
28
|
+
);
|
|
29
|
+
expect(getByText('-3.20%')).toBeTruthy();
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
it('should render neutral when value is zero', () => {
|
|
33
|
+
const { getByText } = render(
|
|
34
|
+
<TestWrapper>
|
|
35
|
+
<Trend value={0} />
|
|
36
|
+
</TestWrapper>,
|
|
37
|
+
);
|
|
38
|
+
expect(getByText('0.00%')).toBeTruthy();
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
it('should render with sm size', () => {
|
|
42
|
+
const { getByText } = render(
|
|
43
|
+
<TestWrapper>
|
|
44
|
+
<Trend value={1.5} size='sm' />
|
|
45
|
+
</TestWrapper>,
|
|
46
|
+
);
|
|
47
|
+
expect(getByText('1.50%')).toBeTruthy();
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
it('should render with md size', () => {
|
|
51
|
+
const { getByText } = render(
|
|
52
|
+
<TestWrapper>
|
|
53
|
+
<Trend value={1.5} size='md' />
|
|
54
|
+
</TestWrapper>,
|
|
55
|
+
);
|
|
56
|
+
expect(getByText('1.50%')).toBeTruthy();
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
it('should render in disabled state', () => {
|
|
60
|
+
const { getByText } = render(
|
|
61
|
+
<TestWrapper>
|
|
62
|
+
<Trend value={5} disabled />
|
|
63
|
+
</TestWrapper>,
|
|
64
|
+
);
|
|
65
|
+
expect(getByText('5.00%')).toBeTruthy();
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
it('should pass testID to root element', () => {
|
|
69
|
+
const { getByTestId } = render(
|
|
70
|
+
<TestWrapper>
|
|
71
|
+
<Trend testID='trend-id' value={10} />
|
|
72
|
+
</TestWrapper>,
|
|
73
|
+
);
|
|
74
|
+
expect(getByTestId('trend-id')).toBeTruthy();
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
it('should format value to 2 decimal places', () => {
|
|
78
|
+
const { getByText } = render(
|
|
79
|
+
<TestWrapper>
|
|
80
|
+
<Trend value={1.123456} />
|
|
81
|
+
</TestWrapper>,
|
|
82
|
+
);
|
|
83
|
+
expect(getByText('1.12%')).toBeTruthy();
|
|
84
|
+
});
|
|
85
|
+
|
|
86
|
+
it('should render all variants side by side', () => {
|
|
87
|
+
const { getByText } = render(
|
|
88
|
+
<TestWrapper>
|
|
89
|
+
<Trend value={10} />
|
|
90
|
+
<Trend value={-10} />
|
|
91
|
+
<Trend value={0} />
|
|
92
|
+
</TestWrapper>,
|
|
93
|
+
);
|
|
94
|
+
expect(getByText('10.00%')).toBeTruthy();
|
|
95
|
+
expect(getByText('-10.00%')).toBeTruthy();
|
|
96
|
+
expect(getByText('0.00%')).toBeTruthy();
|
|
97
|
+
});
|
|
98
|
+
|
|
99
|
+
it('should expose positive accessibility label', () => {
|
|
100
|
+
const { getByLabelText } = render(
|
|
101
|
+
<TestWrapper>
|
|
102
|
+
<Trend value={5.5} />
|
|
103
|
+
</TestWrapper>,
|
|
104
|
+
);
|
|
105
|
+
expect(getByLabelText('Trending up by 5.50%')).toBeTruthy();
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
it('should expose negative accessibility label with absolute value', () => {
|
|
109
|
+
const { getByLabelText } = render(
|
|
110
|
+
<TestWrapper>
|
|
111
|
+
<Trend value={-3.2} />
|
|
112
|
+
</TestWrapper>,
|
|
113
|
+
);
|
|
114
|
+
expect(getByLabelText('Trending down by 3.20%')).toBeTruthy();
|
|
115
|
+
});
|
|
116
|
+
|
|
117
|
+
it('should expose neutral accessibility label', () => {
|
|
118
|
+
const { getByLabelText } = render(
|
|
119
|
+
<TestWrapper>
|
|
120
|
+
<Trend value={0} />
|
|
121
|
+
</TestWrapper>,
|
|
122
|
+
);
|
|
123
|
+
expect(getByLabelText('No change, 0.00%')).toBeTruthy();
|
|
124
|
+
});
|
|
125
|
+
});
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { useDisabledContext } from '@ledgerhq/lumen-utils-shared';
|
|
2
|
+
import { StyleSheet } from 'react-native';
|
|
3
|
+
import { useCommonTranslation } from '../../../i18n';
|
|
4
|
+
import type { LumenTextStyle } from '../../../styles';
|
|
5
|
+
import { useStyleSheet } from '../../../styles';
|
|
6
|
+
import { Minus, TriangleDown, TriangleUp } from '../../Symbols';
|
|
7
|
+
import type { IconSize } from '../Icon';
|
|
8
|
+
import { Box, Text } from '../Utility';
|
|
9
|
+
import type { TrendProps } from './types';
|
|
10
|
+
|
|
11
|
+
type TrendVariant = 'positive' | 'negative' | 'neutral';
|
|
12
|
+
|
|
13
|
+
function getVariant(value: number): TrendVariant {
|
|
14
|
+
if (value === 0) {
|
|
15
|
+
return 'neutral';
|
|
16
|
+
}
|
|
17
|
+
return value > 0 ? 'positive' : 'negative';
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export function Trend({
|
|
21
|
+
value,
|
|
22
|
+
size = 'md',
|
|
23
|
+
lx = {},
|
|
24
|
+
disabled: disabledProp = false,
|
|
25
|
+
style,
|
|
26
|
+
...props
|
|
27
|
+
}: TrendProps) {
|
|
28
|
+
const variant = getVariant(value);
|
|
29
|
+
|
|
30
|
+
const disabled = useDisabledContext({
|
|
31
|
+
consumerName: 'Trend',
|
|
32
|
+
mergeWith: { disabled: disabledProp },
|
|
33
|
+
});
|
|
34
|
+
const { t } = useCommonTranslation();
|
|
35
|
+
|
|
36
|
+
const styles = useStyles({ size, variant, disabled });
|
|
37
|
+
|
|
38
|
+
const Icon = {
|
|
39
|
+
positive: TriangleUp,
|
|
40
|
+
negative: TriangleDown,
|
|
41
|
+
neutral: Minus,
|
|
42
|
+
}[variant];
|
|
43
|
+
|
|
44
|
+
const iconSize = (
|
|
45
|
+
{
|
|
46
|
+
md: 16,
|
|
47
|
+
sm: 12,
|
|
48
|
+
} as const
|
|
49
|
+
)[size] as IconSize;
|
|
50
|
+
|
|
51
|
+
const iconColor = (
|
|
52
|
+
{
|
|
53
|
+
positive: 'success',
|
|
54
|
+
negative: 'error',
|
|
55
|
+
neutral: 'muted',
|
|
56
|
+
} as const
|
|
57
|
+
)[variant] as LumenTextStyle['color'];
|
|
58
|
+
|
|
59
|
+
const absoluteFormattedValue = `${Math.abs(value).toFixed(2)}%`;
|
|
60
|
+
const formattedValue =
|
|
61
|
+
value < 0 ? `-${absoluteFormattedValue}` : absoluteFormattedValue;
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<Box
|
|
65
|
+
accessible
|
|
66
|
+
accessibilityLabel={t(`components.trend.${variant}AriaLabel`, {
|
|
67
|
+
value: absoluteFormattedValue,
|
|
68
|
+
})}
|
|
69
|
+
accessibilityState={{ disabled }}
|
|
70
|
+
lx={lx}
|
|
71
|
+
style={[styles.container, style]}
|
|
72
|
+
{...props}
|
|
73
|
+
>
|
|
74
|
+
<Icon size={iconSize} color={disabled ? 'disabled' : iconColor} />
|
|
75
|
+
<Text style={styles.text}>{formattedValue}</Text>
|
|
76
|
+
</Box>
|
|
77
|
+
);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
const useStyles = ({
|
|
81
|
+
size,
|
|
82
|
+
variant,
|
|
83
|
+
disabled,
|
|
84
|
+
}: {
|
|
85
|
+
size: NonNullable<TrendProps['size']>;
|
|
86
|
+
variant: TrendVariant;
|
|
87
|
+
disabled: boolean;
|
|
88
|
+
}) =>
|
|
89
|
+
useStyleSheet(
|
|
90
|
+
(t) => {
|
|
91
|
+
const color = {
|
|
92
|
+
positive: t.colors.text.success,
|
|
93
|
+
negative: t.colors.text.error,
|
|
94
|
+
neutral: t.colors.text.muted,
|
|
95
|
+
}[variant];
|
|
96
|
+
|
|
97
|
+
const sizeMap = {
|
|
98
|
+
sm: t.typographies.body3,
|
|
99
|
+
md: t.typographies.body2,
|
|
100
|
+
}[size];
|
|
101
|
+
|
|
102
|
+
return {
|
|
103
|
+
container: {
|
|
104
|
+
flexDirection: 'row',
|
|
105
|
+
alignItems: 'center',
|
|
106
|
+
gap: t.spacings.s2,
|
|
107
|
+
},
|
|
108
|
+
text: StyleSheet.flatten([
|
|
109
|
+
{
|
|
110
|
+
...sizeMap,
|
|
111
|
+
color,
|
|
112
|
+
},
|
|
113
|
+
disabled && { color: t.colors.text.disabled },
|
|
114
|
+
]),
|
|
115
|
+
};
|
|
116
|
+
},
|
|
117
|
+
[size, variant, disabled],
|
|
118
|
+
);
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { BoxProps } from '../Utility';
|
|
2
|
+
|
|
3
|
+
export type TrendProps = {
|
|
4
|
+
/**
|
|
5
|
+
* The value to display in the trend. This value affects the appearance of the component in terms of color and icon.
|
|
6
|
+
* @required
|
|
7
|
+
*/
|
|
8
|
+
value: number;
|
|
9
|
+
/**
|
|
10
|
+
* The size of the trend component.
|
|
11
|
+
* @default md
|
|
12
|
+
*/
|
|
13
|
+
size?: 'sm' | 'md';
|
|
14
|
+
/**
|
|
15
|
+
* When `true`, shows a muted appearance on the trend, regardless of value.
|
|
16
|
+
*
|
|
17
|
+
* @default false
|
|
18
|
+
*/
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
} & Omit<BoxProps, 'children'>;
|
|
@@ -4,15 +4,15 @@ export * from './AmountInput';
|
|
|
4
4
|
export * from './Avatar';
|
|
5
5
|
export * from './Banner';
|
|
6
6
|
export * from './BottomSheet';
|
|
7
|
-
export * from './DotCount';
|
|
8
|
-
export * from './DotIndicator';
|
|
9
7
|
export * from './Button';
|
|
10
8
|
export * from './Card';
|
|
11
9
|
export * from './CardButton';
|
|
12
|
-
export * from './ContentBanner';
|
|
13
10
|
export * from './Checkbox';
|
|
11
|
+
export * from './ContentBanner';
|
|
14
12
|
export * from './Divider';
|
|
13
|
+
export * from './DotCount';
|
|
15
14
|
export * from './DotIcon';
|
|
15
|
+
export * from './DotIndicator';
|
|
16
16
|
export * from './DotSymbol';
|
|
17
17
|
export * from './Icon';
|
|
18
18
|
export * from './IconButton';
|
|
@@ -37,9 +37,10 @@ export * from './Subheader';
|
|
|
37
37
|
export * from './Switch';
|
|
38
38
|
export * from './TabBar';
|
|
39
39
|
export * from './Tag';
|
|
40
|
-
export * from './Utility';
|
|
41
40
|
export * from './TextInput';
|
|
42
41
|
export * from './ThemeProvider';
|
|
43
42
|
export * from './Tile';
|
|
44
43
|
export * from './TileButton';
|
|
45
44
|
export * from './Tooltip';
|
|
45
|
+
export * from './Trend';
|
|
46
|
+
export * from './Utility';
|
|
@@ -36,11 +36,11 @@ export const Ar = createIcon(
|
|
|
36
36
|
<Svg width={24} height={24} fill='currentColor' viewBox='0 0 17 16'>
|
|
37
37
|
<Path
|
|
38
38
|
fill='currentColor'
|
|
39
|
-
d='M8.197 4.967a.166.166 0 1 1-.333 0 .166.166 0 0 1 .333 0m-3.848 6.83a.167.167 0 0 1-.23-.053.167.167 0 0 1 .283-.176.167.167 0 0 1-.053.229m3.848-6.164a.167.167 0 0 1-.166.167.17.17 0 0 1-.
|
|
39
|
+
d='M8.197 4.967a.166.166 0 1 1-.333 0 .166.166 0 0 1 .333 0m-3.848 6.83a.167.167 0 0 1-.23-.053.167.167 0 0 1 .283-.176.167.167 0 0 1-.053.229m3.848-6.164a.167.167 0 0 1-.166.167.17.17 0 0 1-.167-.167.167.167 0 0 1 .333 0m-3.283 5.812a.166.166 0 1 1-.176-.283.166.166 0 0 1 .176.283M8.197 6.3a.167.167 0 1 1-.334 0 .167.167 0 0 1 .334 0M5.48 11.093a.166.166 0 1 1-.175-.282.166.166 0 0 1 .175.282m2.717-4.126a.166.166 0 1 1-.333 0 .166.166 0 0 1 .333 0m-2.15 3.774a.166.166 0 1 1-.177-.282.166.166 0 0 1 .177.282m2.15-3.108a.167.167 0 0 1-.334 0 .167.167 0 0 1 .334 0M6.612 10.39a.166.166 0 1 1-.175-.283.166.166 0 0 1 .175.283m.567-.352a.166.166 0 1 1-.176-.283.166.166 0 0 1 .176.283M8.197 8.3a.167.167 0 0 1-.166.167.167.167 0 1 1 0-.334c.092 0 .166.075.166.167m.73 1.777a.167.167 0 1 1-.288-.166.167.167 0 0 1 .288.166m.577.333a.167.167 0 1 1-.289-.165.167.167 0 0 1 .289.165m.578.334a.167.167 0 0 1-.228.061.166.166 0 1 1 .228-.061m.577.333a.167.167 0 1 1-.288-.166.167.167 0 0 1 .288.166m.577.333a.167.167 0 1 1-.289-.165.167.167 0 0 1 .29.165m.578.334a.167.167 0 0 1-.228.061.166.166 0 1 1 .228-.061'
|
|
40
40
|
/>
|
|
41
41
|
<Path
|
|
42
42
|
fill='currentColor'
|
|
43
|
-
d='m3.364 7-.
|
|
43
|
+
d='m3.364 7-.29-.581a.65.65 0 0 0-.36.581zm9 0h.65a.65.65 0 0 0-.342-.572zM8.03 14.667l-.29.581a.65.65 0 0 0 .599-.009zM8.013 1.349l.46-.46-.46-.459-.46.46zm-1.843.924a.65.65 0 1 0 .92.919l-.46-.46zm2.766.919a.65.65 0 1 0 .92-.92l-.46.46zM.775 13.966l-.635-.14-.14.634.635.14zm1.77 1.056a.65.65 0 1 0 .28-1.27l-.14.635zm-.714-2.826a.65.65 0 0 0-1.27-.28l.635.14zm13.116 1.77.14.634.635-.14-.14-.634zm-2.05-.214a.65.65 0 0 0 .28 1.27l-.14-.635zm2.263-1.836a.65.65 0 0 0-1.27.28l.636-.14zm-11.796.417h.65V7h-1.3v5.333zm0-5.333.29.581 4.667-2.333-.29-.581-.291-.582L3.073 6.42zM8.03 4.667l-.308.572 4.334 2.333.308-.572.308-.572-4.333-2.334zM12.364 7h-.65v5.333h1.3V7zm0 5.333-.308-.572-4.334 2.333.308.573.309.572 4.333-2.333zM8.03 14.667l.291-.582-4.667-2.333-.29.581-.29.582 4.666 2.333zM12.364 7l-.327-.562L7.73 8.94l.326.562.327.562 4.308-2.502zM8.055 9.502h-.65v5.172h1.3V9.502zm0 0 .306-.573L3.67 6.426 3.364 7l-.306.574 4.691 2.502zM8.03 4.667l.65-.004-.017-3.317-.65.003-.65.004.017 3.317zm-1.4-1.935.46.46 1.382-1.383-.46-.46-.459-.46L6.17 2.274zM8.013 1.35l-.46.46 1.383 1.383.46-.46.46-.46L8.471.89zm-4.65 10.984-.346-.55-2.589 1.633.347.55.346.55 2.59-1.633zm-.678 2.054.14-.635-1.91-.421-.14.635-.14.634 1.91.422zm-1.91-.421.635.14.42-1.91-.634-.14-.635-.14-.421 1.91zm11.589-1.633-.348.55 2.584 1.632.347-.55.347-.549-2.583-1.632zm.673 2.054.14.635 1.91-.422-.14-.634-.14-.635-1.91.421zm1.91-.421.635-.14-.422-1.91-.634.14-.635.14.421 1.91z'
|
|
44
44
|
/>
|
|
45
45
|
</Svg>,
|
|
46
46
|
);
|
|
@@ -39,7 +39,7 @@ export const BasketPutIn = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M5.5 12h6.667M5.5 12a1.167 1.167 0 1 0 0 2.333A1.167 1.167 0 0 0 5.5 12m6.667 0a1.167 1.167 0 1 0 0 2.333 1.167 1.167 0 0 0 0-2.333M3.762 4.667h1.571M8.667 4v3.
|
|
42
|
+
d='M5.5 12h6.667M5.5 12a1.167 1.167 0 1 0 0 2.333A1.167 1.167 0 0 0 5.5 12m6.667 0a1.167 1.167 0 1 0 0 2.333 1.167 1.167 0 0 0 0-2.333M3.762 4.667h1.571M8.667 4v3.333M10 6 8.667 7.333 7.333 6m-2 6-2-9.333H2m10 2h1.333a.667.667 0 0 1 .644.838l-1.066 4a.67.67 0 0 1-.644.495H4.905'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const Clip = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M8.967 6.253 5.28 9.94a1.083 1.083 0 0 0 0 1.547h-.007c.427.427 1.12.427 1.547 0l5.747-5.75a2.197 2.197 0 0 0 0-3.1l-.007-.007a2.19 2.19 0 0 0-3.1-.007h-.007L3.7 8.369a3.
|
|
42
|
+
d='M8.967 6.253 5.28 9.94a1.083 1.083 0 0 0 0 1.547h-.007c.427.427 1.12.427 1.547 0l5.747-5.75a2.197 2.197 0 0 0 0-3.1l-.007-.007a2.19 2.19 0 0 0-3.1-.007h-.007L3.7 8.369a3.277 3.277 0 0 0-.007 4.639 3.283 3.283 0 0 0 4.64 0v-.007l4.2-4.2'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -37,16 +37,8 @@ export const ClockFill = createIcon(
|
|
|
37
37
|
<Path
|
|
38
38
|
fill='currentColor'
|
|
39
39
|
fillRule='evenodd'
|
|
40
|
-
d='
|
|
40
|
+
d='M8 1.5a6.5 6.5 0 1 1 0 13c-3.596 0-6.5-2.91-6.5-6.5 0-3.596 2.91-6.5 6.5-6.5m0 2.116a.65.65 0 0 0-.65.65V8c0 .359.291.65.65.65h3.1a.65.65 0 0 0 0-1.3H8.65V4.267a.65.65 0 0 0-.65-.65'
|
|
41
41
|
clipRule='evenodd'
|
|
42
42
|
/>
|
|
43
|
-
<Path fill='currentColor' d='M11.1 8H8zM8 8V4.267z' />
|
|
44
|
-
<Path
|
|
45
|
-
stroke='#fff'
|
|
46
|
-
strokeLinecap='round'
|
|
47
|
-
strokeLinejoin='round'
|
|
48
|
-
strokeWidth={1.3}
|
|
49
|
-
d='M11.1 8H8V4.267'
|
|
50
|
-
/>
|
|
51
43
|
</Svg>,
|
|
52
44
|
);
|
|
@@ -39,7 +39,7 @@ export const CloudDownload = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M8 10.
|
|
42
|
+
d='M8 10.667V14m1.333-1.333L8 14l-1.333-1.333m-1.734-1.334H4.66A3.33 3.33 0 0 1 1.327 8a3.32 3.32 0 0 1 2.879-3.293V4.7a3.98 3.98 0 0 1 3.78-2.713c2.207 0 4 1.786 4 4a2.67 2.67 0 0 1 2.667 2.666c0 1.467-1.2 2.667-2.667 2.667h-.94'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const CloudUpload = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M4.933 11.333H4.66A3.33 3.33 0 0 1 1.327 8a3.32 3.32 0 0 1 2.879-3.293V4.7a3.98 3.98 0 0 1 3.78-2.713c2.207 0 4 1.786 4 4a2.67 2.67 0 0 1 2.667 2.666c0 1.467-1.2 2.667-2.667 2.667h-.
|
|
42
|
+
d='M4.933 11.333H4.66A3.33 3.33 0 0 1 1.327 8a3.32 3.32 0 0 1 2.879-3.293V4.7a3.98 3.98 0 0 1 3.78-2.713c2.207 0 4 1.786 4 4a2.67 2.67 0 0 1 2.667 2.666c0 1.467-1.2 2.667-2.667 2.667h-.94m-4.38.68L8 10.667 9.333 12M8 10.667V14'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const CoinsAddPlus = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='
|
|
42
|
+
d='M8.667 7V5.333c0-.353-.352-.692-.977-.942S6.217 4 5.333 4s-1.732.14-2.357.39S2 4.98 2 5.334v5.334C2 11.4 3.493 12 5.333 12M2 5.333c0 .354.351.693.976.943s1.473.39 2.357.39 1.732-.14 2.357-.39.977-.589.977-.943M7.333 10c0 .733 1.487 1.333 3.334 1.333 1.84 0 3.333-.6 3.333-1.333m-6.667 0v2.667C7.333 13.4 8.82 14 10.667 14c1.84 0 3.333-.6 3.333-1.333V10m-6.667 0c0-.74 1.487-1.333 3.334-1.333C12.507 8.667 14 9.26 14 10m-2.667-6.667H14m-1.333 1.334V2M5.333 9.333C3.493 9.333 2 8.733 2 8'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const CoinsCheck = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='
|
|
42
|
+
d='M8.667 7V5.333c0-.353-.352-.692-.977-.942S6.217 4 5.333 4s-1.732.14-2.357.39S2 4.98 2 5.334v5.334C2 11.4 3.493 12 5.333 12M2 5.333c0 .354.351.693.976.943s1.473.39 2.357.39 1.732-.14 2.357-.39.977-.589.977-.943M7.333 10c0 .733 1.487 1.333 3.334 1.333 1.84 0 3.333-.6 3.333-1.333m-6.667 0v2.667C7.333 13.4 8.82 14 10.667 14c1.84 0 3.333-.6 3.333-1.333V10m-6.667 0c0-.74 1.487-1.333 3.334-1.333C12.507 8.667 14 9.26 14 10m-8.667-.667C3.493 9.333 2 8.733 2 8m12.667-5.375-2 2-1.2-1.2'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const CoinsCross = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M2 5.333c0 .734 1.487 1.334 3.333 1.
|
|
42
|
+
d='M2 5.333c0 .734 1.487 1.334 3.333 1.334m3.334-1.334c0-.353-.352-.692-.977-.942S6.217 4 5.333 4s-1.732.14-2.357.39S2 4.98 2 5.334v5.334C2 11.4 3.493 12 5.333 12M2 5.333c0 .354.351.693.976.943s1.473.39 2.357.39m0 0c.884 0 1.732-.14 2.357-.39s.977-.589.977-.943m0 0V7m3-2.667 2-2m0 2-2-2M2 8c0 .733 1.487 1.327 3.333 1.327m-.006.006c-1.847 0-3.334-.6-3.334-1.333m5.34 2c0 .733 1.487 1.333 3.334 1.333 1.84 0 3.333-.6 3.333-1.333v2.667C14 13.4 12.506 14 10.666 14c-1.847 0-3.334-.6-3.334-1.333zm6.665 0c0-.74-1.493-1.333-3.333-1.333S7.33 9.26 7.33 10c0 .733 1.487 1.333 3.334 1.333 1.84 0 3.333-.6 3.333-1.333'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -39,7 +39,7 @@ export const ColorPalette = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M11.148 5.285a1.334 1.334 0 0 1 1.569.594l1.103 1.885a1.334 1.334 0 0 1-.49 1.832l-6.705 3.822a4.46 4.46 0 0 1-2.21.585m-.083 0a2.334 2.334 0 0 0 2.334-2.335V3.331c0-.736-.597-1.333-1.334-1.333h-2c-.737 0-1.334.597-1.334 1.333v8.337a2.334 2.334 0 0 0 2.334 2.335m0 0a3.13 3.13 0 0 0 2.703-1.55l3.969-6.786a1.334 1.334 0 0 0-.491-1.832L8.588 2.738a1.334 1.334 0 0 0-1.812.485l-.11.
|
|
42
|
+
d='M11.148 5.285a1.334 1.334 0 0 1 1.569.594l1.103 1.885a1.334 1.334 0 0 1-.49 1.832l-6.705 3.822a4.46 4.46 0 0 1-2.21.585m-.083 0a2.334 2.334 0 0 0 2.334-2.335V3.331c0-.736-.597-1.333-1.334-1.333h-2c-.737 0-1.334.597-1.334 1.333v8.337a2.334 2.334 0 0 0 2.334 2.335m0 0a3.13 3.13 0 0 0 2.703-1.55l3.969-6.786a1.334 1.334 0 0 0-.491-1.832L8.588 2.738a1.334 1.334 0 0 0-1.812.485l-.11.188M4.5 11.669a.167.167 0 1 1-.334-.001.167.167 0 0 1 .334 0'
|
|
43
43
|
/>
|
|
44
44
|
</Svg>,
|
|
45
45
|
);
|
|
@@ -36,7 +36,7 @@ export const CryptoBitcoinCoin = createIcon(
|
|
|
36
36
|
<Svg width={24} height={24} fill='currentColor' viewBox='0 0 16 16'>
|
|
37
37
|
<Path
|
|
38
38
|
fill='currentColor'
|
|
39
|
-
d='M14.65 8a.65.65 0 1 0-1.3 0h1.3M8 2.65a.65.65 0 0 0 0-1.3v1.3M11.033.683a.65.65 0 1 0 0 1.3v-1.3M14.01 4.96a.65.65 0 1 0 1.3 0h-1.3m-2.977-2.277a.65.65 0 1 0 0 1.3v-1.3m.977 2.277a.65.65 0 1 0 1.3 0h-1.3M6.667 10h-.65c0 .359.29.65.65.65zm.65-4a.65.65 0 0 0-1.3 0h1.3m1.373-.667a.65.65 0 0 0-1.3 0h1.3M7.39 6a.65.65 0 0 0 1.3 0h-1.3m1.3 4a.65.65 0 0 0-1.3 0h1.3m-1.3.667a.65.65 0 1 0 1.3 0h-1.3M6.667 8v-.65a.65.65 0 0 0-.65.65zM6.66 6v-.65a.65.65 0 0 0-.65.65zm0 2h-.65c0 .359.291.65.65.65zM14 8h-.65A5.35 5.35 0 0 1 8 13.35v1.3A6.65 6.65 0 0 0 14.65 8zm-6 6v-.65A5.35 5.35 0 0 1 2.65 8h-1.3A6.65 6.65 0 0 0 8 14.65zM2 8h.65A5.35 5.35 0 0 1 8 2.65v-1.3A6.65 6.65 0 0 0 1.35 8zm9.033-6.667v.65A2.976 2.976 0 0 1 14.01 4.96h1.3A4.276 4.276 0 0 0 11.033.683zm0 2v.65c.541 0 .977.436.977.977h1.3a2.275 2.275 0 0 0-2.277-2.277zM6.667 10h.65V6h-1.3v4zM8.04 5.333h-.65V6h1.3v-.667zm0 4.667h-.65v.667h1.3V10zM6.667 8v.65H9v-1.3H6.667zM9 8v.65c.19 0 .35.
|
|
39
|
+
d='M14.65 8a.65.65 0 1 0-1.3 0h1.3M8 2.65a.65.65 0 0 0 0-1.3v1.3M11.033.683a.65.65 0 1 0 0 1.3v-1.3M14.01 4.96a.65.65 0 1 0 1.3 0h-1.3m-2.977-2.277a.65.65 0 1 0 0 1.3v-1.3m.977 2.277a.65.65 0 1 0 1.3 0h-1.3M6.667 10h-.65c0 .359.29.65.65.65zm.65-4a.65.65 0 0 0-1.3 0h1.3m1.373-.667a.65.65 0 0 0-1.3 0h1.3M7.39 6a.65.65 0 0 0 1.3 0h-1.3m1.3 4a.65.65 0 0 0-1.3 0h1.3m-1.3.667a.65.65 0 1 0 1.3 0h-1.3M6.667 8v-.65a.65.65 0 0 0-.65.65zM6.66 6v-.65a.65.65 0 0 0-.65.65zm0 2h-.65c0 .359.291.65.65.65zM14 8h-.65A5.35 5.35 0 0 1 8 13.35v1.3A6.65 6.65 0 0 0 14.65 8zm-6 6v-.65A5.35 5.35 0 0 1 2.65 8h-1.3A6.65 6.65 0 0 0 8 14.65zM2 8h.65A5.35 5.35 0 0 1 8 2.65v-1.3A6.65 6.65 0 0 0 1.35 8zm9.033-6.667v.65A2.976 2.976 0 0 1 14.01 4.96h1.3A4.276 4.276 0 0 0 11.033.683zm0 2v.65c.541 0 .977.436.977.977h1.3a2.275 2.275 0 0 0-2.277-2.277zM6.667 10h.65V6h-1.3v4zM8.04 5.333h-.65V6h1.3v-.667zm0 4.667h-.65v.667h1.3V10zM6.667 8v.65H9v-1.3H6.667zM9 8v.65c.19 0 .35.159.35.35h1.3c0-.915-.747-1.65-1.65-1.65zm1 1h-.65c0 .188-.162.35-.35.35v1.3c.906 0 1.65-.744 1.65-1.65zm-1 1v-.65H6.667v1.3H9zm-2.333 0h.65V8h-1.3v2zM6.66 6v.65h2.1v-1.3h-2.1zm2.1 0v.65c.19 0 .35.159.35.35h1.3c0-.915-.747-1.65-1.65-1.65zm1 1h-.65c0 .188-.162.35-.35.35v1.3c.906 0 1.65-.744 1.65-1.65zm-1 1v-.65h-2.1v1.3h2.1zm-2.1 0h.65V6h-1.3v2z'
|
|
40
40
|
/>
|
|
41
41
|
</Svg>,
|
|
42
42
|
);
|
|
@@ -39,7 +39,7 @@ export const Csv = createIcon(
|
|
|
39
39
|
strokeLinecap='round'
|
|
40
40
|
strokeLinejoin='round'
|
|
41
41
|
strokeWidth={1.3}
|
|
42
|
-
d='M10.333 14h1a2 2 0 0 0 2-2V5.673a2 2 0 0 0-.585-1.414l-1.673-1.673A2 2 0 0 0 9.66 2H4.667a2 2 0 0 0-2 2v4.667m10.666-3H11a1.333 1.333 0 0 1-1.333-1.334V2M8 6v3.
|
|
42
|
+
d='M10.333 14h1a2 2 0 0 0 2-2V5.673a2 2 0 0 0-.585-1.414l-1.673-1.673A2 2 0 0 0 9.66 2H4.667a2 2 0 0 0-2 2v4.667m10.666-3H11a1.333 1.333 0 0 1-1.333-1.334V2M8 6v3.333M6.667 8 8 9.333 9.333 8'
|
|
43
43
|
/>
|
|
44
44
|
<Path
|
|
45
45
|
fill='currentColor'
|
|
@@ -36,7 +36,7 @@ export const Discord = createIcon(
|
|
|
36
36
|
<Svg width={24} height={24} fill='currentColor' viewBox='0 0 16 16'>
|
|
37
37
|
<Path
|
|
38
38
|
fill='currentColor'
|
|
39
|
-
d='M12.628 4.115c-.876-.37-1.8-.633-2.75-.782q-.195.323-.353.662c-1.012-.
|
|
39
|
+
d='M12.628 4.115c-.876-.37-1.8-.633-2.75-.782q-.195.323-.353.662c-1.012-.14-2.041-.14-3.053 0a7 7 0 0 0-.352-.662c-.95.15-1.876.413-2.753.784-1.741 2.379-2.213 4.699-1.977 6.985 1.02.696 2.16 1.225 3.374 1.565q.41-.511.722-1.076a7.5 7.5 0 0 1-1.138-.502q.144-.097.28-.194A8.5 8.5 0 0 0 8 11.591a8.5 8.5 0 0 0 3.373-.696q.136.104.279.194a7.5 7.5 0 0 1-1.14.503q.312.565.722 1.075a11.4 11.4 0 0 0 3.376-1.564c.277-2.652-.473-4.95-1.982-6.988M5.785 9.696c-.657 0-1.2-.551-1.2-1.23 0-.677.524-1.233 1.198-1.233s1.213.556 1.202 1.234-.53 1.229-1.2 1.229m4.43 0c-.659 0-1.2-.551-1.2-1.23 0-.677.524-1.233 1.2-1.233s1.21.556 1.199 1.234c-.012.678-.529 1.229-1.2 1.229'
|
|
40
40
|
/>
|
|
41
41
|
</Svg>,
|
|
42
42
|
);
|