@digigov/react-icons 1.0.0-a131264d → 1.0.0-b0737a96
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/AccessibilityIcon/config.js +7 -19
- package/AccessibilityIcon/index.js +6 -21
- package/AccessibilityIcon/index.test.js +21 -27
- package/AccessibilityIcon/package.json +6 -0
- package/ArrowIcon/config.js +8 -20
- package/ArrowIcon/index.js +6 -21
- package/ArrowIcon/index.test.js +11 -17
- package/ArrowIcon/package.json +6 -0
- package/BurgerIcon/config.js +9 -22
- package/BurgerIcon/index.js +6 -21
- package/BurgerIcon/index.test.js +15 -21
- package/BurgerIcon/package.json +6 -0
- package/CaretIcon/config.js +8 -20
- package/CaretIcon/index.js +6 -21
- package/CaretIcon/index.test.js +11 -17
- package/CaretIcon/package.json +6 -0
- package/CheckIcon/config.js +5 -17
- package/CheckIcon/index.js +6 -21
- package/CheckIcon/index.test.js +19 -25
- package/CheckIcon/package.json +6 -0
- package/ChevronIcon/config.js +8 -20
- package/ChevronIcon/index.js +6 -21
- package/ChevronIcon/index.test.js +11 -17
- package/ChevronIcon/package.json +6 -0
- package/CloseIcon/config.js +5 -17
- package/CloseIcon/index.js +6 -21
- package/CloseIcon/index.test.js +5 -11
- package/CloseIcon/package.json +6 -0
- package/GlobeIcon/config.js +5 -17
- package/GlobeIcon/index.js +6 -21
- package/GlobeIcon/index.test.js +11 -17
- package/GlobeIcon/package.json +6 -0
- package/Icon/index.js +15 -39
- package/Icon/index.test.js +23 -29
- package/Icon/package.json +6 -0
- package/MoreVertIcon/config.js +7 -19
- package/MoreVertIcon/index.js +6 -21
- package/MoreVertIcon/index.test.js +21 -27
- package/MoreVertIcon/package.json +6 -0
- package/SearchIcon/config.js +5 -17
- package/SearchIcon/index.js +6 -21
- package/SearchIcon/index.test.js +5 -11
- package/SearchIcon/package.json +6 -0
- package/UncheckIcon/config.js +5 -17
- package/UncheckIcon/index.js +6 -21
- package/UncheckIcon/index.test.js +21 -27
- package/UncheckIcon/package.json +6 -0
- package/cjs/AccessibilityIcon/config.js +31 -0
- package/cjs/AccessibilityIcon/index.js +24 -0
- package/cjs/AccessibilityIcon/index.test.js +81 -0
- package/cjs/ArrowIcon/config.js +39 -0
- package/cjs/ArrowIcon/index.js +24 -0
- package/cjs/ArrowIcon/index.test.js +39 -0
- package/cjs/BurgerIcon/config.js +45 -0
- package/cjs/BurgerIcon/index.js +24 -0
- package/cjs/BurgerIcon/index.test.js +56 -0
- package/cjs/CaretIcon/config.js +39 -0
- package/cjs/CaretIcon/index.js +24 -0
- package/cjs/CaretIcon/index.test.js +39 -0
- package/cjs/CheckIcon/config.js +23 -0
- package/cjs/CheckIcon/index.js +24 -0
- package/cjs/CheckIcon/index.test.js +73 -0
- package/cjs/ChevronIcon/config.js +39 -0
- package/cjs/ChevronIcon/index.js +24 -0
- package/cjs/ChevronIcon/index.test.js +39 -0
- package/cjs/CloseIcon/config.js +23 -0
- package/cjs/CloseIcon/index.js +24 -0
- package/cjs/CloseIcon/index.test.js +15 -0
- package/{es → cjs}/GlobeIcon/config.js +17 -5
- package/cjs/GlobeIcon/index.js +24 -0
- package/cjs/GlobeIcon/index.test.js +39 -0
- package/cjs/Icon/index.js +58 -0
- package/cjs/Icon/index.test.js +88 -0
- package/cjs/MoreVertIcon/config.js +37 -0
- package/cjs/MoreVertIcon/index.js +24 -0
- package/cjs/MoreVertIcon/index.test.js +81 -0
- package/cjs/SearchIcon/config.js +23 -0
- package/cjs/SearchIcon/index.js +24 -0
- package/cjs/SearchIcon/index.test.js +15 -0
- package/cjs/UncheckIcon/config.js +23 -0
- package/cjs/UncheckIcon/index.js +24 -0
- package/cjs/UncheckIcon/index.test.js +81 -0
- package/cjs/icons.js +148 -0
- package/cjs/index.js +148 -0
- package/cjs/registry.js +73 -0
- package/icons.js +12 -148
- package/index.js +11 -148
- package/package.json +4 -4
- package/registry.d.ts +1 -1
- package/registry.js +16 -43
- package/AccessibilityIcon/config.mjs +0 -19
- package/AccessibilityIcon/index.mjs +0 -9
- package/AccessibilityIcon/index.test.mjs +0 -75
- package/ArrowIcon/config.mjs +0 -27
- package/ArrowIcon/index.mjs +0 -9
- package/ArrowIcon/index.test.mjs +0 -33
- package/BurgerIcon/config.mjs +0 -32
- package/BurgerIcon/index.mjs +0 -9
- package/BurgerIcon/index.test.mjs +0 -50
- package/CaretIcon/config.mjs +0 -27
- package/CaretIcon/index.mjs +0 -9
- package/CaretIcon/index.test.mjs +0 -33
- package/CheckIcon/config.mjs +0 -11
- package/CheckIcon/index.mjs +0 -9
- package/CheckIcon/index.test.mjs +0 -67
- package/ChevronIcon/config.mjs +0 -27
- package/ChevronIcon/index.mjs +0 -9
- package/ChevronIcon/index.test.mjs +0 -33
- package/CloseIcon/config.mjs +0 -11
- package/CloseIcon/index.mjs +0 -9
- package/CloseIcon/index.test.mjs +0 -9
- package/GlobeIcon/config.mjs +0 -11
- package/GlobeIcon/index.mjs +0 -9
- package/GlobeIcon/index.test.mjs +0 -33
- package/Icon/index.mjs +0 -34
- package/Icon/index.test.mjs +0 -82
- package/MoreVertIcon/config.mjs +0 -25
- package/MoreVertIcon/index.mjs +0 -9
- package/MoreVertIcon/index.test.mjs +0 -75
- package/SearchIcon/config.mjs +0 -11
- package/SearchIcon/index.mjs +0 -9
- package/SearchIcon/index.test.mjs +0 -9
- package/UncheckIcon/config.mjs +0 -11
- package/UncheckIcon/index.mjs +0 -9
- package/UncheckIcon/index.test.mjs +0 -75
- package/es/AccessibilityIcon/config.js +0 -19
- package/es/AccessibilityIcon/index.js +0 -9
- package/es/AccessibilityIcon/index.test.js +0 -75
- package/es/ArrowIcon/config.js +0 -27
- package/es/ArrowIcon/index.js +0 -9
- package/es/ArrowIcon/index.test.js +0 -33
- package/es/BurgerIcon/config.js +0 -32
- package/es/BurgerIcon/index.js +0 -9
- package/es/BurgerIcon/index.test.js +0 -50
- package/es/CaretIcon/config.js +0 -27
- package/es/CaretIcon/index.js +0 -9
- package/es/CaretIcon/index.test.js +0 -33
- package/es/CheckIcon/config.js +0 -11
- package/es/CheckIcon/index.js +0 -9
- package/es/CheckIcon/index.test.js +0 -67
- package/es/ChevronIcon/config.js +0 -27
- package/es/ChevronIcon/index.js +0 -9
- package/es/ChevronIcon/index.test.js +0 -33
- package/es/CloseIcon/config.js +0 -11
- package/es/CloseIcon/index.js +0 -9
- package/es/CloseIcon/index.test.js +0 -9
- package/es/GlobeIcon/index.js +0 -9
- package/es/GlobeIcon/index.test.js +0 -33
- package/es/Icon/index.js +0 -34
- package/es/Icon/index.test.js +0 -82
- package/es/MoreVertIcon/config.js +0 -25
- package/es/MoreVertIcon/index.js +0 -9
- package/es/MoreVertIcon/index.test.js +0 -75
- package/es/SearchIcon/config.js +0 -11
- package/es/SearchIcon/index.js +0 -9
- package/es/SearchIcon/index.test.js +0 -9
- package/es/UncheckIcon/config.js +0 -11
- package/es/UncheckIcon/index.js +0 -9
- package/es/UncheckIcon/index.test.js +0 -75
- package/es/icons.js +0 -12
- package/es/index.js +0 -11
- package/es/registry.js +0 -46
- package/icons.mjs +0 -12
- package/index.mjs +0 -11
- package/registry.mjs +0 -46
- /package/{es → cjs}/AccessibilityIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/ArrowIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/BurgerIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/CaretIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/CheckIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/CloseIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/GlobeIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/Icon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/MoreVertIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/SearchIcon/__snapshots__/index.test.tsx.snap +0 -0
- /package/{es → cjs}/UncheckIcon/__snapshots__/index.test.tsx.snap +0 -0
package/es/CaretIcon/config.js
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref2 = /*#__PURE__*/React.createElement("path", {
|
|
4
|
-
d: "M18,22V2L6,12L18,22z"
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
var _ref3 = /*#__PURE__*/React.createElement("path", {
|
|
8
|
-
d: "M6,2v20l12-10L6,2z"
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref4 = /*#__PURE__*/React.createElement("path", {
|
|
12
|
-
d: "M2,18h20L12,6L2,18z"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
var _ref5 = /*#__PURE__*/React.createElement("path", {
|
|
16
|
-
d: "M22,6H2l10,12L22,6z"
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
export var caret = function caret(_ref) {
|
|
20
|
-
var _ref$direction = _ref.direction,
|
|
21
|
-
direction = _ref$direction === void 0 ? 'left' : _ref$direction;
|
|
22
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, direction === 'left' && _ref2, direction === 'right' && _ref3, direction === 'up' && _ref4, direction === 'down' && _ref5);
|
|
23
|
-
}; // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
24
|
-
// @ts-ignore
|
|
25
|
-
|
|
26
|
-
caret.props = ['direction'];
|
|
27
|
-
export default caret;
|
package/es/CaretIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var CaretIcon = function CaretIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "caret"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default CaretIcon;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import CaretIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(CaretIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the CaretIcon with no props, direction prop is left by default', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(CaretIcon, {
|
|
12
|
-
direction: "right"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the CaretIcon with direction right prop', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(CaretIcon, {
|
|
20
|
-
direction: "up"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the CaretIcon with direction up prop', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(CaretIcon, {
|
|
28
|
-
direction: "down"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the CaretIcon with direction down prop', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
package/es/CheckIcon/config.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("polygon", {
|
|
4
|
-
points: "9.49 14.94 4.16 9.67 1.84 12.01 9.5 19.6 22.16 7.05 19.84 4.7 9.5 14.94"
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
export function check() {
|
|
8
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref);
|
|
9
|
-
}
|
|
10
|
-
check.props = [];
|
|
11
|
-
export default check;
|
package/es/CheckIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var CheckIcon = function CheckIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "check"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default CheckIcon;
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import CheckIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(CheckIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the CheckIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
12
|
-
size: "md"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the CheckIcon with prop size=m', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
20
|
-
size: "xl"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the CheckIcon with prop size=xl', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
28
|
-
variant: "light"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the CheckIcon with prop variant=light', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
var _ref5 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
36
|
-
variant: "success"
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
it('renders the CheckIcon with prop variant=success', function () {
|
|
40
|
-
expect(mount(_ref5)).toMatchSnapshot();
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
var _ref6 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
44
|
-
variant: "warning"
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it('renders the CheckIcon with prop variant=warning', function () {
|
|
48
|
-
expect(mount(_ref6)).toMatchSnapshot();
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
var _ref7 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
52
|
-
variant: "warning",
|
|
53
|
-
size: "sm"
|
|
54
|
-
});
|
|
55
|
-
|
|
56
|
-
it('renders the CheckIcon with prop variant=warning and size=s', function () {
|
|
57
|
-
expect(mount(_ref7)).toMatchSnapshot();
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
var _ref8 = /*#__PURE__*/React.createElement(CheckIcon, {
|
|
61
|
-
variant: "warning",
|
|
62
|
-
size: "xl"
|
|
63
|
-
});
|
|
64
|
-
|
|
65
|
-
it('renders the CheckIcon with prop variant=error and size= xl', function () {
|
|
66
|
-
expect(mount(_ref8)).toMatchSnapshot();
|
|
67
|
-
});
|
package/es/ChevronIcon/config.js
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref2 = /*#__PURE__*/React.createElement("path", {
|
|
4
|
-
d: "M14.8,22l2.4-2.3L9.6,12l7.6-7.6L14.8,2l-10,10L14.8,22z"
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
var _ref3 = /*#__PURE__*/React.createElement("path", {
|
|
8
|
-
d: "M8.5,2L6.1,4.3l7.6,7.7l-7.6,7.6L8.5,22l10-10L8.5,2z"
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref4 = /*#__PURE__*/React.createElement("path", {
|
|
12
|
-
d: "M2,15.8l2.3,2.4l7.7-7.6l7.6,7.6l2.4-2.4l-10-10L2,15.8z"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
var _ref5 = /*#__PURE__*/React.createElement("path", {
|
|
16
|
-
d: "M22,8.2l-2.3-2.4L12,13.4L4.4,5.8L2,8.2l10,10L22,8.2z"
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
export var chevron = function chevron(_ref) {
|
|
20
|
-
var _ref$direction = _ref.direction,
|
|
21
|
-
direction = _ref$direction === void 0 ? 'right' : _ref$direction;
|
|
22
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, direction === 'left' && _ref2, direction === 'right' && _ref3, direction === 'up' && _ref4, direction === 'down' && _ref5);
|
|
23
|
-
}; // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
24
|
-
// @ts-ignore
|
|
25
|
-
|
|
26
|
-
chevron.props = ['direction'];
|
|
27
|
-
export default chevron;
|
package/es/ChevronIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var ChevronIcon = function ChevronIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "chevron"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default ChevronIcon;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import ChevronIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(ChevronIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the ChevronIcon with no props, direction prop is right by default', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(ChevronIcon, {
|
|
12
|
-
direction: "left"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the ChevronIcon with direction left prop', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(ChevronIcon, {
|
|
20
|
-
direction: "up"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the ChevronIcon with direction up prop', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(ChevronIcon, {
|
|
28
|
-
direction: "down"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the ChevronIcon with direction down prop', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
package/es/CloseIcon/config.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("polygon", {
|
|
4
|
-
points: "14.4,11.8 22,4.2 19.7,1.8 12,9.4 4.4,1.8 2,4.2 9.7,11.9 2.1,19.5 4.4,21.9 12.1,14.3 19.7,21.9 22.1,19.5 "
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
export function close() {
|
|
8
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref);
|
|
9
|
-
}
|
|
10
|
-
close.props = [];
|
|
11
|
-
export default close;
|
package/es/CloseIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var CloseIcon = function CloseIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "close"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default CloseIcon;
|
package/es/GlobeIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var GlobeIcon = function GlobeIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "globe"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default GlobeIcon;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import GlobeIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(GlobeIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the GlobeIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(GlobeIcon, {
|
|
12
|
-
variant: "dark"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the GlobeIcon with prop variant=dark', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(GlobeIcon, {
|
|
20
|
-
variant: "light"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the GlobeIcon prop variant= "light"', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(GlobeIcon, {
|
|
28
|
-
variant: "error"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the GlobeIcon prop variant= "error"', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
package/es/Icon/index.js
DELETED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
3
|
-
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
-
var _excluded = ["icon", "className"];
|
|
5
|
-
import React from 'react';
|
|
6
|
-
import clsx from 'clsx';
|
|
7
|
-
import SvgIcon from '@digigov/react-core/SvgIcon';
|
|
8
|
-
import * as icons from "../icons";
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Icon is used whenever we need a GOV.GR icon.
|
|
12
|
-
* Choose the icon from the list in icon prop.
|
|
13
|
-
*/
|
|
14
|
-
export var Icon = /*#__PURE__*/React.forwardRef(function Icon(_ref, ref) {
|
|
15
|
-
var _ref$icon = _ref.icon,
|
|
16
|
-
icon = _ref$icon === void 0 ? 'chevron' : _ref$icon,
|
|
17
|
-
className = _ref.className,
|
|
18
|
-
props = _objectWithoutProperties(_ref, _excluded);
|
|
19
|
-
|
|
20
|
-
var IconComponent = icons[icon]; // eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
21
|
-
// @ts-ignore
|
|
22
|
-
|
|
23
|
-
var iconProps = IconComponent === null || IconComponent === void 0 ? void 0 : IconComponent.props.reduce(function (compProps, propName) {
|
|
24
|
-
var value = props[propName];
|
|
25
|
-
delete props[propName];
|
|
26
|
-
return _extends({}, compProps, _defineProperty({}, propName, value));
|
|
27
|
-
}, {});
|
|
28
|
-
return /*#__PURE__*/React.createElement(SvgIcon, _extends({
|
|
29
|
-
ref: ref
|
|
30
|
-
}, props, {
|
|
31
|
-
className: clsx(className, true && "govgr-svg-icon--".concat(icon))
|
|
32
|
-
}), /*#__PURE__*/React.createElement(IconComponent, iconProps));
|
|
33
|
-
});
|
|
34
|
-
export default Icon;
|
package/es/Icon/index.test.js
DELETED
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import Icon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(Icon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the Icon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(Icon, {
|
|
12
|
-
direction: "up"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the Icon with prop icon=arrow and direction=up', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(Icon, {
|
|
20
|
-
icon: "burger"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the Icon with prop prop icon=burger', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(Icon, {
|
|
28
|
-
icon: "caret"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the Icon prop icon= "caret"', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
var _ref5 = /*#__PURE__*/React.createElement(Icon, {
|
|
36
|
-
icon: "caret",
|
|
37
|
-
direction: "left"
|
|
38
|
-
});
|
|
39
|
-
|
|
40
|
-
it('renders the Icon prop icon= "caret" and direction=left', function () {
|
|
41
|
-
expect(mount(_ref5)).toMatchSnapshot();
|
|
42
|
-
});
|
|
43
|
-
|
|
44
|
-
var _ref6 = /*#__PURE__*/React.createElement(Icon, {
|
|
45
|
-
icon: "check"
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
it('renders the Icon prop icon= "check"', function () {
|
|
49
|
-
expect(mount(_ref6)).toMatchSnapshot();
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
var _ref7 = /*#__PURE__*/React.createElement(Icon, {
|
|
53
|
-
icon: "close"
|
|
54
|
-
});
|
|
55
|
-
|
|
56
|
-
it('renders the Icon prop icon= "close"', function () {
|
|
57
|
-
expect(mount(_ref7)).toMatchSnapshot();
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
var _ref8 = /*#__PURE__*/React.createElement(Icon, {
|
|
61
|
-
icon: "globe"
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
it('renders the Icon with prop prop icon=globe', function () {
|
|
65
|
-
expect(mount(_ref8)).toMatchSnapshot();
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
var _ref9 = /*#__PURE__*/React.createElement(Icon, {
|
|
69
|
-
icon: "moreVert"
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
it('renders the Icon props icon= "moreVert"', function () {
|
|
73
|
-
expect(mount(_ref9)).toMatchSnapshot();
|
|
74
|
-
});
|
|
75
|
-
|
|
76
|
-
var _ref10 = /*#__PURE__*/React.createElement(Icon, {
|
|
77
|
-
icon: "uncheck"
|
|
78
|
-
});
|
|
79
|
-
|
|
80
|
-
it('renders the Icon prop icon= "uncheck"', function () {
|
|
81
|
-
expect(mount(_ref10)).toMatchSnapshot();
|
|
82
|
-
});
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("circle", {
|
|
4
|
-
cx: "12",
|
|
5
|
-
cy: "5",
|
|
6
|
-
r: "2"
|
|
7
|
-
});
|
|
8
|
-
|
|
9
|
-
var _ref2 = /*#__PURE__*/React.createElement("circle", {
|
|
10
|
-
cx: "12",
|
|
11
|
-
cy: "12",
|
|
12
|
-
r: "2"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
var _ref3 = /*#__PURE__*/React.createElement("circle", {
|
|
16
|
-
cx: "12",
|
|
17
|
-
cy: "19",
|
|
18
|
-
r: "2"
|
|
19
|
-
});
|
|
20
|
-
|
|
21
|
-
export function moreVert() {
|
|
22
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref, _ref2, _ref3);
|
|
23
|
-
}
|
|
24
|
-
moreVert.props = [];
|
|
25
|
-
export default moreVert;
|
package/es/MoreVertIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var MoreVertIcon = function MoreVertIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "moreVert"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default MoreVertIcon;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import MoreVertIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(MoreVertIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the MoreVertIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
12
|
-
size: "sm"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the MoreVertIcon with prop size=s', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
20
|
-
size: "lg"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the MoreVertIcon with prop size=l', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
28
|
-
variant: "dark"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the MoreVertIcon with prop variant=dark', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
var _ref5 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
36
|
-
variant: "primary"
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
it('renders the MoreVertIcon with prop variant=primary', function () {
|
|
40
|
-
expect(mount(_ref5)).toMatchSnapshot();
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
var _ref6 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
44
|
-
variant: "success"
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it('renders the MoreVertIcon with prop variant=success', function () {
|
|
48
|
-
expect(mount(_ref6)).toMatchSnapshot();
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
var _ref7 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
52
|
-
variant: "focus"
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
it('renders the MoreVertIcon with prop variant=focus', function () {
|
|
56
|
-
expect(mount(_ref7)).toMatchSnapshot();
|
|
57
|
-
});
|
|
58
|
-
|
|
59
|
-
var _ref8 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
60
|
-
variant: "warning",
|
|
61
|
-
size: "sm"
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
it('renders the MoreVertIcon with prop variant=warning and size=s', function () {
|
|
65
|
-
expect(mount(_ref8)).toMatchSnapshot();
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
var _ref9 = /*#__PURE__*/React.createElement(MoreVertIcon, {
|
|
69
|
-
variant: "warning",
|
|
70
|
-
size: "xl"
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
it('renders the MoreVertIcon with prop variant=error and size= xl', function () {
|
|
74
|
-
expect(mount(_ref9)).toMatchSnapshot();
|
|
75
|
-
});
|
package/es/SearchIcon/config.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("path", {
|
|
4
|
-
d: "M22,19.9l-5.4-5.4c0.9-1.3,1.4-2.8,1.4-4.5c0-4.4-3.6-8-8-8s-8,3.6-8,8s3.6,8,8,8c1.7,0,3.2-0.5,4.5-1.4l5.4,5.4L22,19.9z M10,15c-2.8,0-5-2.2-5-5s2.2-5,5-5s5,2.2,5,5S12.8,15,10,15z"
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
export function search() {
|
|
8
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref);
|
|
9
|
-
}
|
|
10
|
-
search.props = [];
|
|
11
|
-
export default search;
|
package/es/SearchIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var SearchIcon = function SearchIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "search"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default SearchIcon;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import SearchIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(SearchIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the SearchIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
package/es/UncheckIcon/config.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("polygon", {
|
|
4
|
-
points: "20.59 5.74 18.26 3.41 12 9.67 5.742 3.41 3.41 5.74 9.67 12 3.41 18.26 5.74 20.6 12 14.33 18.26 20.59 20.59 18.26 14.33 12 20.59 5.74"
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
export function uncheck() {
|
|
8
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref);
|
|
9
|
-
}
|
|
10
|
-
uncheck.props = [];
|
|
11
|
-
export default uncheck;
|
package/es/UncheckIcon/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from "../Icon";
|
|
4
|
-
export var UncheckIcon = function UncheckIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "uncheck"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default UncheckIcon;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import UncheckIcon from "./";
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(UncheckIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the UncheckIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
12
|
-
size: "md"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the UncheckIcon with prop size=m', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
20
|
-
size: "lg"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the UncheckIcon with prop size=l', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
28
|
-
variant: "dark"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the UncheckIcon with prop variant=dark', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
var _ref5 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
36
|
-
variant: "light"
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
it('renders the UncheckIcon with prop variant=light', function () {
|
|
40
|
-
expect(mount(_ref5)).toMatchSnapshot();
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
var _ref6 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
44
|
-
variant: "gray"
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it('renders the UncheckIcon with prop variant=gray', function () {
|
|
48
|
-
expect(mount(_ref6)).toMatchSnapshot();
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
var _ref7 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
52
|
-
variant: "primary"
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
it('renders the UncheckIcon with prop variant=primary', function () {
|
|
56
|
-
expect(mount(_ref7)).toMatchSnapshot();
|
|
57
|
-
});
|
|
58
|
-
|
|
59
|
-
var _ref8 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
60
|
-
variant: "warning",
|
|
61
|
-
size: "sm"
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
it('renders the UncheckIcon with prop variant=warning and size=s', function () {
|
|
65
|
-
expect(mount(_ref8)).toMatchSnapshot();
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
var _ref9 = /*#__PURE__*/React.createElement(UncheckIcon, {
|
|
69
|
-
variant: "warning",
|
|
70
|
-
size: "xl"
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
it('renders the UncheckIcon with prop variant=error and size= xl', function () {
|
|
74
|
-
expect(mount(_ref9)).toMatchSnapshot();
|
|
75
|
-
});
|