@digigov/react-icons 1.0.0-88820b1e → 1.0.0-8b33e4c8
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.d.ts +1 -1
- package/AccessibilityIcon/index.js +6 -21
- package/AccessibilityIcon/index.test.js +21 -27
- package/AccessibilityIcon/package.json +6 -0
- package/ArrowIcon/config.d.ts +1 -1
- package/ArrowIcon/config.js +13 -25
- package/ArrowIcon/index.d.ts +1 -1
- 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.d.ts +1 -1
- 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.d.ts +1 -1
- 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.d.ts +1 -1
- package/CheckIcon/index.js +6 -21
- package/CheckIcon/index.test.js +19 -25
- package/CheckIcon/package.json +6 -0
- package/ChevronIcon/config.d.ts +14 -0
- package/{es/ArrowIcon → ChevronIcon}/config.js +3 -3
- package/ChevronIcon/index.d.ts +4 -0
- package/{es/ArrowIcon → ChevronIcon}/index.js +4 -4
- package/ChevronIcon/index.test.d.ts +1 -0
- package/ChevronIcon/index.test.js +33 -0
- package/ChevronIcon/package.json +6 -0
- package/CloseIcon/config.js +5 -17
- package/CloseIcon/index.d.ts +1 -1
- 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.d.ts +1 -1
- package/GlobeIcon/index.js +6 -21
- package/GlobeIcon/index.test.js +11 -17
- package/GlobeIcon/package.json +6 -0
- package/Icon/__snapshots__/index.test.tsx.snap +343 -0
- package/Icon/index.d.ts +25 -0
- package/Icon/index.js +34 -0
- package/Icon/index.test.d.ts +1 -0
- package/Icon/index.test.js +82 -0
- package/Icon/package.json +6 -0
- package/MoreVertIcon/config.js +7 -19
- package/MoreVertIcon/index.d.ts +1 -1
- 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.d.ts +1 -1
- 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.d.ts +1 -1
- 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/{esm → cjs}/GlobeIcon/config.js +17 -5
- package/cjs/GlobeIcon/index.js +24 -0
- package/cjs/GlobeIcon/index.test.js +39 -0
- package/cjs/Icon/__snapshots__/index.test.tsx.snap +343 -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.d.ts +3 -0
- package/icons.js +12 -135
- package/index.d.ts +1 -0
- package/index.js +11 -135
- package/package.json +4 -5
- package/registry.d.ts +2 -0
- package/registry.js +18 -39
- package/src/AccessibilityIcon/index.tsx +1 -1
- package/src/ArrowIcon/config.tsx +6 -6
- package/src/ArrowIcon/index.tsx +1 -1
- package/src/BurgerIcon/index.tsx +1 -1
- package/src/CaretIcon/index.tsx +1 -1
- package/src/CheckIcon/index.tsx +1 -1
- package/src/ChevronIcon/config.tsx +37 -0
- package/src/ChevronIcon/index.test.tsx +20 -0
- package/src/ChevronIcon/index.tsx +8 -0
- package/src/CloseIcon/index.tsx +1 -1
- package/src/GlobeIcon/index.tsx +1 -1
- package/src/Icon/__snapshots__/index.test.tsx.snap +343 -0
- package/src/Icon/index.test.tsx +36 -0
- package/src/Icon/index.tsx +63 -0
- package/src/MoreVertIcon/index.tsx +1 -1
- package/src/SearchIcon/index.tsx +1 -1
- package/src/UncheckIcon/index.tsx +1 -1
- package/src/icons.ts +3 -0
- package/src/index.ts +1 -0
- package/src/registry.js +4 -0
- 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/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/CloseIcon/config.js +0 -11
- package/es/CloseIcon/index.js +0 -9
- package/es/CloseIcon/index.test.js +0 -9
- package/es/GlobeIcon/config.js +0 -11
- package/es/GlobeIcon/index.js +0 -9
- package/es/GlobeIcon/index.test.js +0 -33
- 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 -11
- package/es/index.js +0 -10
- package/es/registry.js +0 -42
- package/esm/AccessibilityIcon/__snapshots__/index.test.tsx.snap +0 -408
- package/esm/AccessibilityIcon/config.js +0 -19
- package/esm/AccessibilityIcon/index.js +0 -9
- package/esm/AccessibilityIcon/index.test.js +0 -75
- package/esm/ArrowIcon/__snapshots__/index.test.tsx.snap +0 -148
- package/esm/ArrowIcon/config.js +0 -27
- package/esm/ArrowIcon/index.js +0 -9
- package/esm/ArrowIcon/index.test.js +0 -33
- package/esm/BurgerIcon/__snapshots__/index.test.tsx.snap +0 -320
- package/esm/BurgerIcon/config.js +0 -32
- package/esm/BurgerIcon/index.js +0 -9
- package/esm/BurgerIcon/index.test.js +0 -50
- package/esm/CaretIcon/__snapshots__/index.test.tsx.snap +0 -148
- package/esm/CaretIcon/config.js +0 -27
- package/esm/CaretIcon/index.js +0 -9
- package/esm/CaretIcon/index.test.js +0 -33
- package/esm/CheckIcon/__snapshots__/index.test.tsx.snap +0 -299
- package/esm/CheckIcon/config.js +0 -11
- package/esm/CheckIcon/index.js +0 -9
- package/esm/CheckIcon/index.test.js +0 -67
- package/esm/CloseIcon/__snapshots__/index.test.tsx.snap +0 -34
- package/esm/CloseIcon/config.js +0 -11
- package/esm/CloseIcon/index.js +0 -9
- package/esm/CloseIcon/index.test.js +0 -9
- package/esm/GlobeIcon/__snapshots__/index.test.tsx.snap +0 -149
- package/esm/GlobeIcon/index.js +0 -9
- package/esm/GlobeIcon/index.test.js +0 -33
- package/esm/MoreVertIcon/__snapshots__/index.test.tsx.snap +0 -444
- package/esm/MoreVertIcon/config.js +0 -25
- package/esm/MoreVertIcon/index.js +0 -9
- package/esm/MoreVertIcon/index.test.js +0 -75
- package/esm/SearchIcon/__snapshots__/index.test.tsx.snap +0 -34
- package/esm/SearchIcon/config.js +0 -11
- package/esm/SearchIcon/index.js +0 -9
- package/esm/SearchIcon/index.test.js +0 -9
- package/esm/UncheckIcon/__snapshots__/index.test.tsx.snap +0 -336
- package/esm/UncheckIcon/config.js +0 -11
- package/esm/UncheckIcon/index.js +0 -9
- package/esm/UncheckIcon/index.test.js +0 -75
- package/esm/icons.js +0 -11
- package/esm/index.js +0 -10
- package/esm/registry.js +0 -42
- /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}/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
|
@@ -0,0 +1,343 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
+
|
|
3
|
+
exports[`renders the Icon prop icon= "caret" 1`] = `
|
|
4
|
+
<ForwardRef(Icon)
|
|
5
|
+
icon="caret"
|
|
6
|
+
>
|
|
7
|
+
<ForwardRef(SvgIcon)
|
|
8
|
+
className="govgr-svg-icon--caret"
|
|
9
|
+
>
|
|
10
|
+
<ForwardRef(Base)
|
|
11
|
+
aria-hidden="true"
|
|
12
|
+
as="svg"
|
|
13
|
+
className="govgr-svg-icon--caret govgr-svg-icon"
|
|
14
|
+
focusable="false"
|
|
15
|
+
viewBox="0 0 24 24"
|
|
16
|
+
>
|
|
17
|
+
<svg
|
|
18
|
+
aria-hidden="true"
|
|
19
|
+
className="govgr-svg-icon--caret govgr-svg-icon"
|
|
20
|
+
focusable="false"
|
|
21
|
+
viewBox="0 0 24 24"
|
|
22
|
+
>
|
|
23
|
+
<caret>
|
|
24
|
+
<path
|
|
25
|
+
d="M18,22V2L6,12L18,22z"
|
|
26
|
+
/>
|
|
27
|
+
</caret>
|
|
28
|
+
</svg>
|
|
29
|
+
</ForwardRef(Base)>
|
|
30
|
+
</ForwardRef(SvgIcon)>
|
|
31
|
+
</ForwardRef(Icon)>
|
|
32
|
+
`;
|
|
33
|
+
|
|
34
|
+
exports[`renders the Icon prop icon= "caret" and direction=left 1`] = `
|
|
35
|
+
<ForwardRef(Icon)
|
|
36
|
+
direction="left"
|
|
37
|
+
icon="caret"
|
|
38
|
+
>
|
|
39
|
+
<ForwardRef(SvgIcon)
|
|
40
|
+
className="govgr-svg-icon--caret"
|
|
41
|
+
>
|
|
42
|
+
<ForwardRef(Base)
|
|
43
|
+
aria-hidden="true"
|
|
44
|
+
as="svg"
|
|
45
|
+
className="govgr-svg-icon--caret govgr-svg-icon"
|
|
46
|
+
focusable="false"
|
|
47
|
+
viewBox="0 0 24 24"
|
|
48
|
+
>
|
|
49
|
+
<svg
|
|
50
|
+
aria-hidden="true"
|
|
51
|
+
className="govgr-svg-icon--caret govgr-svg-icon"
|
|
52
|
+
focusable="false"
|
|
53
|
+
viewBox="0 0 24 24"
|
|
54
|
+
>
|
|
55
|
+
<caret
|
|
56
|
+
direction="left"
|
|
57
|
+
>
|
|
58
|
+
<path
|
|
59
|
+
d="M18,22V2L6,12L18,22z"
|
|
60
|
+
/>
|
|
61
|
+
</caret>
|
|
62
|
+
</svg>
|
|
63
|
+
</ForwardRef(Base)>
|
|
64
|
+
</ForwardRef(SvgIcon)>
|
|
65
|
+
</ForwardRef(Icon)>
|
|
66
|
+
`;
|
|
67
|
+
|
|
68
|
+
exports[`renders the Icon prop icon= "check" 1`] = `
|
|
69
|
+
<ForwardRef(Icon)
|
|
70
|
+
icon="check"
|
|
71
|
+
>
|
|
72
|
+
<ForwardRef(SvgIcon)
|
|
73
|
+
className="govgr-svg-icon--check"
|
|
74
|
+
>
|
|
75
|
+
<ForwardRef(Base)
|
|
76
|
+
aria-hidden="true"
|
|
77
|
+
as="svg"
|
|
78
|
+
className="govgr-svg-icon--check govgr-svg-icon"
|
|
79
|
+
focusable="false"
|
|
80
|
+
viewBox="0 0 24 24"
|
|
81
|
+
>
|
|
82
|
+
<svg
|
|
83
|
+
aria-hidden="true"
|
|
84
|
+
className="govgr-svg-icon--check govgr-svg-icon"
|
|
85
|
+
focusable="false"
|
|
86
|
+
viewBox="0 0 24 24"
|
|
87
|
+
>
|
|
88
|
+
<check>
|
|
89
|
+
<polygon
|
|
90
|
+
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"
|
|
91
|
+
/>
|
|
92
|
+
</check>
|
|
93
|
+
</svg>
|
|
94
|
+
</ForwardRef(Base)>
|
|
95
|
+
</ForwardRef(SvgIcon)>
|
|
96
|
+
</ForwardRef(Icon)>
|
|
97
|
+
`;
|
|
98
|
+
|
|
99
|
+
exports[`renders the Icon prop icon= "close" 1`] = `
|
|
100
|
+
<ForwardRef(Icon)
|
|
101
|
+
icon="close"
|
|
102
|
+
>
|
|
103
|
+
<ForwardRef(SvgIcon)
|
|
104
|
+
className="govgr-svg-icon--close"
|
|
105
|
+
>
|
|
106
|
+
<ForwardRef(Base)
|
|
107
|
+
aria-hidden="true"
|
|
108
|
+
as="svg"
|
|
109
|
+
className="govgr-svg-icon--close govgr-svg-icon"
|
|
110
|
+
focusable="false"
|
|
111
|
+
viewBox="0 0 24 24"
|
|
112
|
+
>
|
|
113
|
+
<svg
|
|
114
|
+
aria-hidden="true"
|
|
115
|
+
className="govgr-svg-icon--close govgr-svg-icon"
|
|
116
|
+
focusable="false"
|
|
117
|
+
viewBox="0 0 24 24"
|
|
118
|
+
>
|
|
119
|
+
<close>
|
|
120
|
+
<polygon
|
|
121
|
+
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 "
|
|
122
|
+
/>
|
|
123
|
+
</close>
|
|
124
|
+
</svg>
|
|
125
|
+
</ForwardRef(Base)>
|
|
126
|
+
</ForwardRef(SvgIcon)>
|
|
127
|
+
</ForwardRef(Icon)>
|
|
128
|
+
`;
|
|
129
|
+
|
|
130
|
+
exports[`renders the Icon prop icon= "uncheck" 1`] = `
|
|
131
|
+
<ForwardRef(Icon)
|
|
132
|
+
icon="uncheck"
|
|
133
|
+
>
|
|
134
|
+
<ForwardRef(SvgIcon)
|
|
135
|
+
className="govgr-svg-icon--uncheck"
|
|
136
|
+
>
|
|
137
|
+
<ForwardRef(Base)
|
|
138
|
+
aria-hidden="true"
|
|
139
|
+
as="svg"
|
|
140
|
+
className="govgr-svg-icon--uncheck govgr-svg-icon"
|
|
141
|
+
focusable="false"
|
|
142
|
+
viewBox="0 0 24 24"
|
|
143
|
+
>
|
|
144
|
+
<svg
|
|
145
|
+
aria-hidden="true"
|
|
146
|
+
className="govgr-svg-icon--uncheck govgr-svg-icon"
|
|
147
|
+
focusable="false"
|
|
148
|
+
viewBox="0 0 24 24"
|
|
149
|
+
>
|
|
150
|
+
<uncheck>
|
|
151
|
+
<polygon
|
|
152
|
+
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"
|
|
153
|
+
/>
|
|
154
|
+
</uncheck>
|
|
155
|
+
</svg>
|
|
156
|
+
</ForwardRef(Base)>
|
|
157
|
+
</ForwardRef(SvgIcon)>
|
|
158
|
+
</ForwardRef(Icon)>
|
|
159
|
+
`;
|
|
160
|
+
|
|
161
|
+
exports[`renders the Icon props icon= "moreVert" 1`] = `
|
|
162
|
+
<ForwardRef(Icon)
|
|
163
|
+
icon="moreVert"
|
|
164
|
+
>
|
|
165
|
+
<ForwardRef(SvgIcon)
|
|
166
|
+
className="govgr-svg-icon--moreVert"
|
|
167
|
+
>
|
|
168
|
+
<ForwardRef(Base)
|
|
169
|
+
aria-hidden="true"
|
|
170
|
+
as="svg"
|
|
171
|
+
className="govgr-svg-icon--moreVert govgr-svg-icon"
|
|
172
|
+
focusable="false"
|
|
173
|
+
viewBox="0 0 24 24"
|
|
174
|
+
>
|
|
175
|
+
<svg
|
|
176
|
+
aria-hidden="true"
|
|
177
|
+
className="govgr-svg-icon--moreVert govgr-svg-icon"
|
|
178
|
+
focusable="false"
|
|
179
|
+
viewBox="0 0 24 24"
|
|
180
|
+
>
|
|
181
|
+
<moreVert>
|
|
182
|
+
<circle
|
|
183
|
+
cx="12"
|
|
184
|
+
cy="5"
|
|
185
|
+
r="2"
|
|
186
|
+
/>
|
|
187
|
+
<circle
|
|
188
|
+
cx="12"
|
|
189
|
+
cy="12"
|
|
190
|
+
r="2"
|
|
191
|
+
/>
|
|
192
|
+
<circle
|
|
193
|
+
cx="12"
|
|
194
|
+
cy="19"
|
|
195
|
+
r="2"
|
|
196
|
+
/>
|
|
197
|
+
</moreVert>
|
|
198
|
+
</svg>
|
|
199
|
+
</ForwardRef(Base)>
|
|
200
|
+
</ForwardRef(SvgIcon)>
|
|
201
|
+
</ForwardRef(Icon)>
|
|
202
|
+
`;
|
|
203
|
+
|
|
204
|
+
exports[`renders the Icon with no props 1`] = `
|
|
205
|
+
<ForwardRef(Icon)>
|
|
206
|
+
<ForwardRef(SvgIcon)
|
|
207
|
+
className="govgr-svg-icon--arrow"
|
|
208
|
+
>
|
|
209
|
+
<ForwardRef(Base)
|
|
210
|
+
aria-hidden="true"
|
|
211
|
+
as="svg"
|
|
212
|
+
className="govgr-svg-icon--arrow govgr-svg-icon"
|
|
213
|
+
focusable="false"
|
|
214
|
+
viewBox="0 0 24 24"
|
|
215
|
+
>
|
|
216
|
+
<svg
|
|
217
|
+
aria-hidden="true"
|
|
218
|
+
className="govgr-svg-icon--arrow govgr-svg-icon"
|
|
219
|
+
focusable="false"
|
|
220
|
+
viewBox="0 0 24 24"
|
|
221
|
+
>
|
|
222
|
+
<arrow>
|
|
223
|
+
<path
|
|
224
|
+
d="M8.5,2L6.1,4.3l7.6,7.7l-7.6,7.6L8.5,22l10-10L8.5,2z"
|
|
225
|
+
/>
|
|
226
|
+
</arrow>
|
|
227
|
+
</svg>
|
|
228
|
+
</ForwardRef(Base)>
|
|
229
|
+
</ForwardRef(SvgIcon)>
|
|
230
|
+
</ForwardRef(Icon)>
|
|
231
|
+
`;
|
|
232
|
+
|
|
233
|
+
exports[`renders the Icon with prop icon=arrow and direction=up 1`] = `
|
|
234
|
+
<ForwardRef(Icon)
|
|
235
|
+
direction="up"
|
|
236
|
+
>
|
|
237
|
+
<ForwardRef(SvgIcon)
|
|
238
|
+
className="govgr-svg-icon--arrow"
|
|
239
|
+
>
|
|
240
|
+
<ForwardRef(Base)
|
|
241
|
+
aria-hidden="true"
|
|
242
|
+
as="svg"
|
|
243
|
+
className="govgr-svg-icon--arrow govgr-svg-icon"
|
|
244
|
+
focusable="false"
|
|
245
|
+
viewBox="0 0 24 24"
|
|
246
|
+
>
|
|
247
|
+
<svg
|
|
248
|
+
aria-hidden="true"
|
|
249
|
+
className="govgr-svg-icon--arrow govgr-svg-icon"
|
|
250
|
+
focusable="false"
|
|
251
|
+
viewBox="0 0 24 24"
|
|
252
|
+
>
|
|
253
|
+
<arrow
|
|
254
|
+
direction="up"
|
|
255
|
+
>
|
|
256
|
+
<path
|
|
257
|
+
d="M2,15.8l2.3,2.4l7.7-7.6l7.6,7.6l2.4-2.4l-10-10L2,15.8z"
|
|
258
|
+
/>
|
|
259
|
+
</arrow>
|
|
260
|
+
</svg>
|
|
261
|
+
</ForwardRef(Base)>
|
|
262
|
+
</ForwardRef(SvgIcon)>
|
|
263
|
+
</ForwardRef(Icon)>
|
|
264
|
+
`;
|
|
265
|
+
|
|
266
|
+
exports[`renders the Icon with prop prop icon=burger 1`] = `
|
|
267
|
+
<ForwardRef(Icon)
|
|
268
|
+
icon="burger"
|
|
269
|
+
>
|
|
270
|
+
<ForwardRef(SvgIcon)
|
|
271
|
+
className="govgr-svg-icon--burger"
|
|
272
|
+
>
|
|
273
|
+
<ForwardRef(Base)
|
|
274
|
+
aria-hidden="true"
|
|
275
|
+
as="svg"
|
|
276
|
+
className="govgr-svg-icon--burger govgr-svg-icon"
|
|
277
|
+
focusable="false"
|
|
278
|
+
viewBox="0 0 24 24"
|
|
279
|
+
>
|
|
280
|
+
<svg
|
|
281
|
+
aria-hidden="true"
|
|
282
|
+
className="govgr-svg-icon--burger govgr-svg-icon"
|
|
283
|
+
focusable="false"
|
|
284
|
+
viewBox="0 0 24 24"
|
|
285
|
+
>
|
|
286
|
+
<burger>
|
|
287
|
+
<g
|
|
288
|
+
className=""
|
|
289
|
+
>
|
|
290
|
+
<rect
|
|
291
|
+
height="3.3"
|
|
292
|
+
id="govgr-svg-icon--burger__line-1"
|
|
293
|
+
width="20"
|
|
294
|
+
/>
|
|
295
|
+
<rect
|
|
296
|
+
height="3.3"
|
|
297
|
+
id="govgr-svg-icon--burger__line-2"
|
|
298
|
+
width="20"
|
|
299
|
+
/>
|
|
300
|
+
<rect
|
|
301
|
+
height="3.3"
|
|
302
|
+
id="govgr-svg-icon--burger__line-3"
|
|
303
|
+
width="20"
|
|
304
|
+
/>
|
|
305
|
+
</g>
|
|
306
|
+
</burger>
|
|
307
|
+
</svg>
|
|
308
|
+
</ForwardRef(Base)>
|
|
309
|
+
</ForwardRef(SvgIcon)>
|
|
310
|
+
</ForwardRef(Icon)>
|
|
311
|
+
`;
|
|
312
|
+
|
|
313
|
+
exports[`renders the Icon with prop prop icon=globe 1`] = `
|
|
314
|
+
<ForwardRef(Icon)
|
|
315
|
+
icon="globe"
|
|
316
|
+
>
|
|
317
|
+
<ForwardRef(SvgIcon)
|
|
318
|
+
className="govgr-svg-icon--globe"
|
|
319
|
+
>
|
|
320
|
+
<ForwardRef(Base)
|
|
321
|
+
aria-hidden="true"
|
|
322
|
+
as="svg"
|
|
323
|
+
className="govgr-svg-icon--globe govgr-svg-icon"
|
|
324
|
+
focusable="false"
|
|
325
|
+
viewBox="0 0 24 24"
|
|
326
|
+
>
|
|
327
|
+
<svg
|
|
328
|
+
aria-hidden="true"
|
|
329
|
+
className="govgr-svg-icon--globe govgr-svg-icon"
|
|
330
|
+
focusable="false"
|
|
331
|
+
viewBox="0 0 24 24"
|
|
332
|
+
>
|
|
333
|
+
<globe>
|
|
334
|
+
<path
|
|
335
|
+
d="M12,0C5.4,0,0,5.4,0,12s5.4,12,12,12s12-5.4,12-12S18.6,0,12,0z M22.4,13.1C22.4,13.1,22.4,13.2,22.4,13.1 c0,0.4-0.1,0.8-0.2,1.1v0h-3.6c0.2-1.5,0.2-3,0-4.5h3.6v0c0.1,0.4,0.1,0.7,0.2,1.1c0,0,0,0,0,0C22.5,11.6,22.5,12.4,22.4,13.1z M16,21.7c1.1-1.5,2-3.5,2.4-6h3.4c0,0,0,0,0,0C20.8,18.4,18.7,20.6,16,21.7z M21.8,8.2C21.8,8.2,21.8,8.2,21.8,8.2l-3.4,0 c-0.4-2.4-1.3-4.5-2.4-6C18.7,3.4,20.8,5.6,21.8,8.2L21.8,8.2z M17.1,9.7c0.2,1.5,0.2,3,0,4.5h-4.4V9.7L17.1,9.7L17.1,9.7z M12.7,8.2V1.6c1.9,0.6,3.5,3.2,4.1,6.6L12.7,8.2L12.7,8.2z M12.7,15.7h4.1c-0.7,3.4-2.3,6.1-4.1,6.6V15.7L12.7,15.7z M2.2,15.8 C2.2,15.8,2.2,15.8,2.2,15.8l3.4,0c0.4,2.4,1.3,4.5,2.4,6C5.3,20.6,3.2,18.4,2.2,15.8L2.2,15.8z M8,2.3c-1.1,1.5-2,3.5-2.4,6H2.2 c0,0,0,0,0,0C3.2,5.6,5.3,3.4,8,2.3z M6.9,14.3c-0.2-1.5-0.2-3,0-4.5h4.4v4.5H6.9L6.9,14.3z M11.2,15.8v6.6 c-1.9-0.6-3.5-3.2-4.1-6.6L11.2,15.8L11.2,15.8z M11.2,8.3H7.1c0.7-3.4,2.3-6.1,4.1-6.6V8.3L11.2,8.3z M1.6,10.9 C1.6,10.9,1.6,10.8,1.6,10.9c0-0.4,0.1-0.8,0.2-1.1v0h3.6c-0.2,1.5-0.2,3,0,4.5H1.7v0c-0.1-0.4-0.1-0.7-0.2-1.1c0,0,0,0,0,0 C1.5,12.4,1.5,11.6,1.6,10.9z"
|
|
336
|
+
/>
|
|
337
|
+
|
|
338
|
+
</globe>
|
|
339
|
+
</svg>
|
|
340
|
+
</ForwardRef(Base)>
|
|
341
|
+
</ForwardRef(SvgIcon)>
|
|
342
|
+
</ForwardRef(Icon)>
|
|
343
|
+
`;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { mount } from 'enzyme';
|
|
3
|
+
|
|
4
|
+
import Icon from '@digigov/react-icons/Icon';
|
|
5
|
+
|
|
6
|
+
it('renders the Icon with no props', () => {
|
|
7
|
+
expect(mount(<Icon />)).toMatchSnapshot();
|
|
8
|
+
});
|
|
9
|
+
|
|
10
|
+
it('renders the Icon with prop icon=arrow and direction=up', () => {
|
|
11
|
+
expect(mount(<Icon direction="up" />)).toMatchSnapshot();
|
|
12
|
+
});
|
|
13
|
+
it('renders the Icon with prop prop icon=burger', () => {
|
|
14
|
+
expect(mount(<Icon icon="burger" />)).toMatchSnapshot();
|
|
15
|
+
});
|
|
16
|
+
it('renders the Icon prop icon= "caret"', () => {
|
|
17
|
+
expect(mount(<Icon icon="caret" />)).toMatchSnapshot();
|
|
18
|
+
});
|
|
19
|
+
it('renders the Icon prop icon= "caret" and direction=left', () => {
|
|
20
|
+
expect(mount(<Icon icon="caret" direction="left" />)).toMatchSnapshot();
|
|
21
|
+
});
|
|
22
|
+
it('renders the Icon prop icon= "check"', () => {
|
|
23
|
+
expect(mount(<Icon icon="check" />)).toMatchSnapshot();
|
|
24
|
+
});
|
|
25
|
+
it('renders the Icon prop icon= "close"', () => {
|
|
26
|
+
expect(mount(<Icon icon="close" />)).toMatchSnapshot();
|
|
27
|
+
});
|
|
28
|
+
it('renders the Icon with prop prop icon=globe', () => {
|
|
29
|
+
expect(mount(<Icon icon="globe" />)).toMatchSnapshot();
|
|
30
|
+
});
|
|
31
|
+
it('renders the Icon props icon= "moreVert"', () => {
|
|
32
|
+
expect(mount(<Icon icon="moreVert" />)).toMatchSnapshot();
|
|
33
|
+
});
|
|
34
|
+
it('renders the Icon prop icon= "uncheck"', () => {
|
|
35
|
+
expect(mount(<Icon icon="uncheck" />)).toMatchSnapshot();
|
|
36
|
+
});
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import SvgIcon, { SvgIconProps } from '@digigov/react-core/SvgIcon';
|
|
4
|
+
import * as icons from '@digigov/react-icons/icons';
|
|
5
|
+
import type { IconTypes } from '@digigov/react-icons/icons';
|
|
6
|
+
|
|
7
|
+
export type IconProps<N extends keyof IconTypes> = SvgIconProps &
|
|
8
|
+
IconTypes[N] & {
|
|
9
|
+
/**
|
|
10
|
+
* ref is optional.
|
|
11
|
+
* ref prop declares the reference of the svg icon component.
|
|
12
|
+
* It can be used to to access the DOM element and the React element.
|
|
13
|
+
*/
|
|
14
|
+
ref?: React.Ref<SVGSVGElement>;
|
|
15
|
+
/**
|
|
16
|
+
* icon is optional, but strongly recommended.
|
|
17
|
+
* Default value is 'chevron'.
|
|
18
|
+
* Use this prop to display the icon you want.
|
|
19
|
+
*/
|
|
20
|
+
icon?: N;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
type IconComponent = <C extends keyof IconTypes>(
|
|
24
|
+
props: IconProps<C>
|
|
25
|
+
) => React.ReactElement | null;
|
|
26
|
+
export type IconNames = keyof IconTypes;
|
|
27
|
+
/**
|
|
28
|
+
* Icon is used whenever we need a GOV.GR icon.
|
|
29
|
+
* Choose the icon from the list in icon prop.
|
|
30
|
+
*/
|
|
31
|
+
export const Icon: IconComponent = React.forwardRef<
|
|
32
|
+
SVGSVGElement,
|
|
33
|
+
IconProps<IconNames>
|
|
34
|
+
>(function Icon(
|
|
35
|
+
{ icon = 'chevron', className, ...props }: IconProps<IconNames>,
|
|
36
|
+
ref
|
|
37
|
+
) {
|
|
38
|
+
const IconComponent = icons[icon];
|
|
39
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
40
|
+
// @ts-ignore
|
|
41
|
+
const iconProps = IconComponent?.props.reduce((compProps, propName) => {
|
|
42
|
+
const value = props[propName];
|
|
43
|
+
delete props[propName];
|
|
44
|
+
return {
|
|
45
|
+
...compProps,
|
|
46
|
+
[propName]: value,
|
|
47
|
+
};
|
|
48
|
+
}, {});
|
|
49
|
+
|
|
50
|
+
return (
|
|
51
|
+
<SvgIcon
|
|
52
|
+
ref={ref}
|
|
53
|
+
{...props}
|
|
54
|
+
className={clsx(className, {
|
|
55
|
+
[`govgr-svg-icon--${icon}`]: true,
|
|
56
|
+
})}
|
|
57
|
+
>
|
|
58
|
+
<IconComponent {...iconProps} />
|
|
59
|
+
</SvgIcon>
|
|
60
|
+
);
|
|
61
|
+
});
|
|
62
|
+
|
|
63
|
+
export default Icon;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Icon, { IconProps } from '@digigov/react-
|
|
2
|
+
import Icon, { IconProps } from '@digigov/react-icons/Icon';
|
|
3
3
|
|
|
4
4
|
export const MoreVertIcon: React.FC<IconProps<'moreVert'>> = (props) => {
|
|
5
5
|
return <Icon {...props} icon="moreVert"></Icon>;
|
package/src/SearchIcon/index.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Icon, { IconProps } from '@digigov/react-
|
|
2
|
+
import Icon, { IconProps } from '@digigov/react-icons/Icon';
|
|
3
3
|
|
|
4
4
|
export const SearchIcon: React.FC<IconProps<'search'>> = (props) => {
|
|
5
5
|
return <Icon {...props} icon="search"></Icon>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Icon, { IconProps } from '@digigov/react-
|
|
2
|
+
import Icon, { IconProps } from '@digigov/react-icons/Icon';
|
|
3
3
|
|
|
4
4
|
export const UncheckIcon: React.FC<IconProps<'uncheck'>> = (props) => {
|
|
5
5
|
return <Icon {...props} icon="uncheck"></Icon>;
|
package/src/icons.ts
CHANGED
|
@@ -3,6 +3,7 @@ import type { ArrowType } from '@digigov/react-icons/ArrowIcon/config';
|
|
|
3
3
|
import type { BurgerType } from '@digigov/react-icons/BurgerIcon/config';
|
|
4
4
|
import type { CaretType } from '@digigov/react-icons/CaretIcon/config';
|
|
5
5
|
import type { CheckType } from '@digigov/react-icons/CheckIcon/config';
|
|
6
|
+
import type { ChevronType } from '@digigov/react-icons/ChevronIcon/config';
|
|
6
7
|
import type { CloseType } from '@digigov/react-icons/CloseIcon/config';
|
|
7
8
|
import type { GlobeType } from '@digigov/react-icons/GlobeIcon/config';
|
|
8
9
|
import type { MoreVertType } from '@digigov/react-icons/MoreVertIcon/config';
|
|
@@ -13,6 +14,7 @@ export * from '@digigov/react-icons/AccessibilityIcon/config';
|
|
|
13
14
|
export * from '@digigov/react-icons/ArrowIcon/config';
|
|
14
15
|
export * from '@digigov/react-icons/BurgerIcon/config';
|
|
15
16
|
export * from '@digigov/react-icons/CaretIcon/config';
|
|
17
|
+
export * from '@digigov/react-icons/ChevronIcon/config';
|
|
16
18
|
export * from '@digigov/react-icons/CloseIcon/config';
|
|
17
19
|
export * from '@digigov/react-icons/CheckIcon/config';
|
|
18
20
|
export * from '@digigov/react-icons/GlobeIcon/config';
|
|
@@ -31,4 +33,5 @@ export interface IconTypes {
|
|
|
31
33
|
moreVert: MoreVertType;
|
|
32
34
|
uncheck: UncheckType;
|
|
33
35
|
search: SearchType;
|
|
36
|
+
chevron: ChevronType;
|
|
34
37
|
}
|
package/src/index.ts
CHANGED
|
@@ -3,6 +3,7 @@ export * from '@digigov/react-icons/ArrowIcon';
|
|
|
3
3
|
export * from '@digigov/react-icons/BurgerIcon';
|
|
4
4
|
export * from '@digigov/react-icons/CaretIcon';
|
|
5
5
|
export * from '@digigov/react-icons/CheckIcon';
|
|
6
|
+
export * from '@digigov/react-icons/ChevronIcon';
|
|
6
7
|
export * from '@digigov/react-icons/UncheckIcon';
|
|
7
8
|
export * from '@digigov/react-icons/CloseIcon';
|
|
8
9
|
export * from '@digigov/react-icons/GlobeIcon';
|
package/src/registry.js
CHANGED
|
@@ -4,8 +4,10 @@ import * as _digigov_react_icons_ArrowIcon from '@digigov/react-icons/ArrowIcon'
|
|
|
4
4
|
import * as _digigov_react_icons_BurgerIcon from '@digigov/react-icons/BurgerIcon';
|
|
5
5
|
import * as _digigov_react_icons_CaretIcon from '@digigov/react-icons/CaretIcon';
|
|
6
6
|
import * as _digigov_react_icons_CheckIcon from '@digigov/react-icons/CheckIcon';
|
|
7
|
+
import * as _digigov_react_icons_ChevronIcon from '@digigov/react-icons/ChevronIcon';
|
|
7
8
|
import * as _digigov_react_icons_CloseIcon from '@digigov/react-icons/CloseIcon';
|
|
8
9
|
import * as _digigov_react_icons_GlobeIcon from '@digigov/react-icons/GlobeIcon';
|
|
10
|
+
import * as _digigov_react_icons_Icon from '@digigov/react-icons/Icon';
|
|
9
11
|
import * as _digigov_react_icons_icons from '@digigov/react-icons/icons';
|
|
10
12
|
import * as _digigov_react_icons from '@digigov/react-icons';
|
|
11
13
|
import * as _digigov_react_icons_MoreVertIcon from '@digigov/react-icons/MoreVertIcon';
|
|
@@ -36,8 +38,10 @@ export default {
|
|
|
36
38
|
'@digigov/react-icons/BurgerIcon': lazyImport(_digigov_react_icons_BurgerIcon),
|
|
37
39
|
'@digigov/react-icons/CaretIcon': lazyImport(_digigov_react_icons_CaretIcon),
|
|
38
40
|
'@digigov/react-icons/CheckIcon': lazyImport(_digigov_react_icons_CheckIcon),
|
|
41
|
+
'@digigov/react-icons/ChevronIcon': lazyImport(_digigov_react_icons_ChevronIcon),
|
|
39
42
|
'@digigov/react-icons/CloseIcon': lazyImport(_digigov_react_icons_CloseIcon),
|
|
40
43
|
'@digigov/react-icons/GlobeIcon': lazyImport(_digigov_react_icons_GlobeIcon),
|
|
44
|
+
'@digigov/react-icons/Icon': lazyImport(_digigov_react_icons_Icon),
|
|
41
45
|
'@digigov/react-icons/icons': lazyImport(_digigov_react_icons_icons),
|
|
42
46
|
'@digigov/react-icons': lazyImport(_digigov_react_icons),
|
|
43
47
|
'@digigov/react-icons/MoreVertIcon': lazyImport(_digigov_react_icons_MoreVertIcon),
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
3
|
-
var _ref = /*#__PURE__*/React.createElement("title", null, "\u039C\u03B5\u03BD\u03BF\u03CD \u03A0\u03C1\u03BF\u03C3\u03B2\u03B1\u03C3\u03B9\u03BC\u03CC\u03C4\u03B7\u03C4\u03B1\u03C2");
|
|
4
|
-
|
|
5
|
-
var _ref2 = /*#__PURE__*/React.createElement("circle", {
|
|
6
|
-
cx: "12",
|
|
7
|
-
cy: "3",
|
|
8
|
-
r: "3"
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref3 = /*#__PURE__*/React.createElement("path", {
|
|
12
|
-
d: "M19.76,6.13c-4.94,2.01-10.57,2.01-15.51,0c-0.71-0.3-1.55-0.04-1.98,0.66c-1.41,2.6,3.27,3.76,4.94,4.37 c0.4,0.11,0.81,0.2,1.22,0.28c0.56,0.11,0.92,0.67,0.79,1.25c-0.79,3.66-1.96,9.1-1.96,9.1c-0.46,2.27,2.72,3.15,3.39,0.92L12,17.93 l1.36,4.78c0.67,2.22,3.85,1.36,3.39-0.92c0,0-1.16-5.4-1.95-9.06c-0.12-0.57,0.22-1.16,0.77-1.27c2.01-0.41,3.94-1.17,5.68-2.31 C22.89,8.04,21.58,5.38,19.76,6.13z"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
export function accessibility() {
|
|
16
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, _ref, _ref2, _ref3);
|
|
17
|
-
}
|
|
18
|
-
accessibility.props = [];
|
|
19
|
-
export default accessibility;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import Icon from '@digigov/react-core/Icon';
|
|
4
|
-
export var AccessibilityIcon = function AccessibilityIcon(props) {
|
|
5
|
-
return /*#__PURE__*/React.createElement(Icon, _extends({}, props, {
|
|
6
|
-
icon: "accessibility"
|
|
7
|
-
}));
|
|
8
|
-
};
|
|
9
|
-
export default AccessibilityIcon;
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import AccessibilityIcon from '@digigov/react-icons/AccessibilityIcon';
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(AccessibilityIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the AccessibilityIcon with no props', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
12
|
-
size: "sm"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the AccessibilityIcon with prop size=s', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
20
|
-
size: "lg"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the AccessibilityIcon with prop size=l', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
28
|
-
variant: "dark"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the AccessibilityIcon with prop variant=dark', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
var _ref5 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
36
|
-
variant: "primary"
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
it('renders the AccessibilityIcon with prop variant=primary', function () {
|
|
40
|
-
expect(mount(_ref5)).toMatchSnapshot();
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
var _ref6 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
44
|
-
variant: "success"
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it('renders the AccessibilityIcon with prop variant=success', function () {
|
|
48
|
-
expect(mount(_ref6)).toMatchSnapshot();
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
var _ref7 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
52
|
-
variant: "error"
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
it('renders the AccessibilityIcon with prop variant=error', function () {
|
|
56
|
-
expect(mount(_ref7)).toMatchSnapshot();
|
|
57
|
-
});
|
|
58
|
-
|
|
59
|
-
var _ref8 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
60
|
-
variant: "warning",
|
|
61
|
-
size: "sm"
|
|
62
|
-
});
|
|
63
|
-
|
|
64
|
-
it('renders the AccessibilityIcon with prop variant=warning and size=s', function () {
|
|
65
|
-
expect(mount(_ref8)).toMatchSnapshot();
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
var _ref9 = /*#__PURE__*/React.createElement(AccessibilityIcon, {
|
|
69
|
-
variant: "warning",
|
|
70
|
-
size: "xl"
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
it('renders the AccessibilityIcon with prop variant=error and size= xl', function () {
|
|
74
|
-
expect(mount(_ref9)).toMatchSnapshot();
|
|
75
|
-
});
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { mount } from 'enzyme';
|
|
3
|
-
import ArrowIcon from '@digigov/react-icons/ArrowIcon';
|
|
4
|
-
|
|
5
|
-
var _ref = /*#__PURE__*/React.createElement(ArrowIcon, null);
|
|
6
|
-
|
|
7
|
-
it('renders the ArrowIcon with no props, direction prop is right by default', function () {
|
|
8
|
-
expect(mount(_ref)).toMatchSnapshot();
|
|
9
|
-
});
|
|
10
|
-
|
|
11
|
-
var _ref2 = /*#__PURE__*/React.createElement(ArrowIcon, {
|
|
12
|
-
direction: "left"
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
it('renders the ArrowIcon with direction left prop', function () {
|
|
16
|
-
expect(mount(_ref2)).toMatchSnapshot();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
var _ref3 = /*#__PURE__*/React.createElement(ArrowIcon, {
|
|
20
|
-
direction: "up"
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('renders the ArrowIcon with direction up prop', function () {
|
|
24
|
-
expect(mount(_ref3)).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
var _ref4 = /*#__PURE__*/React.createElement(ArrowIcon, {
|
|
28
|
-
direction: "down"
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
it('renders the ArrowIcon with direction down prop', function () {
|
|
32
|
-
expect(mount(_ref4)).toMatchSnapshot();
|
|
33
|
-
});
|