@oslokommune/punkt-react 5.1.18 → 5.1.20
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/CHANGELOG.md +175 -123
- package/package.json +4 -4
- package/src/components/footer/Footer.test.tsx +35 -35
- package/src/components/footer/__snapshots__/Footer.test.tsx.snap +9 -71
- package/src/components/footerSimple/FooterSimple.test.tsx +1 -1
- package/src/components/footerSimple/__snapshots__/FooterSimple.test.tsx.snap +4 -41
- package/src/components/linkcard/LinkCard.test.tsx +1 -1
- package/src/components/linkcard/__snapshots__/LinkCard.test.tsx.snap +4 -11
- package/src/components/tag/Tag.test.tsx +4 -4
- package/src/components/tag/__snapshots__/Tag.test.tsx.snap +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
3
|
Punkt følger [Semantic Versioning 2.0.0](https://semver.org/spec/v2.0.0.html) for versjonering,
|
|
4
|
-
og skriver commits ca etter [Conventional Commits](https://conventionalcommits.org).
|
|
4
|
+
og skriver commits ca etter [Conventional Commits](https://conventionalcommits.org).
|
|
5
5
|
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
-
## [5.1.
|
|
8
|
+
## [5.1.20](https://github.com/oslokommune/punkt/compare/5.1.19...5.1.20) (2023-07-24)
|
|
9
9
|
|
|
10
10
|
### ⚠ BREAKING CHANGES
|
|
11
11
|
Ingen
|
|
@@ -17,412 +17,478 @@ Ingen
|
|
|
17
17
|
Ingen
|
|
18
18
|
|
|
19
19
|
### Chores
|
|
20
|
-
*
|
|
20
|
+
* [949](https://github.com/oslokommune/punkt/issues/949) Tests in workflow.
|
|
21
|
+
* React test ved PR.
|
|
21
22
|
|
|
22
23
|
|
|
23
24
|
---
|
|
24
25
|
|
|
25
26
|
|
|
27
|
+
## [5.1.9](https://github.com/oslokommune/punkt/compare/5.1.8...5.1.9) (2023-07-14)
|
|
28
|
+
|
|
29
|
+
### ⚠ BREAKING CHANGES
|
|
30
|
+
|
|
31
|
+
Ingen
|
|
32
|
+
|
|
33
|
+
### Features
|
|
34
|
+
|
|
35
|
+
Ingen
|
|
36
|
+
|
|
37
|
+
### Bug Fixes
|
|
38
|
+
|
|
39
|
+
Ingen
|
|
40
|
+
|
|
41
|
+
### Chores
|
|
42
|
+
|
|
43
|
+
- Bump dependencies #918.
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
26
47
|
## [5.1.7](https://github.com/oslokommune/punkt/compare/5.1.6...5.1.7) (2023-06-28)
|
|
27
48
|
|
|
28
49
|
### ⚠ BREAKING CHANGES
|
|
50
|
+
|
|
29
51
|
Ingen
|
|
30
52
|
|
|
31
53
|
### Features
|
|
54
|
+
|
|
32
55
|
Ingen
|
|
33
56
|
|
|
34
57
|
### Bug Fixes
|
|
58
|
+
|
|
35
59
|
Ingen
|
|
36
60
|
|
|
37
61
|
### Chores
|
|
38
|
-
|
|
62
|
+
|
|
63
|
+
- [978](https://github.com/oslokommune/punkt/issues/978) Ny farge og modifier - tag. --blue-light
|
|
39
64
|
--thin-text
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
* bump semver from 7.5.1 to 7.5.2. Bumps [semver](https://github.com/npm/node-semver) from 7.5.1 to 7.5.2.
|
|
44
|
-
- [Release notes](https://github.com/npm/node-semver/releases)
|
|
45
|
-
- [Changelog](https://github.com/npm/node-semver/blob/main/CHANGELOG.md)
|
|
46
|
-
- [Commits](https://github.com/npm/node-semver/compare/v7.5.1...v7.5.2)
|
|
47
|
-
|
|
48
|
-
---
|
|
49
|
-
updated-dependencies:
|
|
50
|
-
- dependency-name: semver
|
|
51
|
-
dependency-type: direct:development
|
|
52
|
-
...
|
|
53
|
-
|
|
54
|
-
Signed-off-by: dependabot[bot] <support@github.com>
|
|
55
|
-
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
|
65
|
+
- [918](https://github.com/oslokommune/punkt/issues/918) Oppdatere dependencies. \* chore(all): #918 Semver from 7.4.0 to 7.5.3
|
|
66
|
+
- chore(vue2, react): #918 @astrojs/react and vue from 2.1.0 to 2.2.1
|
|
67
|
+
- bump semver from 7.5.1 to 7.5.2. Bumps [semver](https://github.com/npm/node-semver) from 7.5.1 to 7.5.2.
|
|
56
68
|
|
|
69
|
+
- [Release notes](https://github.com/npm/node-semver/releases)
|
|
70
|
+
- [Changelog](https://github.com/npm/node-semver/blob/main/CHANGELOG.md)
|
|
71
|
+
- [Commits](https://github.com/npm/node-semver/compare/v7.5.1...v7.5.2)
|
|
57
72
|
|
|
58
|
-
|
|
73
|
+
***
|
|
74
|
+
|
|
75
|
+
updated-dependencies:
|
|
76
|
+
|
|
77
|
+
- dependency-name: semver
|
|
78
|
+
dependency-type: direct:development
|
|
79
|
+
...
|
|
80
|
+
|
|
81
|
+
Signed-off-by: dependabot[bot] <support@github.com>
|
|
82
|
+
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
|
59
83
|
|
|
84
|
+
---
|
|
60
85
|
|
|
61
86
|
## [5.1.6](https://github.com/oslokommune/punkt/compare/5.1.5...5.1.6) (2023-06-22)
|
|
62
87
|
|
|
63
88
|
### ⚠ BREAKING CHANGES
|
|
89
|
+
|
|
64
90
|
Ingen
|
|
65
91
|
|
|
66
92
|
### Features
|
|
93
|
+
|
|
67
94
|
Ingen
|
|
68
95
|
|
|
69
96
|
### Bug Fixes
|
|
70
|
-
* [962](https://github.com/oslokommune/punkt/issues/962) Fiks icon cache.
|
|
71
97
|
|
|
98
|
+
- [962](https://github.com/oslokommune/punkt/issues/962) Fiks icon cache.
|
|
72
99
|
|
|
73
100
|
### Chores
|
|
101
|
+
|
|
74
102
|
Ingen
|
|
75
103
|
|
|
76
104
|
---
|
|
77
105
|
|
|
78
|
-
|
|
79
106
|
## [5.1.0](https://github.com/oslokommune/punkt/compare/5.0.11...5.1.0) (2023-06-12)
|
|
80
107
|
|
|
81
108
|
### ⚠ BREAKING CHANGES
|
|
109
|
+
|
|
82
110
|
Ingen
|
|
83
111
|
|
|
84
112
|
### Features
|
|
85
|
-
* [846](https://github.com/oslokommune/punkt/issues/846) Ny komponent tag. Tag erstatter Badge, men badge blir fortsatt liggende i CSS, men denne skal altså slettes.
|
|
86
113
|
|
|
114
|
+
- [846](https://github.com/oslokommune/punkt/issues/846) Ny komponent tag. Tag erstatter Badge, men badge blir fortsatt liggende i CSS, men denne skal altså slettes.
|
|
87
115
|
|
|
88
116
|
### Bug Fixes
|
|
117
|
+
|
|
89
118
|
Ingen
|
|
90
119
|
|
|
91
120
|
### Chores
|
|
121
|
+
|
|
92
122
|
Ingen
|
|
93
123
|
|
|
94
124
|
---
|
|
95
125
|
|
|
96
|
-
|
|
97
126
|
## [5.0.9](https://github.com/oslokommune/punkt/compare/5.0.8...5.0.9) (2023-06-06)
|
|
98
127
|
|
|
99
128
|
### ⚠ BREAKING CHANGES
|
|
129
|
+
|
|
100
130
|
Ingen
|
|
101
131
|
|
|
102
132
|
### Features
|
|
133
|
+
|
|
103
134
|
Ingen
|
|
104
135
|
|
|
105
136
|
### Bug Fixes
|
|
106
|
-
* [938](https://github.com/oslokommune/punkt/issues/938) Sjekk om fetch eksisterer før vi kaller det i PktIcon (#939).
|
|
107
137
|
|
|
138
|
+
- [938](https://github.com/oslokommune/punkt/issues/938) Sjekk om fetch eksisterer før vi kaller det i PktIcon (#939).
|
|
108
139
|
|
|
109
140
|
### Chores
|
|
141
|
+
|
|
110
142
|
Ingen
|
|
111
143
|
|
|
112
144
|
---
|
|
113
145
|
|
|
114
|
-
|
|
115
146
|
## [5.0.7](https://github.com/oslokommune/punkt/compare/5.0.6...5.0.7) (2023-06-02)
|
|
116
147
|
|
|
117
148
|
### ⚠ BREAKING CHANGES
|
|
149
|
+
|
|
118
150
|
Ingen
|
|
119
151
|
|
|
120
152
|
### Features
|
|
153
|
+
|
|
121
154
|
Ingen
|
|
122
155
|
|
|
123
156
|
### Bug Fixes
|
|
124
|
-
* [913](https://github.com/oslokommune/punkt/issues/913) Fiks headerlogo path.
|
|
125
157
|
|
|
158
|
+
- [913](https://github.com/oslokommune/punkt/issues/913) Fiks headerlogo path.
|
|
126
159
|
|
|
127
160
|
### Chores
|
|
161
|
+
|
|
128
162
|
Ingen
|
|
129
163
|
|
|
130
164
|
---
|
|
131
165
|
|
|
132
|
-
|
|
133
166
|
## [5.0.4](https://github.com/oslokommune/punkt/compare/5.0.3...5.0.4) (2023-06-01)
|
|
134
167
|
|
|
135
168
|
### ⚠ BREAKING CHANGES
|
|
169
|
+
|
|
136
170
|
Ingen
|
|
137
171
|
|
|
138
172
|
### Features
|
|
173
|
+
|
|
139
174
|
Ingen
|
|
140
175
|
|
|
141
176
|
### Bug Fixes
|
|
142
|
-
* Fiks størrelser på ikoner og ikon i knapper (#907).
|
|
143
|
-
* Fiks størrelser på ikoner og visning av ikon i knapper.
|
|
144
177
|
|
|
178
|
+
- Fiks størrelser på ikoner og ikon i knapper (#907).
|
|
179
|
+
- Fiks størrelser på ikoner og visning av ikon i knapper.
|
|
145
180
|
|
|
146
181
|
### Chores
|
|
182
|
+
|
|
147
183
|
Ingen
|
|
148
184
|
|
|
149
185
|
---
|
|
150
186
|
|
|
151
|
-
|
|
152
187
|
## [5.0.3](https://github.com/oslokommune/punkt/compare/5.0.2...5.0.3) (2023-06-01)
|
|
153
188
|
|
|
154
189
|
### ⚠ BREAKING CHANGES
|
|
190
|
+
|
|
155
191
|
Ingen
|
|
156
192
|
|
|
157
193
|
### Features
|
|
194
|
+
|
|
158
195
|
Ingen
|
|
159
196
|
|
|
160
197
|
### Bug Fixes
|
|
161
|
-
* [903](https://github.com/oslokommune/punkt/issues/903) Fiks eksport av icon.
|
|
162
198
|
|
|
199
|
+
- [903](https://github.com/oslokommune/punkt/issues/903) Fiks eksport av icon.
|
|
163
200
|
|
|
164
201
|
### Chores
|
|
202
|
+
|
|
165
203
|
Ingen
|
|
166
204
|
|
|
167
205
|
---
|
|
168
206
|
|
|
169
|
-
|
|
170
207
|
## [5.0.2](https://github.com/oslokommune/punkt/compare/5.0.1...5.0.2) (2023-05-31)
|
|
171
208
|
|
|
172
209
|
### ⚠ BREAKING CHANGES
|
|
210
|
+
|
|
173
211
|
Ingen
|
|
174
212
|
|
|
175
213
|
### Features
|
|
214
|
+
|
|
176
215
|
Ingen
|
|
177
216
|
|
|
178
217
|
### Bug Fixes
|
|
179
|
-
* Fix publish to gh.
|
|
180
218
|
|
|
219
|
+
- Fix publish to gh.
|
|
181
220
|
|
|
182
221
|
### Chores
|
|
222
|
+
|
|
183
223
|
Ingen
|
|
184
224
|
|
|
185
225
|
---
|
|
186
226
|
|
|
187
|
-
|
|
188
227
|
## [5.0.1](https://github.com/oslokommune/punkt/compare/5.0.0...5.0.1) (2023-05-30)
|
|
189
228
|
|
|
190
229
|
### ⚠ BREAKING CHANGES
|
|
230
|
+
|
|
191
231
|
Ingen
|
|
192
232
|
|
|
193
233
|
### Features
|
|
234
|
+
|
|
194
235
|
Ingen
|
|
195
236
|
|
|
196
237
|
### Bug Fixes
|
|
197
|
-
* Fiks publisering til gh packages.
|
|
198
238
|
|
|
239
|
+
- Fiks publisering til gh packages.
|
|
199
240
|
|
|
200
241
|
### Chores
|
|
242
|
+
|
|
201
243
|
Ingen
|
|
202
244
|
|
|
203
245
|
---
|
|
204
246
|
|
|
205
|
-
|
|
206
247
|
## [5.0.0](https://github.com/oslokommune/punkt/compare/4.3.2...5.0.0) (2023-05-30)
|
|
207
248
|
|
|
208
249
|
### ⚠ BREAKING CHANGES
|
|
209
|
-
|
|
250
|
+
|
|
251
|
+
- [809](https://github.com/oslokommune/punkt/issues/809) Endre SVG oppsett (#851). BREAKING CHANGE: Ny dokumentasjon straks vi har testet dette ferdig
|
|
210
252
|
|
|
211
253
|
Nytt:
|
|
212
|
-
|
|
254
|
+
|
|
255
|
+
- Ikoner kommer med komponentene
|
|
213
256
|
- Oppdatert PktIcon-komponent
|
|
214
257
|
- Ny CSS-klasse `pkt-icon`
|
|
215
258
|
- Fjernet data: import av ikoner i CSS
|
|
216
259
|
|
|
217
260
|
Punkt CLI skal vedlikeholdes men ikke videreutvikles, så det er fortsatt mulig å bruke svg-oppsettet ved bruk av CLI. Men vi vil anbefale å bruke ikon-komponenten vår som dynamisk henter ikoner slik at du kan slippe å tenke på at ikoner en gang i blant må oppdateres.
|
|
218
261
|
|
|
219
|
-
Les mer om ikoner her:
|
|
262
|
+
Les mer om ikoner her:
|
|
220
263
|
https://punkt.oslo.kommune.no/5.0/ressurser/ikoner/kode/
|
|
221
264
|
|
|
222
265
|
**Hva må du gjøre?**
|
|
223
266
|
|
|
224
|
-
Alle som bruker klasser/komponenter som inneholder ikoner:
|
|
225
|
-
Import av ikoner i CSS henter vi nå fra vår CDN.
|
|
267
|
+
Alle som bruker klasser/komponenter som inneholder ikoner:
|
|
268
|
+
Import av ikoner i CSS henter vi nå fra vår CDN.
|
|
269
|
+
|
|
226
270
|
- Dere som har satt opp CSP må legge inn https://punkt-cdn.oslo.kommune.no/ i deres CSP.
|
|
227
271
|
|
|
228
|
-
**Vue2 og React**
|
|
272
|
+
**Vue2 og React**
|
|
229
273
|
|
|
230
274
|
Ikonene kommer nå inkludert med komponentene ved bruk av PktIcon.
|
|
231
275
|
Hvis du har brukt Punkt CLI til å legge til ikoner/logo i komponenter kan du nå fjerne punkt.config.json og dens svg'er. Hvis du har konfigurert CSP må du legge til CDN i din CSP. https://punkt-cdn.oslo.kommune.no/
|
|
232
276
|
|
|
233
|
-
PktIcon har blitt oppdatert med nye props.
|
|
277
|
+
PktIcon har blitt oppdatert med nye props.
|
|
234
278
|
|
|
235
279
|
### Features
|
|
280
|
+
|
|
236
281
|
Ingen
|
|
237
282
|
|
|
238
283
|
### Bug Fixes
|
|
284
|
+
|
|
239
285
|
Ingen
|
|
240
286
|
|
|
241
287
|
### Chores
|
|
288
|
+
|
|
242
289
|
Ingen
|
|
243
290
|
|
|
244
291
|
---
|
|
245
292
|
|
|
246
|
-
|
|
247
293
|
## [4.3.0](https://github.com/oslokommune/punkt/compare/4.2.1...4.3.0) (2023-05-24)
|
|
248
294
|
|
|
249
295
|
### ⚠ BREAKING CHANGES
|
|
296
|
+
|
|
250
297
|
Ingen
|
|
251
298
|
|
|
252
299
|
### Features
|
|
253
|
-
* [869](https://github.com/oslokommune/punkt/issues/869) External Linkcard.
|
|
254
300
|
|
|
301
|
+
- [869](https://github.com/oslokommune/punkt/issues/869) External Linkcard.
|
|
255
302
|
|
|
256
303
|
### Bug Fixes
|
|
257
|
-
* [869](https://github.com/oslokommune/punkt/issues/869) ForwardRef - linkcard.
|
|
258
304
|
|
|
305
|
+
- [869](https://github.com/oslokommune/punkt/issues/869) ForwardRef - linkcard.
|
|
259
306
|
|
|
260
307
|
### Chores
|
|
308
|
+
|
|
261
309
|
Ingen
|
|
262
310
|
|
|
263
311
|
---
|
|
264
312
|
|
|
265
|
-
|
|
266
313
|
## [4.3.0](https://github.com/oslokommune/punkt/compare/4.2.0...4.3.0) (2023-05-23)
|
|
267
314
|
|
|
268
315
|
### ⚠ BREAKING CHANGES
|
|
316
|
+
|
|
269
317
|
Ingen
|
|
270
318
|
|
|
271
319
|
### Features
|
|
320
|
+
|
|
272
321
|
Ingen
|
|
273
322
|
|
|
274
323
|
### Bug Fixes
|
|
275
|
-
* Legg til type i PktButton slik at skjema ikke sendes inn … (#875). * fix(vue2,react): Legg til type i PktButton slik at skjema ikke sendes inn av en vanlig knapp
|
|
276
|
-
* fix(vue2,react): type="button" på lukkeknappen i PktAlert
|
|
277
324
|
|
|
325
|
+
- Legg til type i PktButton slik at skjema ikke sendes inn … (#875). \* fix(vue2,react): Legg til type i PktButton slik at skjema ikke sendes inn av en vanlig knapp
|
|
326
|
+
- fix(vue2,react): type="button" på lukkeknappen i PktAlert
|
|
278
327
|
|
|
279
328
|
### Chores
|
|
329
|
+
|
|
280
330
|
Ingen
|
|
281
331
|
|
|
282
332
|
---
|
|
283
333
|
|
|
284
|
-
|
|
285
334
|
## [4.2.0](https://github.com/oslokommune/punkt/compare/4.1.0...4.2.0) (2023-05-16)
|
|
286
335
|
|
|
287
336
|
### ⚠ BREAKING CHANGES
|
|
337
|
+
|
|
288
338
|
Ingen
|
|
289
339
|
|
|
290
340
|
### Features
|
|
291
|
-
* [852](https://github.com/oslokommune/punkt/issues/852) Legg til openInNewTab - Linkcard. Lagt til ny prop i Linkcard: openInNewTab.
|
|
292
|
-
Om du ønsker at linken skal åpnes i ny fane send openInNewTab = true. Da vil det legges til en target="_blank" og rel="noopener noreferrer"
|
|
293
341
|
|
|
342
|
+
- [852](https://github.com/oslokommune/punkt/issues/852) Legg til openInNewTab - Linkcard. Lagt til ny prop i Linkcard: openInNewTab.
|
|
343
|
+
Om du ønsker at linken skal åpnes i ny fane send openInNewTab = true. Da vil det legges til en target="\_blank" og rel="noopener noreferrer"
|
|
294
344
|
|
|
295
345
|
### Bug Fixes
|
|
346
|
+
|
|
296
347
|
Ingen
|
|
297
348
|
|
|
298
349
|
### Chores
|
|
350
|
+
|
|
299
351
|
Ingen
|
|
300
352
|
|
|
301
353
|
---
|
|
302
354
|
|
|
303
|
-
|
|
304
355
|
## [4.1.0](https://github.com/oslokommune/punkt/compare/4.0.1...4.1.0) (2023-05-16)
|
|
305
356
|
|
|
306
357
|
### ⚠ BREAKING CHANGES
|
|
358
|
+
|
|
307
359
|
Ingen
|
|
308
360
|
|
|
309
361
|
### Features
|
|
310
|
-
* [850](https://github.com/oslokommune/punkt/issues/850) openInNewTab prop - Footer. Lagt til ny prop i Footer og FooterSimple: openInNewTab.
|
|
311
|
-
Om du ønsker at linken skal åpnes i ny fane send openInNewTab = true. Da vil det legges til en target="_blank" og rel="noopener noreferrer"
|
|
312
362
|
|
|
363
|
+
- [850](https://github.com/oslokommune/punkt/issues/850) openInNewTab prop - Footer. Lagt til ny prop i Footer og FooterSimple: openInNewTab.
|
|
364
|
+
Om du ønsker at linken skal åpnes i ny fane send openInNewTab = true. Da vil det legges til en target="\_blank" og rel="noopener noreferrer"
|
|
313
365
|
|
|
314
366
|
### Bug Fixes
|
|
367
|
+
|
|
315
368
|
Ingen
|
|
316
369
|
|
|
317
370
|
### Chores
|
|
371
|
+
|
|
318
372
|
Ingen
|
|
319
373
|
|
|
320
374
|
---
|
|
321
375
|
|
|
322
|
-
|
|
323
376
|
## [4.0.0](https://github.com/oslokommune/punkt/compare/3.4.2...4.0.0) (2023-05-08)
|
|
324
377
|
|
|
325
378
|
### ⚠ BREAKING CHANGES
|
|
326
|
-
|
|
379
|
+
|
|
380
|
+
- [792](https://github.com/oslokommune/punkt/issues/792) Footer. Nye komponenter:
|
|
381
|
+
|
|
327
382
|
- pkt-footer
|
|
328
383
|
- pkt-footer-simple
|
|
329
|
-
|
|
330
|
-
BREAKING CHANGE: Gammel pkt-footer er nå blitt pkt-footer-simple
|
|
331
384
|
|
|
385
|
+
BREAKING CHANGE: Gammel pkt-footer er nå blitt pkt-footer-simple
|
|
332
386
|
|
|
333
387
|
### Features
|
|
388
|
+
|
|
334
389
|
Ingen
|
|
335
390
|
|
|
336
391
|
### Bug Fixes
|
|
392
|
+
|
|
337
393
|
Ingen
|
|
338
394
|
|
|
339
395
|
### Chores
|
|
396
|
+
|
|
340
397
|
Ingen
|
|
341
398
|
|
|
342
399
|
---
|
|
343
400
|
|
|
344
|
-
|
|
345
401
|
## [3.4.2](https://github.com/oslokommune/punkt/compare/3.4.1...3.4.2) (2023-05-04)
|
|
346
402
|
|
|
347
403
|
### ⚠ BREAKING CHANGES
|
|
404
|
+
|
|
348
405
|
Ingen
|
|
349
406
|
|
|
350
407
|
### Features
|
|
408
|
+
|
|
351
409
|
Ingen
|
|
352
410
|
|
|
353
411
|
### Bug Fixes
|
|
354
|
-
* [825](https://github.com/oslokommune/punkt/issues/825) Ref og tester i button og alert.
|
|
355
412
|
|
|
413
|
+
- [825](https://github.com/oslokommune/punkt/issues/825) Ref og tester i button og alert.
|
|
356
414
|
|
|
357
415
|
### Chores
|
|
416
|
+
|
|
358
417
|
Ingen
|
|
359
418
|
|
|
360
419
|
---
|
|
361
420
|
|
|
362
|
-
|
|
363
421
|
## [3.4.1](https://github.com/oslokommune/punkt/compare/3.4.0...3.4.1) (2023-05-04)
|
|
364
422
|
|
|
365
423
|
### ⚠ BREAKING CHANGES
|
|
424
|
+
|
|
366
425
|
Ingen
|
|
367
426
|
|
|
368
427
|
### Features
|
|
428
|
+
|
|
369
429
|
Ingen
|
|
370
430
|
|
|
371
431
|
### Bug Fixes
|
|
372
|
-
* [828](https://github.com/oslokommune/punkt/issues/828) Fiks lint i react.
|
|
373
432
|
|
|
433
|
+
- [828](https://github.com/oslokommune/punkt/issues/828) Fiks lint i react.
|
|
374
434
|
|
|
375
435
|
### Chores
|
|
436
|
+
|
|
376
437
|
Ingen
|
|
377
438
|
|
|
378
439
|
---
|
|
379
440
|
|
|
380
|
-
|
|
381
441
|
## [3.4.0](https://github.com/oslokommune/punkt/compare/3.3.1...3.4.0) (2023-05-04)
|
|
382
442
|
|
|
383
443
|
### ⚠ BREAKING CHANGES
|
|
444
|
+
|
|
384
445
|
Ingen
|
|
385
446
|
|
|
386
447
|
### Features
|
|
387
|
-
* [825](https://github.com/oslokommune/punkt/issues/825) Legg til forward ref på React-knapp. Legger til forward ref på React-knapp for bedre tilgjengelighet og funksjonalitet
|
|
388
|
-
Installerer og konfigurerer to nye biblioteker for linting for å forbedre kodekvaliteten og vedlikeholdet
|
|
389
448
|
|
|
449
|
+
- [825](https://github.com/oslokommune/punkt/issues/825) Legg til forward ref på React-knapp. Legger til forward ref på React-knapp for bedre tilgjengelighet og funksjonalitet
|
|
450
|
+
Installerer og konfigurerer to nye biblioteker for linting for å forbedre kodekvaliteten og vedlikeholdet
|
|
390
451
|
|
|
391
452
|
### Bug Fixes
|
|
453
|
+
|
|
392
454
|
Ingen
|
|
393
455
|
|
|
394
456
|
### Chores
|
|
457
|
+
|
|
395
458
|
Ingen
|
|
396
459
|
|
|
397
460
|
---
|
|
398
461
|
|
|
399
|
-
|
|
400
462
|
## [3.2.1](https://github.com/oslokommune/punkt/compare/3.2.0...3.2.1) (2023-04-20)
|
|
401
463
|
|
|
402
464
|
### ⚠ BREAKING CHANGES
|
|
465
|
+
|
|
403
466
|
Ingen
|
|
404
467
|
|
|
405
468
|
### Features
|
|
469
|
+
|
|
406
470
|
Ingen
|
|
407
471
|
|
|
408
472
|
### Bug Fixes
|
|
409
|
-
* Legge til manglende changelogs (#804). Changelogs ble ikke generert for v3.2.0 pga en feil. Denne releasen er kun for å bumpe versjonen og få changelogs på plass.
|
|
410
473
|
|
|
474
|
+
- Legge til manglende changelogs (#804). Changelogs ble ikke generert for v3.2.0 pga en feil. Denne releasen er kun for å bumpe versjonen og få changelogs på plass.
|
|
411
475
|
|
|
412
476
|
### Chores
|
|
477
|
+
|
|
413
478
|
Ingen
|
|
414
479
|
|
|
415
480
|
---
|
|
416
481
|
|
|
417
|
-
|
|
418
482
|
## [3.2.0](https://github.com/oslokommune/punkt/compare/3.1.2...3.2.0) (2023-04-20)
|
|
419
483
|
|
|
420
484
|
### ⚠ BREAKING CHANGES
|
|
485
|
+
|
|
421
486
|
Ingen
|
|
422
487
|
|
|
423
488
|
### Features
|
|
424
|
-
|
|
425
|
-
|
|
489
|
+
|
|
490
|
+
- [760](https://github.com/oslokommune/punkt/issues/760) Link og linkcard
|
|
491
|
+
To nyheter denne gangen; link og linkcard.
|
|
426
492
|
|
|
427
493
|
Link har fått en overhaling, og har fått mulighet til å skille
|
|
428
494
|
visuelt på intern og ekstern lenke. Focus state er nå mer synlig.
|
|
@@ -434,16 +500,18 @@ lenketekst og mer informasjon under lenketeksten. Komponenten
|
|
|
434
500
|
finnes både i CSS, React og Vue2. Les mer på
|
|
435
501
|
https://punkt.oslo.kommune.no/3.2/komponenter/linkcard/
|
|
436
502
|
|
|
437
|
-
|
|
503
|
+
---
|
|
504
|
+
|
|
438
505
|
Co-authored-by: Cecilie Hansen Rørås <cecilie.roras@origo.oslo.kommune.no>
|
|
439
506
|
Co-authored-by: Ole Aasen <ole.aasen@origo.oslo.kommune.no>
|
|
440
507
|
Co-authored-by: Victoria Nerem <118815886+vicnerem@users.noreply.github.com>
|
|
441
508
|
|
|
442
509
|
### Bug Fixes
|
|
443
|
-
Ingen
|
|
444
510
|
|
|
511
|
+
Ingen
|
|
445
512
|
|
|
446
513
|
### Chores
|
|
514
|
+
|
|
447
515
|
Ingen
|
|
448
516
|
|
|
449
517
|
---
|
|
@@ -451,119 +519,112 @@ Ingen
|
|
|
451
519
|
## [3.1.2](https://github.com/oslokommune/punkt/compare/3.1.1...3.1.2) (2023-03-30)
|
|
452
520
|
|
|
453
521
|
### ⚠ BREAKING CHANGES
|
|
522
|
+
|
|
454
523
|
Ingen
|
|
455
524
|
|
|
456
525
|
### Features
|
|
526
|
+
|
|
457
527
|
Ingen
|
|
458
528
|
|
|
459
529
|
### Bug Fixes
|
|
530
|
+
|
|
460
531
|
Ingen
|
|
461
532
|
|
|
462
533
|
### Chores
|
|
534
|
+
|
|
463
535
|
Ingen
|
|
464
536
|
|
|
465
537
|
---
|
|
466
538
|
|
|
467
|
-
|
|
468
539
|
## [3.1.1](https://github.com/oslokommune/punkt/compare/3.1.0...3.1.1) (2023-03-23)
|
|
469
540
|
|
|
470
541
|
### ⚠ BREAKING CHANGES
|
|
542
|
+
|
|
471
543
|
Ingen
|
|
472
544
|
|
|
473
545
|
### Features
|
|
546
|
+
|
|
474
547
|
Ingen
|
|
475
548
|
|
|
476
549
|
### Bug Fixes
|
|
550
|
+
|
|
477
551
|
Ingen
|
|
478
552
|
|
|
479
553
|
### Chores
|
|
480
|
-
* [670](https://github.com/oslokommune/punkt/issues/670) Generer changelog automatisk (#746). Changelog genereres nå automatisk utifra commits, så lenge de følger Convential commits malen.
|
|
481
|
-
|
|
482
|
-
Dette er dokumentert i [CONTRIBUTING.md](https://github.com/oslokommune/punkt/blob/main/CONTRIBUTING.md) og i [scriptet som gjør dette ved publisering](https://github.com/oslokommune/punkt/blob/main/scripts/update-changelog.js).
|
|
483
554
|
|
|
555
|
+
- [670](https://github.com/oslokommune/punkt/issues/670) Generer changelog automatisk (#746). Changelog genereres nå automatisk utifra commits, så lenge de følger Convential commits malen.
|
|
484
556
|
|
|
485
|
-
|
|
557
|
+
Dette er dokumentert i [CONTRIBUTING.md](https://github.com/oslokommune/punkt/blob/main/CONTRIBUTING.md) og i [scriptet som gjør dette ved publisering](https://github.com/oslokommune/punkt/blob/main/scripts/update-changelog.js).
|
|
486
558
|
|
|
559
|
+
---
|
|
487
560
|
|
|
488
561
|
## [3.1.0](https://github.com/oslokommune/punkt/compare/v3.0.2...v3.1.0) (2023-03-20)
|
|
489
562
|
|
|
490
563
|
### Features
|
|
491
|
-
|
|
564
|
+
|
|
565
|
+
- [#720](https://github.com/oslokommune/punkt/issues/720) Lag Messagebox i React
|
|
492
566
|
|
|
493
567
|
## [3.0.2](https://github.com/oslokommune/punkt/compare/v3.0.1...v3.0.2) (2023-03-16)
|
|
494
568
|
|
|
495
569
|
### Bug Fixes
|
|
496
|
-
|
|
497
|
-
|
|
570
|
+
|
|
571
|
+
- [#735](https://github.com/oslokommune/punkt/issues/735) Rett feil i visning av innlogget bruker i Header komponent
|
|
572
|
+
Rettet referanse til css-klassen `pkt-truncate-text` fra `truncate-text`.
|
|
498
573
|
|
|
499
574
|
## [3.0.0](https://github.com/oslokommune/punkt/compare/v2.0.3...v3.0.0) (2023-03-13)
|
|
500
575
|
|
|
501
576
|
Versjon 3 inneholder endringer på Alert-komponenten både i css og Vue2, og finnes nå også i React.
|
|
502
577
|
|
|
503
578
|
### Features
|
|
504
|
-
* [#683](https://github.com/oslokommune/punkt/issues/683) Legg til Alert i React. Se mer informasjon på [nettsiden](https://punkt.oslo.kommune.no/3.0/komponenter/alert/kode/).
|
|
505
579
|
|
|
580
|
+
- [#683](https://github.com/oslokommune/punkt/issues/683) Legg til Alert i React. Se mer informasjon på [nettsiden](https://punkt.oslo.kommune.no/3.0/komponenter/alert/kode/).
|
|
506
581
|
|
|
507
582
|
## [2.0.3](https://github.com/oslokommune/punkt/compare/v2.0.2...v2.0.3) (2023-03-09)
|
|
508
583
|
|
|
509
|
-
|
|
510
584
|
### Bug Fixes
|
|
511
585
|
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
586
|
+
- **css:** [#703](https://github.com/oslokommune/punkt/issues/703) Rett feil på button icon-only ([#704](https://github.com/oslokommune/punkt/issues/704)) ([504daf9](https://github.com/oslokommune/punkt/commit/504daf9b71136742dac8f0c5300417b0f2ccbc91))
|
|
515
587
|
|
|
516
588
|
## [2.0.2](https://github.com/oslokommune/punkt/compare/v2.0.1...v2.0.2) (2023-03-07)
|
|
517
589
|
|
|
518
|
-
|
|
519
590
|
### Bug Fixes
|
|
520
591
|
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
592
|
+
- **react:** Rett feil dependencies i React-pakken ([#698](https://github.com/oslokommune/punkt/issues/698)) ([0fc3093](https://github.com/oslokommune/punkt/commit/0fc309338bb511e119e2982cd04ef8a0a9fae09a))
|
|
524
593
|
|
|
525
594
|
## [2.0.1](https://github.com/oslokommune/punkt/compare/v2.0.0...v2.0.1) (2023-03-07)
|
|
526
595
|
|
|
527
|
-
|
|
528
596
|
### Bug Fixes
|
|
529
597
|
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
598
|
+
- Endre flat-button i alert ([#697](https://github.com/oslokommune/punkt/issues/697)) ([c98aa2a](https://github.com/oslokommune/punkt/commit/c98aa2aa647a8c200013e2770ba5b0e7d17c7a26))
|
|
533
599
|
|
|
534
600
|
## [2.0.0](https://github.com/oslokommune/punkt/compare/v1.0.2...v2.0.0) (2023-03-07)
|
|
535
601
|
|
|
536
|
-
|
|
537
602
|
### ⚠ BREAKING CHANGES
|
|
538
603
|
|
|
539
|
-
|
|
540
|
-
Buttons har fått ny styling og buttonskins har gått fra 5 til 3:
|
|
604
|
+
- #595 Button (#696)
|
|
605
|
+
Buttons har fått ny styling og buttonskins har gått fra 5 til 3:
|
|
541
606
|
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
607
|
+
* Primary: Ny styling
|
|
608
|
+
* Secondary: Ny styling
|
|
609
|
+
* Tertiary: **breaking** har fått stylingen til flat-button
|
|
545
610
|
|
|
546
|
-
|
|
547
|
-
|
|
611
|
+
* Flat: **breaking** fjernet
|
|
612
|
+
* Primary-confirm: **breaking** fjernet
|
|
548
613
|
|
|
549
614
|
**Migrering**:
|
|
615
|
+
|
|
550
616
|
- Endre Flat til Tertiary
|
|
551
617
|
- Endre gammel Tertiary til Secondary (du kan overstyre fargen selv)
|
|
552
618
|
|
|
553
619
|
### Features
|
|
554
620
|
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
621
|
+
- [#595](https://github.com/oslokommune/punkt/issues/595) Button ([#696](https://github.com/oslokommune/punkt/issues/696)) ([8870dd7](https://github.com/oslokommune/punkt/commit/8870dd732251160f06d59691064045b111c19ed7))
|
|
558
622
|
|
|
559
623
|
## [1.0.1](https://github.com/oslokommune/punkt/compare/v1.0.0...v1.0.1) (2023-02-27)
|
|
560
624
|
|
|
561
|
-
|
|
562
625
|
### Bug Fixes
|
|
563
626
|
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
627
|
+
- Rette opp i changelogs etter overgang til v1 ([#680](https://github.com/oslokommune/punkt/issues/680)) ([8136c6d](https://github.com/oslokommune/punkt/commit/8136c6db1fa405394fbd886847f253a0b46b8c49))
|
|
567
628
|
|
|
568
629
|
## [1.0.0](https://github.com/oslokommune/punkt/compare/v0.23.0...v1.0.0) (2023-02-27)
|
|
569
630
|
|
|
@@ -571,29 +632,20 @@ Helt nytt oppsett for Punkt v1, nytt AWS-oppsett, nye domener, med å ta i bruke
|
|
|
571
632
|
|
|
572
633
|
**react** Skrive om til å bruke vite.js, sette opp dev-app som publiseres, forbedre NPM pakken.
|
|
573
634
|
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
635
|
# [0.23.0](https://github.com/oslokommune/punkt/compare/v0.22.4...v0.23.0) (2023-02-27)
|
|
579
636
|
|
|
580
|
-
|
|
581
|
-
* build!: Publisere Punkt v1 igjen :rocket: (#678) ([cb3bf71](https://github.com/oslokommune/punkt/commit/cb3bf7104db6507a5ce4d45982141c1c2eba3659)), closes [#678](https://github.com/oslokommune/punkt/issues/678)
|
|
582
|
-
|
|
637
|
+
- build!: Publisere Punkt v1 igjen :rocket: (#678) ([cb3bf71](https://github.com/oslokommune/punkt/commit/cb3bf7104db6507a5ce4d45982141c1c2eba3659)), closes [#678](https://github.com/oslokommune/punkt/issues/678)
|
|
583
638
|
|
|
584
639
|
## BREAKING CHANGES
|
|
585
640
|
|
|
586
|
-
|
|
587
|
-
|
|
641
|
+
- Helt nytt oppsett for Punkt v1, nytt AWS-oppsett, nye domener, med å ta i bruke lerna for monorepo, nye GH workflow, og ny måte å kjøre oppgaver på.
|
|
588
642
|
|
|
589
643
|
## [0.22.4](https://github.com/oslokommune/punkt/compare/v0.22.3...v0.22.4) (2023-02-27)
|
|
590
644
|
|
|
591
645
|
**Note:** Version bump only for package @oslokommune/punkt-react
|
|
592
646
|
|
|
593
|
-
|
|
594
647
|
## [0.22.2](https://github.com/oslokommune/punkt/compare/v0.22.1...v0.22.2) (2023-02-26)
|
|
595
648
|
|
|
596
|
-
|
|
597
649
|
### Bug Fixes
|
|
598
650
|
|
|
599
|
-
|
|
651
|
+
- **react:** Sett opp react-lib og publiseringsflyter ([#660](https://github.com/oslokommune/punkt/issues/660)) ([1bb89c7](https://github.com/oslokommune/punkt/commit/1bb89c764e1fd0e100cd7c2d6d820d958273609e))
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oslokommune/punkt-react",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.20",
|
|
4
4
|
"description": "React komponentbibliotek til Punkt, et designsystem laget av Oslo Origo",
|
|
5
5
|
"homepage": "https://punkt.oslo.kommune.no",
|
|
6
6
|
"author": "Team Designsystem, Oslo Origo",
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"test": "react-scripts test --env=jsdom"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@oslokommune/punkt-assets": "^5.1.
|
|
35
|
-
"@oslokommune/punkt-css": "^5.1.
|
|
34
|
+
"@oslokommune/punkt-assets": "^5.1.19",
|
|
35
|
+
"@oslokommune/punkt-css": "^5.1.19",
|
|
36
36
|
"@testing-library/jest-dom": "^5.16.5",
|
|
37
37
|
"@testing-library/react": "^14.0.0",
|
|
38
38
|
"@testing-library/user-event": "^14.4.3",
|
|
@@ -90,5 +90,5 @@
|
|
|
90
90
|
"url": "https://github.com/oslokommune/punkt/issues"
|
|
91
91
|
},
|
|
92
92
|
"license": "MIT",
|
|
93
|
-
"gitHead": "
|
|
93
|
+
"gitHead": "daf8015afaa547afd0a37583a5ea2be7599d0277"
|
|
94
94
|
}
|
|
@@ -57,64 +57,64 @@ describe('PktFooterSimple', () => {
|
|
|
57
57
|
|
|
58
58
|
|
|
59
59
|
describe('basic rendering', () => {
|
|
60
|
-
|
|
61
|
-
|
|
60
|
+
it('should render columns and social links', () => {
|
|
61
|
+
render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />)
|
|
62
62
|
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
const columnOneElement = screen.getByText('Column One')
|
|
64
|
+
expect(columnOneElement).toBeInTheDocument()
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
const columnOneLink1Element = screen.getByText('Link 1')
|
|
67
|
+
expect(columnOneLink1Element).toHaveAttribute('href', 'https://example.com')
|
|
68
|
+
expect(columnOneLink1Element).toHaveClass('pkt-link--external')
|
|
69
69
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
const columnOneLink2Element = screen.getByText('Link 2')
|
|
71
|
+
expect(columnOneLink2Element).toHaveAttribute('href', 'https://example.com')
|
|
72
|
+
expect(columnOneLink2Element).not.toHaveClass('pkt-link--external')
|
|
73
73
|
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
const columnOneTextElement = screen.getByText('Column One Text')
|
|
75
|
+
expect(columnOneTextElement).toBeInTheDocument()
|
|
76
76
|
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
const columnTwoElement = screen.getByText('Column Two')
|
|
78
|
+
expect(columnTwoElement).toBeInTheDocument()
|
|
79
79
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
80
|
+
const columnTwoLink3Element = screen.getByText('Link 3')
|
|
81
|
+
expect(columnTwoLink3Element).toHaveAttribute('href', 'https://example.com')
|
|
82
|
+
expect(columnTwoLink3Element).toHaveClass('pkt-link--external')
|
|
83
83
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
84
|
+
const columnTwoLink4Element = screen.getByText('Link 4')
|
|
85
|
+
expect(columnTwoLink4Element).toHaveAttribute('href', 'https://example.com')
|
|
86
|
+
expect(columnTwoLink4Element).not.toHaveClass('pkt-link--external')
|
|
87
87
|
|
|
88
|
-
|
|
89
|
-
|
|
88
|
+
const columnTwoTextElement = screen.getByText('Column Two Text')
|
|
89
|
+
expect(columnTwoTextElement).toBeInTheDocument()
|
|
90
90
|
|
|
91
|
-
|
|
92
|
-
|
|
91
|
+
const personvernLink = screen.getByText('Personvern og informasjonskapsler');
|
|
92
|
+
expect(personvernLink).toBeInTheDocument();
|
|
93
93
|
|
|
94
|
-
|
|
95
|
-
|
|
94
|
+
const tilgjengelighetLink = screen.getByText('Tilgjengelighet');
|
|
95
|
+
expect(tilgjengelighetLink).toBeInTheDocument();
|
|
96
96
|
|
|
97
|
-
|
|
98
|
-
|
|
97
|
+
const socialLinksElement = screen.getByLabelText('standard lenker')
|
|
98
|
+
expect(socialLinksElement).toBeInTheDocument()
|
|
99
99
|
|
|
100
|
-
|
|
101
|
-
|
|
100
|
+
const socialLinksFacebookElement = screen.getByLabelText('til facebook')
|
|
101
|
+
expect(socialLinksFacebookElement).toHaveAttribute('href', 'https://example.com')
|
|
102
102
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
const socialLinksTwitterElement = screen.getByLabelText('til twitter')
|
|
104
|
+
expect(socialLinksTwitterElement).toHaveAttribute('href', 'https://example.com')
|
|
105
|
+
})
|
|
106
106
|
})
|
|
107
107
|
|
|
108
108
|
describe('accessibility', () => {
|
|
109
109
|
it('renders with no wcag errors with axe', async () => {
|
|
110
|
-
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks}/>);
|
|
110
|
+
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />);
|
|
111
111
|
const results = await axe(container);
|
|
112
112
|
expect(results).toHaveNoViolations();
|
|
113
113
|
})
|
|
114
114
|
})
|
|
115
115
|
|
|
116
116
|
describe('snapshot', () => {
|
|
117
|
-
it('renders correctly', () => {
|
|
117
|
+
it('renders correctly with all props', () => {
|
|
118
118
|
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />);
|
|
119
119
|
expect(container).toMatchSnapshot();
|
|
120
120
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
3
|
+
exports[`PktFooterSimple snapshot renders correctly with all props 1`] = `
|
|
4
4
|
<div>
|
|
5
5
|
<footer
|
|
6
6
|
class="pkt-footer"
|
|
@@ -34,15 +34,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
34
34
|
<a
|
|
35
35
|
class="pkt-footer__link pkt-link--external"
|
|
36
36
|
href="https://example.com"
|
|
37
|
+
target="_self"
|
|
37
38
|
>
|
|
38
|
-
<svg
|
|
39
|
-
class="pkt-footer__link-icon"
|
|
40
|
-
viewBox="0 0 32 32"
|
|
41
|
-
>
|
|
42
|
-
<use
|
|
43
|
-
href="#chevron-right"
|
|
44
|
-
/>
|
|
45
|
-
</svg>
|
|
46
39
|
Link 1
|
|
47
40
|
</a>
|
|
48
41
|
</li>
|
|
@@ -52,15 +45,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
52
45
|
<a
|
|
53
46
|
class="pkt-footer__link "
|
|
54
47
|
href="https://example.com"
|
|
48
|
+
target="_self"
|
|
55
49
|
>
|
|
56
|
-
<svg
|
|
57
|
-
class="pkt-footer__link-icon"
|
|
58
|
-
viewBox="0 0 32 32"
|
|
59
|
-
>
|
|
60
|
-
<use
|
|
61
|
-
href="#chevron-right"
|
|
62
|
-
/>
|
|
63
|
-
</svg>
|
|
64
50
|
Link 2
|
|
65
51
|
</a>
|
|
66
52
|
</li>
|
|
@@ -88,15 +74,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
88
74
|
<a
|
|
89
75
|
class="pkt-footer__link pkt-link--external"
|
|
90
76
|
href="https://example.com"
|
|
77
|
+
target="_self"
|
|
91
78
|
>
|
|
92
|
-
<svg
|
|
93
|
-
class="pkt-footer__link-icon"
|
|
94
|
-
viewBox="0 0 32 32"
|
|
95
|
-
>
|
|
96
|
-
<use
|
|
97
|
-
href="#chevron-right"
|
|
98
|
-
/>
|
|
99
|
-
</svg>
|
|
100
79
|
Link 3
|
|
101
80
|
</a>
|
|
102
81
|
</li>
|
|
@@ -106,15 +85,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
106
85
|
<a
|
|
107
86
|
class="pkt-footer__link "
|
|
108
87
|
href="https://example.com"
|
|
88
|
+
target="_self"
|
|
109
89
|
>
|
|
110
|
-
<svg
|
|
111
|
-
class="pkt-footer__link-icon"
|
|
112
|
-
viewBox="0 0 32 32"
|
|
113
|
-
>
|
|
114
|
-
<use
|
|
115
|
-
href="#chevron-right"
|
|
116
|
-
/>
|
|
117
|
-
</svg>
|
|
118
90
|
Link 4
|
|
119
91
|
</a>
|
|
120
92
|
</li>
|
|
@@ -138,14 +110,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
138
110
|
class="pkt-footer__link"
|
|
139
111
|
href="https://www.oslo.kommune.no/personvern-og-informasjonskapsler/"
|
|
140
112
|
>
|
|
141
|
-
<svg
|
|
142
|
-
class="pkt-footer__link-icon"
|
|
143
|
-
viewBox="0 0 32 32"
|
|
144
|
-
>
|
|
145
|
-
<use
|
|
146
|
-
href="#chevron-right"
|
|
147
|
-
/>
|
|
148
|
-
</svg>
|
|
149
113
|
Personvern og informasjonskapsler
|
|
150
114
|
</a>
|
|
151
115
|
</li>
|
|
@@ -156,14 +120,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
156
120
|
class="pkt-footer__link"
|
|
157
121
|
href="https://www.oslo.kommune.no/tilgjengelighet/"
|
|
158
122
|
>
|
|
159
|
-
<svg
|
|
160
|
-
class="pkt-footer__link-icon"
|
|
161
|
-
viewBox="0 0 32 32"
|
|
162
|
-
>
|
|
163
|
-
<use
|
|
164
|
-
href="#chevron-right"
|
|
165
|
-
/>
|
|
166
|
-
</svg>
|
|
167
123
|
Tilgjengelighet
|
|
168
124
|
</a>
|
|
169
125
|
</li>
|
|
@@ -184,32 +140,14 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
184
140
|
aria-label="til facebook"
|
|
185
141
|
class="pkt-footer__social-icon-link"
|
|
186
142
|
href="https://example.com"
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
aria-hidden="true"
|
|
190
|
-
class="pkt-footer__social-icon"
|
|
191
|
-
viewBox="0 0 32 32"
|
|
192
|
-
>
|
|
193
|
-
<use
|
|
194
|
-
href="#facebook"
|
|
195
|
-
/>
|
|
196
|
-
</svg>
|
|
197
|
-
</a>
|
|
143
|
+
target="_self"
|
|
144
|
+
/>
|
|
198
145
|
<a
|
|
199
146
|
aria-label="til twitter"
|
|
200
147
|
class="pkt-footer__social-icon-link"
|
|
201
148
|
href="https://example.com"
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
aria-hidden="true"
|
|
205
|
-
class="pkt-footer__social-icon"
|
|
206
|
-
viewBox="0 0 32 32"
|
|
207
|
-
>
|
|
208
|
-
<use
|
|
209
|
-
href="#twitter"
|
|
210
|
-
/>
|
|
211
|
-
</svg>
|
|
212
|
-
</a>
|
|
149
|
+
target="_self"
|
|
150
|
+
/>
|
|
213
151
|
</div>
|
|
214
152
|
</div>
|
|
215
153
|
</div>
|
|
@@ -58,7 +58,7 @@ describe('PktFooterSimple', () => {
|
|
|
58
58
|
})
|
|
59
59
|
|
|
60
60
|
describe('snapshot', () => {
|
|
61
|
-
it('renders correctly', () => {
|
|
61
|
+
it('renders correctly with all props', () => {
|
|
62
62
|
const { container } = render(<PktFooterSimple links={links} />);
|
|
63
63
|
expect(container).toMatchSnapshot();
|
|
64
64
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
3
|
+
exports[`PktFooterSimple snapshot renders correctly with all props 1`] = `
|
|
4
4
|
<div>
|
|
5
5
|
<footer
|
|
6
6
|
class="pkt-footer-simple"
|
|
@@ -18,15 +18,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
18
18
|
<a
|
|
19
19
|
class="pkt-footer-simple__link "
|
|
20
20
|
href="https://www.example.com"
|
|
21
|
+
target="_self"
|
|
21
22
|
>
|
|
22
|
-
<svg
|
|
23
|
-
class="pkt-footer-simple__link-icon"
|
|
24
|
-
viewBox="0 0 32 32"
|
|
25
|
-
>
|
|
26
|
-
<use
|
|
27
|
-
href="#chevron-right"
|
|
28
|
-
/>
|
|
29
|
-
</svg>
|
|
30
23
|
Example Link 1
|
|
31
24
|
</a>
|
|
32
25
|
</li>
|
|
@@ -36,15 +29,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
36
29
|
<a
|
|
37
30
|
class="pkt-footer-simple__link "
|
|
38
31
|
href="https://www.example.com"
|
|
32
|
+
target="_self"
|
|
39
33
|
>
|
|
40
|
-
<svg
|
|
41
|
-
class="pkt-footer-simple__link-icon"
|
|
42
|
-
viewBox="0 0 32 32"
|
|
43
|
-
>
|
|
44
|
-
<use
|
|
45
|
-
href="#chevron-right"
|
|
46
|
-
/>
|
|
47
|
-
</svg>
|
|
48
34
|
Example Link 2
|
|
49
35
|
</a>
|
|
50
36
|
</li>
|
|
@@ -54,15 +40,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
54
40
|
<a
|
|
55
41
|
class="pkt-footer-simple__link "
|
|
56
42
|
href="https://www.example.com"
|
|
43
|
+
target="_self"
|
|
57
44
|
>
|
|
58
|
-
<svg
|
|
59
|
-
class="pkt-footer-simple__link-icon"
|
|
60
|
-
viewBox="0 0 32 32"
|
|
61
|
-
>
|
|
62
|
-
<use
|
|
63
|
-
href="#chevron-right"
|
|
64
|
-
/>
|
|
65
|
-
</svg>
|
|
66
45
|
Example Link 3
|
|
67
46
|
</a>
|
|
68
47
|
</li>
|
|
@@ -73,14 +52,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
73
52
|
class="pkt-footer-simple__link"
|
|
74
53
|
href="https://www.oslo.kommune.no/personvern-og-informasjonskapsler/"
|
|
75
54
|
>
|
|
76
|
-
<svg
|
|
77
|
-
class="pkt-footer-simple__link-icon"
|
|
78
|
-
viewBox="0 0 32 32"
|
|
79
|
-
>
|
|
80
|
-
<use
|
|
81
|
-
href="#chevron-right"
|
|
82
|
-
/>
|
|
83
|
-
</svg>
|
|
84
55
|
Personvern og informasjonskapsler
|
|
85
56
|
</a>
|
|
86
57
|
</li>
|
|
@@ -91,14 +62,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
91
62
|
class="pkt-footer-simple__link"
|
|
92
63
|
href="https://www.oslo.kommune.no/tilgjengelighet/"
|
|
93
64
|
>
|
|
94
|
-
<svg
|
|
95
|
-
class="pkt-footer-simple__link-icon"
|
|
96
|
-
viewBox="0 0 32 32"
|
|
97
|
-
>
|
|
98
|
-
<use
|
|
99
|
-
href="#chevron-right"
|
|
100
|
-
/>
|
|
101
|
-
</svg>
|
|
102
65
|
Tilgjengelighet
|
|
103
66
|
</a>
|
|
104
67
|
</li>
|
|
@@ -66,7 +66,7 @@ describe('PktLinkCard', () => {
|
|
|
66
66
|
})
|
|
67
67
|
|
|
68
68
|
describe('snapshots', () => {
|
|
69
|
-
it('renders correctly as fragment', () => {
|
|
69
|
+
it('renders correctly as fragment with props', () => {
|
|
70
70
|
const { asFragment } = render(
|
|
71
71
|
<PktLinkCard title="Link title" href="/example">
|
|
72
72
|
Link content
|
|
@@ -1,24 +1,17 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktLinkCard snapshots renders correctly as fragment 1`] = `
|
|
3
|
+
exports[`PktLinkCard snapshots renders correctly as fragment with props 1`] = `
|
|
4
4
|
<DocumentFragment>
|
|
5
5
|
<a
|
|
6
|
-
class="pkt-linkcard pkt-link pkt-linkcard"
|
|
6
|
+
class="pkt-linkcard pkt-link pkt-linkcard pkt-linkcard--normal"
|
|
7
7
|
href="/example"
|
|
8
|
+
target="_self"
|
|
8
9
|
>
|
|
9
|
-
<svg
|
|
10
|
-
class="pkt-link__icon"
|
|
11
|
-
viewBox="0 0 32 32"
|
|
12
|
-
>
|
|
13
|
-
<use
|
|
14
|
-
href="#user"
|
|
15
|
-
/>
|
|
16
|
-
</svg>
|
|
17
10
|
<div
|
|
18
11
|
class="pkt-linkcard__content"
|
|
19
12
|
>
|
|
20
13
|
<div
|
|
21
|
-
class="pkt-linkcard__title"
|
|
14
|
+
class="pkt-linkcard__title "
|
|
22
15
|
>
|
|
23
16
|
Link title
|
|
24
17
|
</div>
|
|
@@ -71,9 +71,9 @@ describe('PktTag', () => {
|
|
|
71
71
|
});
|
|
72
72
|
|
|
73
73
|
describe('snapshot', () => {
|
|
74
|
-
it('renders correctly', () => {
|
|
75
|
-
|
|
76
|
-
|
|
74
|
+
it('renders correctly with all props', () => {
|
|
75
|
+
const { container } = render(<PktTag skin="red" size="small" iconName="user" closeTag={true}>Tag</PktTag>);
|
|
76
|
+
expect(container).toMatchSnapshot();
|
|
77
77
|
})
|
|
78
|
-
|
|
78
|
+
})
|
|
79
79
|
});
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktTag snapshot renders correctly 1`] = `
|
|
3
|
+
exports[`PktTag snapshot renders correctly with all props 1`] = `
|
|
4
4
|
<div>
|
|
5
5
|
<button
|
|
6
6
|
aria-label="close"
|
|
7
|
-
class="pkt-tag pkt-btn pkt-btn--tertiary pkt-tag--small pkt-tag--red pkt-btn--icons-right-and-left"
|
|
7
|
+
class="pkt-tag pkt-btn pkt-btn--tertiary pkt-tag--small pkt-tag--red pkt-tag--normal-text pkt-btn--icons-right-and-left"
|
|
8
8
|
type="button"
|
|
9
9
|
>
|
|
10
10
|
<span
|