@oslokommune/punkt-react 14.2.0 → 14.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/index.d.ts +13 -6
- package/dist/punkt-react.es.js +2153 -2137
- package/dist/punkt-react.umd.js +220 -218
- package/package.json +3 -3
- package/src/components/header/HeaderService.tsx +8 -6
- package/src/components/header/types.ts +23 -6
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,24 @@ og skriver commits ca etter [Conventional Commits](https://conventionalcommits.o
|
|
|
5
5
|
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
+
## [14.3.0](https://github.com/oslokommune/punkt/compare/14.2.0...14.3.0) (2026-02-04)
|
|
9
|
+
|
|
10
|
+
### ⚠ BREAKING CHANGES
|
|
11
|
+
Ingen
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
* Header nye props slotMenuVariant og slotMenuText (#3226). Pluss flyttet en del typer til shared-types
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
Ingen
|
|
19
|
+
|
|
20
|
+
### Chores
|
|
21
|
+
Ingen
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
|
|
8
26
|
## [14.2.0](https://github.com/oslokommune/punkt/compare/14.1.1...14.2.0) (2026-02-04)
|
|
9
27
|
|
|
10
28
|
### ⚠ BREAKING CHANGES
|
package/dist/index.d.ts
CHANGED
|
@@ -37,8 +37,13 @@ import { TAlertSkin } from '../../../../../shared-types';
|
|
|
37
37
|
import { TAriaLive } from '../../../../../shared-types';
|
|
38
38
|
import { TCardSkin } from '../../../../../shared-types';
|
|
39
39
|
import { TextareaHTMLAttributes } from 'react';
|
|
40
|
+
import { THeaderMenu } from '../../../../../shared-types';
|
|
41
|
+
import { THeaderPosition } from '../../../../../shared-types';
|
|
42
|
+
import { THeaderScrollBehavior } from '../../../../../shared-types';
|
|
40
43
|
import { TLayout } from '../../../../../shared-types';
|
|
44
|
+
import { TLogOutButtonPlacement } from '../../../../../shared-types';
|
|
41
45
|
import { TMessageboxSkin } from '../../../../../shared-types';
|
|
46
|
+
import { TSlotMenuVariant } from '../../../../../shared-types';
|
|
42
47
|
|
|
43
48
|
declare interface BasePktTagProps {
|
|
44
49
|
skin?: 'blue' | 'blue-light' | 'blue-dark' | 'green' | 'red' | 'beige' | 'yellow' | 'grey' | 'gray';
|
|
@@ -323,7 +328,7 @@ export declare interface IPktHeader {
|
|
|
323
328
|
/** @deprecated userOptions is no longer available. Use userMenu instead. */
|
|
324
329
|
userOptions?: UserMenuItem[];
|
|
325
330
|
/** Where to show the logout button: 'userMenu', 'header', 'both', or 'none' */
|
|
326
|
-
logOutButtonPlacement?:
|
|
331
|
+
logOutButtonPlacement?: TLogOutButtonPlacement;
|
|
327
332
|
/** Callback when user clicks logout */
|
|
328
333
|
logOut?: () => void;
|
|
329
334
|
/** Show search input in the header */
|
|
@@ -341,11 +346,15 @@ export declare interface IPktHeader {
|
|
|
341
346
|
/** Custom breakpoint for tablet responsive behavior (interaction pattern) in pixels. Default: 1280 */
|
|
342
347
|
tabletBreakpoint?: number;
|
|
343
348
|
/** Which menu is initially open */
|
|
344
|
-
openedMenu?:
|
|
349
|
+
openedMenu?: THeaderMenu;
|
|
345
350
|
/** Header position. 'fixed' fixes to top of viewport, 'relative' follows document flow. Default: 'fixed' */
|
|
346
|
-
position?:
|
|
351
|
+
position?: THeaderPosition;
|
|
347
352
|
/** Scroll behavior. 'hide' hides header on scroll down, 'none' keeps it visible. Default: 'hide' */
|
|
348
|
-
scrollBehavior?:
|
|
353
|
+
scrollBehavior?: THeaderScrollBehavior;
|
|
354
|
+
/** Variant for the slot menu button in tablet/mobile mode. Default: 'icon-only' */
|
|
355
|
+
slotMenuVariant?: TSlotMenuVariant;
|
|
356
|
+
/** Text for the slot menu button in tablet/mobile mode. Default: 'Meny' */
|
|
357
|
+
slotMenuText?: string;
|
|
349
358
|
}
|
|
350
359
|
|
|
351
360
|
export declare type IPktHeaderService = IPktHeader;
|
|
@@ -873,8 +882,6 @@ declare type TPktAccordionSkin = TAccordionSkin;
|
|
|
873
882
|
|
|
874
883
|
declare type TPktAccordionSkin_2 = TAccordionSkin;
|
|
875
884
|
|
|
876
|
-
declare type TPktHeaderServiceMenu = 'none' | 'slot' | 'search' | 'user';
|
|
877
|
-
|
|
878
885
|
declare type TSkin = 'blue' | 'green' | 'red' | 'beige' | 'yellow' | 'grey' | 'gray' | 'blue-light';
|
|
879
886
|
|
|
880
887
|
declare type TSkin_2 = IPktTag['skin'];
|