@sats-group/ui-lib 79.0.1 → 79.2.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.
- package/package.json +3 -3
- package/react/banner/banner.tsx +5 -5
- package/react/confirmation/confirmation.tsx +6 -1
- package/react/confirmation/confirmation.types.ts +1 -0
- package/react/icons/16/add.tsx +13 -0
- package/react/icons/16/error.tsx +23 -0
- package/react/icons/16/fistbump.tsx +13 -0
- package/react/icons/16/info.tsx +17 -0
- package/react/icons/16/send.tsx +13 -0
- package/react/icons/18/arrow-down.tsx +13 -0
- package/react/icons/18/confirm.tsx +19 -0
- package/react/icons/18/error.tsx +23 -0
- package/react/icons/18/info.tsx +17 -0
- package/react/icons/18/warning-sign.tsx +23 -0
- package/react/message-field/message-field.tsx +2 -2
- package/react/select/select.scss +2 -1
- package/react/select/select.tsx +1 -1
- package/react/style.scss +33 -0
- package/react/text-area/text-area.scss +1 -1
- package/react/text-input/text-input.tsx +2 -2
- package/react/toggle/toggle.tsx +4 -2
package/package.json
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sats-group/ui-lib",
|
|
3
|
-
"version": "79.0
|
|
3
|
+
"version": "79.2.0",
|
|
4
4
|
"description": "SATS web user interface library",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": "^18 || ^20",
|
|
7
7
|
"npm": "^8 || ^9 || ^10"
|
|
8
8
|
},
|
|
9
9
|
"scripts": {
|
|
10
|
-
"build": "run-s clean logos typecheck colour components",
|
|
10
|
+
"build": "run-s clean logos typecheck colour components style-imports",
|
|
11
11
|
"clean": "node rimraf.mjs",
|
|
12
12
|
"colour": "node codegen/colours.mjs",
|
|
13
13
|
"components": "node codegen/components.mjs",
|
|
14
|
+
"style-imports": "node codegen/style-imports.mjs",
|
|
14
15
|
"dev": "npm run dev --workspace=site",
|
|
15
16
|
"lint": "eslint",
|
|
16
17
|
"lint:ci": "eslint --max-warnings 0",
|
|
@@ -24,7 +25,6 @@
|
|
|
24
25
|
"author": "developer@sats.no",
|
|
25
26
|
"license": "UNLICENSED",
|
|
26
27
|
"peerDependencies": {
|
|
27
|
-
"@sats-group/icons": "^10.0.0",
|
|
28
28
|
"classnames": "^2.5.1",
|
|
29
29
|
"react": "^18.0.0 || ^19.0.0",
|
|
30
30
|
"react-dom": "^18.0.0 || ^19.0.0"
|
package/react/banner/banner.tsx
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import Close from '@sats-group/icons/18/close';
|
|
2
|
-
import Confirm from '@sats-group/icons/18/confirm';
|
|
3
|
-
import Error from '@sats-group/icons/18/error';
|
|
4
|
-
import Info from '@sats-group/icons/18/info';
|
|
5
|
-
import WarningSign from '@sats-group/icons/18/warning-sign';
|
|
6
1
|
import cn from 'classnames';
|
|
7
2
|
import React, { useState } from 'react';
|
|
8
3
|
|
|
9
4
|
import Text from '../text';
|
|
10
5
|
import VisuallyHidden from '../visually-hidden';
|
|
6
|
+
import Error from '../icons/18/error';
|
|
7
|
+
import Info from '../icons/18/info';
|
|
8
|
+
import Confirm from '../icons/18/confirm';
|
|
9
|
+
import WarningSign from '../icons/18/warning-sign';
|
|
10
|
+
import Close from '../icons/18/close';
|
|
11
11
|
|
|
12
12
|
import type { Banner as Props } from './banner.types';
|
|
13
13
|
|
|
@@ -20,6 +20,7 @@ const Confirmation: React.FC<React.PropsWithChildren<Props>> = ({
|
|
|
20
20
|
text,
|
|
21
21
|
title,
|
|
22
22
|
ariaLabel,
|
|
23
|
+
actionButtonType = 'primary',
|
|
23
24
|
}) => {
|
|
24
25
|
useEscape(onClose);
|
|
25
26
|
|
|
@@ -53,7 +54,11 @@ const Confirmation: React.FC<React.PropsWithChildren<Props>> = ({
|
|
|
53
54
|
{confirmationButton ? (
|
|
54
55
|
<Button
|
|
55
56
|
className="confirmation__button"
|
|
56
|
-
variant={
|
|
57
|
+
variant={
|
|
58
|
+
actionButtonType === 'primary'
|
|
59
|
+
? Button.variants.primary
|
|
60
|
+
: Button.variants.primaryDestructive
|
|
61
|
+
}
|
|
57
62
|
{...confirmationButton}
|
|
58
63
|
onClick={onConfirm}
|
|
59
64
|
/>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgAdd = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 16, height: 16, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M8 2.833a.5.5 0 0 1 .5.5V7.5h4.167a.5.5 0 0 1 0 1H8.5v4.167a.5.5 0 0 1-1 0V8.5H3.333a.5.5 0 0 1 0-1H7.5V3.333a.5.5 0 0 1 .5-.5',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
);
|
|
13
|
+
export default SvgAdd;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgError = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 16, height: 16, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M4.885.98A.5.5 0 0 1 5.24.833h5.522a.5.5 0 0 1 .354.147l3.905 3.905a.5.5 0 0 1 .147.354v5.522a.5.5 0 0 1-.147.354l-3.905 3.905a.5.5 0 0 1-.354.147H5.24a.5.5 0 0 1-.354-.147L.98 11.115a.5.5 0 0 1-.147-.354V5.24a.5.5 0 0 1 .147-.354zm.561.853L1.834 5.447v5.108l3.612 3.613h5.108l3.613-3.613V5.446l-3.613-3.612z',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
13
|
+
fill: 'currentColor',
|
|
14
|
+
fillRule: 'evenodd',
|
|
15
|
+
d: 'M8.007 4.5c.507.005.9.444.848.948l-.33 3.16a.528.528 0 0 1-1.05 0l-.328-3.16a.86.86 0 0 1 .86-.947',
|
|
16
|
+
clipRule: 'evenodd',
|
|
17
|
+
}),
|
|
18
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
19
|
+
fill: 'currentColor',
|
|
20
|
+
d: 'M8 11.637a.606.606 0 1 0 0-1.213.606.606 0 0 0 0 1.213',
|
|
21
|
+
}),
|
|
22
|
+
);
|
|
23
|
+
export default SvgError;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgFistbump = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 16, height: 16, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M2.29 2.934a2.7 2.7 0 0 1 1.892-.767h7.636c.708 0 1.389.274 1.893.767A2.6 2.6 0 0 1 14.5 4.8v6.933c0 .561-.228 1.096-.63 1.49a2.15 2.15 0 0 1-1.506.61H9.09a2.7 2.7 0 0 1-1.892-.767 2.6 2.6 0 0 1-.79-1.866v-.047a1.88 1.88 0 0 1-1.21-.654 2.15 2.15 0 0 1-1.563.668 2.16 2.16 0 0 1-1.506-.611 2.08 2.08 0 0 1-.63-1.49V4.8c0-.702.285-1.373.79-1.866m3.483 6.141v.258c0 .218.088.428.249.586a.88.88 0 0 0 .948.183.9.9 0 0 0 .281-.183.83.83 0 0 0 .249-.586v-2.32a.5.5 0 0 1 1 0v2.32c0 .218.088.428.249.586a.88.88 0 0 0 .615.248.88.88 0 0 0 .614-.248.82.82 0 0 0 .25-.586v-2.4a.5.5 0 1 1 1 0v2.134c0 .288.116.566.328.774.212.207.503.326.808.326s.595-.119.807-.326.329-.486.329-.774V4.8c0-.43-.174-.844-.489-1.151a1.7 1.7 0 0 0-1.193-.482H4.182c-.45 0-.879.174-1.193.482A1.6 1.6 0 0 0 2.5 4.8v4.267c0 .288.117.566.329.774.212.207.502.326.807.326s.596-.119.808-.326c.21-.206.327-.483.329-.769V6.933a.5.5 0 1 1 1 0v2.142m7.727 1.77a2.164 2.164 0 0 1-2.698-.346q-.059.07-.125.135a1.88 1.88 0 0 1-1.313.533A1.88 1.88 0 0 1 8 10.583a1.9 1.9 0 0 1-.59.419v.198c0 .43.173.844.488 1.151.314.308.743.482 1.193.482h3.273c.305 0 .595-.118.807-.326.212-.207.329-.486.329-.774z',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
);
|
|
13
|
+
export default SvgFistbump;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgInfo = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 16, height: 16, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M1.926 8a6.074 6.074 0 1 0 12.148 0A6.074 6.074 0 0 0 1.926 8M8 1a7 7 0 1 0 0 14A7 7 0 0 0 8 1',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
13
|
+
fill: 'currentColor',
|
|
14
|
+
d: 'M8.523 11.038v-3.61a.588.588 0 1 0-1.176 0v3.61a.588.588 0 0 0 1.176 0M7.935 5.854a.74.74 0 1 0 0-1.48.74.74 0 0 0 0 1.48',
|
|
15
|
+
}),
|
|
16
|
+
);
|
|
17
|
+
export default SvgInfo;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgSend = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 16, height: 16, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M13.834 2.107c.13.108.19.279.157.445L11.776 13.63a.46.46 0 0 1-.73.279L7.37 11.15l-1.784 2.13a.462.462 0 0 1-.816-.295V9.2L2.185 7.262a.462.462 0 0 1 .105-.798l11.077-4.431a.46.46 0 0 1 .467.074M5.692 9.892v1.822l.937-1.119zm.382-.868 6.763-5.41-1.823 9.116zm4.744-4.977L5.311 8.452 3.395 7.016z',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
);
|
|
13
|
+
export default SvgSend;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgArrowDown = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 18, height: 18, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M4.826 6.7a.6.6 0 0 1 .848 0L9 10.028 12.326 6.7a.6.6 0 1 1 .848.848l-3.75 3.75a.6.6 0 0 1-.848 0l-3.75-3.75a.6.6 0 0 1 0-.848',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
);
|
|
13
|
+
export default SvgArrowDown;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgConfirm = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 18, height: 18, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M12.712 6.682a.525.525 0 0 1 0 .743L7.886 12.25 5.288 9.652a.525.525 0 0 1 .742-.742l1.856 1.856 4.084-4.084a.525.525 0 0 1 .742 0',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
13
|
+
fill: 'currentColor',
|
|
14
|
+
fillRule: 'evenodd',
|
|
15
|
+
d: 'M2.926 9a6.074 6.074 0 1 0 12.148 0A6.074 6.074 0 0 0 2.926 9M9 2a7 7 0 1 0 0 14A7 7 0 0 0 9 2',
|
|
16
|
+
clipRule: 'evenodd',
|
|
17
|
+
}),
|
|
18
|
+
);
|
|
19
|
+
export default SvgConfirm;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgError = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 18, height: 18, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M5.496 1.102a.56.56 0 0 1 .398-.165h6.212c.15 0 .293.06.398.165l4.394 4.394a.56.56 0 0 1 .165.398v6.212c0 .15-.06.293-.165.398l-4.394 4.394a.56.56 0 0 1-.398.165H5.894a.56.56 0 0 1-.398-.165l-4.394-4.394a.56.56 0 0 1-.165-.398V5.894c0-.15.06-.293.165-.398zm.63.96L2.063 6.128v5.746l4.065 4.065h5.746l4.065-4.065V6.127l-4.065-4.064z',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
13
|
+
fill: 'currentColor',
|
|
14
|
+
fillRule: 'evenodd',
|
|
15
|
+
d: 'M9.008 5.063a.966.966 0 0 1 .953 1.066l-.37 3.556a.594.594 0 0 1-1.182 0L8.04 6.129a.966.966 0 0 1 .968-1.066',
|
|
16
|
+
clipRule: 'evenodd',
|
|
17
|
+
}),
|
|
18
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
19
|
+
fill: 'currentColor',
|
|
20
|
+
d: 'M9 13.09a.682.682 0 1 0 0-1.363.682.682 0 0 0 0 1.364',
|
|
21
|
+
}),
|
|
22
|
+
);
|
|
23
|
+
export default SvgError;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgInfo = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 18, height: 18, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
fillRule: 'evenodd',
|
|
9
|
+
d: 'M2.059 9A6.941 6.941 0 1 0 15.94 9 6.941 6.941 0 0 0 2.06 9M9 1a8 8 0 1 0 0 16A8 8 0 0 0 9 1',
|
|
10
|
+
clipRule: 'evenodd',
|
|
11
|
+
}),
|
|
12
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
13
|
+
fill: 'currentColor',
|
|
14
|
+
d: 'M9.598 12.472V8.347a.672.672 0 0 0-1.344 0v4.125a.672.672 0 0 0 1.344 0M8.926 6.547a.846.846 0 1 0 0-1.691.846.846 0 0 0 0 1.691',
|
|
15
|
+
}),
|
|
16
|
+
);
|
|
17
|
+
export default SvgInfo;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
const SvgWarningSign = () =>
|
|
3
|
+
/* @__PURE__ */ React.createElement(
|
|
4
|
+
'svg',
|
|
5
|
+
{ width: 18, height: 18, fill: 'none' },
|
|
6
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
7
|
+
fill: 'currentColor',
|
|
8
|
+
d: 'M9.002 13.896c.377 0 .682-.32.682-.714 0-.395-.305-.715-.682-.715s-.682.32-.682.715.305.714.682.714',
|
|
9
|
+
}),
|
|
10
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
11
|
+
fill: 'currentColor',
|
|
12
|
+
fillRule: 'evenodd',
|
|
13
|
+
d: 'M9.247 6.565a.75.75 0 0 1 .74.828l-.394 3.792a.594.594 0 0 1-1.182 0l-.394-3.796a.75.75 0 0 1 .752-.827z',
|
|
14
|
+
clipRule: 'evenodd',
|
|
15
|
+
}),
|
|
16
|
+
/* @__PURE__ */ React.createElement('path', {
|
|
17
|
+
fill: 'currentColor',
|
|
18
|
+
fillRule: 'evenodd',
|
|
19
|
+
d: 'M15.513 17.041c.263.002.522-.068.75-.202.23-.134.422-.328.559-.563a1.65 1.65 0 0 0 .046-1.568L10.355 1.812a1.6 1.6 0 0 0-.564-.623 1.48 1.48 0 0 0-1.578 0c-.239.15-.434.366-.564.623L1.136 14.708a1.65 1.65 0 0 0 .045 1.567c.137.235.328.429.557.563s.487.204.75.203zM2.141 15.213a.53.53 0 0 0 .014.498.43.43 0 0 0 .152.157.34.34 0 0 0 .175.048h13.039a.34.34 0 0 0 .175-.048.43.43 0 0 0 .153-.157.52.52 0 0 0 .014-.497v-.001L9.35 2.319a.45.45 0 0 0-.159-.179.35.35 0 0 0-.189-.056.35.35 0 0 0-.19.056.45.45 0 0 0-.158.18z',
|
|
20
|
+
clipRule: 'evenodd',
|
|
21
|
+
}),
|
|
22
|
+
);
|
|
23
|
+
export default SvgWarningSign;
|
|
@@ -3,8 +3,8 @@ import React, { useState } from 'react';
|
|
|
3
3
|
import { MessageField as Props, variants, sizes } from './message-field.types';
|
|
4
4
|
import Button from '../button';
|
|
5
5
|
import TextArea from '../text-area';
|
|
6
|
-
import
|
|
7
|
-
import
|
|
6
|
+
import Add from '../icons/16/add';
|
|
7
|
+
import Send from '../icons/16/send';
|
|
8
8
|
import classNames from 'classnames';
|
|
9
9
|
|
|
10
10
|
const MessageField: React.FunctionComponent<Props> & {
|
package/react/select/select.scss
CHANGED
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
&--label-position-stacked {
|
|
17
17
|
flex-direction: column;
|
|
18
|
+
gap: spacing.$xxs;
|
|
18
19
|
}
|
|
19
20
|
|
|
20
21
|
// NOTE: Specificity hack
|
|
@@ -54,7 +55,7 @@
|
|
|
54
55
|
position: relative;
|
|
55
56
|
width: 100%;
|
|
56
57
|
border-radius: corner-radius.$s;
|
|
57
|
-
padding-right: spacing
|
|
58
|
+
padding-right: 36px; // NOTE: custom spacing to offset chevron overlap
|
|
58
59
|
|
|
59
60
|
&--variant-small {
|
|
60
61
|
padding-top: spacing.$xs;
|
package/react/select/select.tsx
CHANGED
|
@@ -5,7 +5,7 @@ import useInputValidation from '../use-input-validation';
|
|
|
5
5
|
|
|
6
6
|
import Option from '../select-option/select-option';
|
|
7
7
|
import Text from '../text';
|
|
8
|
-
import SvgArrowDown from '
|
|
8
|
+
import SvgArrowDown from '../icons/18/arrow-down';
|
|
9
9
|
|
|
10
10
|
import { labelPositions, Select as Props, variants } from './select.types';
|
|
11
11
|
|
package/react/style.scss
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
@use "./badge/badge.scss";
|
|
2
|
+
@use "./banner/banner.scss";
|
|
3
|
+
@use "./bomb/bomb.scss";
|
|
4
|
+
@use "./checkbox/checkbox.scss";
|
|
5
|
+
@use "./chip/chip.scss";
|
|
6
|
+
@use "./chip-selected/chip-selected.scss";
|
|
7
|
+
@use "./confirmation/confirmation.scss";
|
|
8
|
+
@use "./context-menu/context-menu.scss";
|
|
9
|
+
@use "./cropped-image/cropped-image.scss";
|
|
10
|
+
@use "./dropdown-list/dropdown-list.scss";
|
|
11
|
+
@use "./expander/expander.scss";
|
|
12
|
+
@use "./filter/filter.scss";
|
|
13
|
+
@use "./filter-wrapper/filter-wrapper.scss";
|
|
14
|
+
@use "./flag/flag.scss";
|
|
15
|
+
@use "./form-content/form-content.scss";
|
|
16
|
+
@use "./link/link.scss";
|
|
17
|
+
@use "./link-card/link-card.scss";
|
|
18
|
+
@use "./message/message.scss";
|
|
19
|
+
@use "./message-field/message-field.scss";
|
|
20
|
+
@use "./modal/modal.scss";
|
|
21
|
+
@use "./progress-bar/progress-bar.scss";
|
|
22
|
+
@use "./radio/radio.scss";
|
|
23
|
+
@use "./scale-bar/scale-bar.scss";
|
|
24
|
+
@use "./search/search.scss";
|
|
25
|
+
@use "./select/select.scss";
|
|
26
|
+
@use "./tag/tag.scss";
|
|
27
|
+
@use "./text/text.scss";
|
|
28
|
+
@use "./text-area/text-area.scss";
|
|
29
|
+
@use "./text-input/text-input.scss";
|
|
30
|
+
@use "./toggle/toggle.scss";
|
|
31
|
+
@use "./toolbox/toolbox.scss";
|
|
32
|
+
@use "./visually-button/visually-button.scss";
|
|
33
|
+
@use "./visually-hidden/visually-hidden.scss";
|
|
@@ -3,11 +3,11 @@ import * as React from 'react';
|
|
|
3
3
|
|
|
4
4
|
import Text from '../text';
|
|
5
5
|
import useInputValidation from '../use-input-validation';
|
|
6
|
+
import SvgInfo from '../icons/16/info';
|
|
7
|
+
import SvgError from '../icons/16/error';
|
|
6
8
|
|
|
7
9
|
import { themes, variants, TextInput as Props } from './text-input.types';
|
|
8
10
|
import { useEffect } from 'react';
|
|
9
|
-
import SvgError from '@sats-group/icons/16/error';
|
|
10
|
-
import SvgInfo from '@sats-group/icons/16/info';
|
|
11
11
|
|
|
12
12
|
const RefTextInput = React.forwardRef<HTMLInputElement, Props>(
|
|
13
13
|
(
|
package/react/toggle/toggle.tsx
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import cn from 'classnames';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
|
|
4
|
+
import Text from '../text';
|
|
4
5
|
import useInputValidation from '../use-input-validation';
|
|
6
|
+
|
|
5
7
|
import { Toggle as Props } from './toggle.types';
|
|
6
8
|
|
|
7
9
|
const Toggle = React.forwardRef<
|
|
@@ -38,7 +40,7 @@ const Toggle = React.forwardRef<
|
|
|
38
40
|
>
|
|
39
41
|
{isLabelVisible && labelPosition === 'left' && (
|
|
40
42
|
<div className="toggle__label">
|
|
41
|
-
{label}
|
|
43
|
+
<Text>{label}</Text>
|
|
42
44
|
{children}
|
|
43
45
|
</div>
|
|
44
46
|
)}
|
|
@@ -70,7 +72,7 @@ const Toggle = React.forwardRef<
|
|
|
70
72
|
|
|
71
73
|
{isLabelVisible && labelPosition === 'right' && (
|
|
72
74
|
<div className="toggle__label">
|
|
73
|
-
{label}
|
|
75
|
+
<Text>{label}</Text>
|
|
74
76
|
{children}
|
|
75
77
|
</div>
|
|
76
78
|
)}
|