@oslokommune/punkt-react 14.5.0 → 14.5.2

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.
Files changed (70) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/dist/index.d.ts +16 -19
  3. package/dist/punkt-react.es.js +1308 -1382
  4. package/dist/punkt-react.umd.js +154 -182
  5. package/package.json +9 -3
  6. package/src/components/accordion/Accordion.test.tsx +4 -2
  7. package/src/components/accordion/Accordion.tsx +1 -1
  8. package/src/components/accordion/AccordionItem.tsx +3 -3
  9. package/src/components/alert/Alert.test.tsx +4 -5
  10. package/src/components/alert/Alert.tsx +5 -4
  11. package/src/components/backlink/BackLink.tsx +3 -3
  12. package/src/components/breadcrumbs/Breadcrumbs.test.tsx +4 -1
  13. package/src/components/breadcrumbs/Breadcrumbs.tsx +3 -5
  14. package/src/components/button/Button.test.tsx +5 -3
  15. package/src/components/button/Button.tsx +1 -2
  16. package/src/components/card/Card.tsx +6 -3
  17. package/src/components/checkbox/Checkbox.test.tsx +1 -1
  18. package/src/components/checkbox/Checkbox.tsx +10 -2
  19. package/src/components/combobox/Combobox.tsx +9 -8
  20. package/src/components/consent/Consent.tsx +3 -3
  21. package/src/components/datepicker/Datepicker.test.tsx +3 -1
  22. package/src/components/datepicker/Datepicker.tsx +11 -8
  23. package/src/components/footer/Footer.test.tsx +1 -1
  24. package/src/components/footer/Footer.tsx +3 -3
  25. package/src/components/footerSimple/FooterSimple.test.tsx +1 -1
  26. package/src/components/footerSimple/FooterSimple.tsx +3 -3
  27. package/src/components/header/Header.test.tsx +0 -1
  28. package/src/components/header/Header.tsx +1 -0
  29. package/src/components/header/HeaderService.test.tsx +2 -2
  30. package/src/components/header/HeaderService.tsx +34 -15
  31. package/src/components/header/types.ts +8 -8
  32. package/src/components/headerUserMenu/UserMenu.test.tsx +3 -3
  33. package/src/components/headerUserMenu/UserMenu.tsx +6 -2
  34. package/src/components/heading/Heading.test.tsx +4 -2
  35. package/src/components/heading/Heading.tsx +6 -5
  36. package/src/components/helptext/Helptext.tsx +3 -2
  37. package/src/components/icon/Icon.test.tsx +0 -1
  38. package/src/components/icon/Icon.tsx +4 -5
  39. package/src/components/input/Input.tsx +4 -5
  40. package/src/components/inputwrapper/InputWrapper.tsx +2 -1
  41. package/src/components/interfaces.ts +1 -1
  42. package/src/components/loader/Loader.test.tsx +0 -1
  43. package/src/components/loader/Loader.tsx +6 -4
  44. package/src/components/messagebox/Messagebox.tsx +1 -1
  45. package/src/components/modal/Modal.test.tsx +5 -6
  46. package/src/components/modal/Modal.tsx +4 -2
  47. package/src/components/progressbar/Progressbar.test.tsx +5 -3
  48. package/src/components/progressbar/Progressbar.tsx +6 -4
  49. package/src/components/radio/RadioButton.tsx +9 -3
  50. package/src/components/searchinput/SearchInput.test.tsx +3 -3
  51. package/src/components/searchinput/SearchInput.tsx +5 -1
  52. package/src/components/select/Select.test.tsx +0 -1
  53. package/src/components/select/Select.tsx +2 -0
  54. package/src/components/stepper/Step.tsx +2 -1
  55. package/src/components/stepper/Stepper.test.tsx +5 -3
  56. package/src/components/stepper/Stepper.tsx +5 -3
  57. package/src/components/table/Table.test.tsx +6 -6
  58. package/src/components/table/Table.tsx +2 -3
  59. package/src/components/table/TableBody.tsx +2 -3
  60. package/src/components/table/TableData.tsx +2 -3
  61. package/src/components/table/TableDataCell.tsx +2 -3
  62. package/src/components/table/TableHeader.tsx +2 -3
  63. package/src/components/table/TableHeaderCell.tsx +2 -3
  64. package/src/components/table/TableRow.tsx +2 -3
  65. package/src/components/tabs/TabItem.tsx +4 -4
  66. package/src/components/tabs/Tabs.test.tsx +5 -4
  67. package/src/components/tabs/Tabs.tsx +8 -5
  68. package/src/components/textarea/Textarea.test.tsx +0 -1
  69. package/src/components/textarea/Textarea.tsx +9 -4
  70. package/src/components/textinput/Textinput.tsx +11 -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.5.1](https://github.com/oslokommune/punkt/compare/14.5.0...14.5.1) (2026-02-06)
9
+
10
+ ### ⚠ BREAKING CHANGES
11
+ Ingen
12
+
13
+ ### Features
14
+ Ingen
15
+
16
+ ### Bug Fixes
17
+ * Reaktiver ESLint og fiks opp i lintefeil (#3231).
18
+
19
+
20
+ ### Chores
21
+ Ingen
22
+
23
+ ---
24
+
25
+
8
26
  ## [14.5.0](https://github.com/oslokommune/punkt/compare/14.4.0...14.5.0) (2026-02-05)
9
27
 
10
28
  ### ⚠ BREAKING CHANGES
package/dist/index.d.ts CHANGED
@@ -1,5 +1,3 @@
1
- /// <reference types="react" />
2
-
3
1
  import { AnchorHTMLAttributes } from 'react';
4
2
  import { Booleanish } from '../../../../../shared-types';
5
3
  import { ButtonHTMLAttributes } from 'react';
@@ -24,7 +22,6 @@ import { LegacyRef } from 'react';
24
22
  import { LinkHTMLAttributes } from 'react';
25
23
  import { MouseEvent as MouseEvent_2 } from 'react';
26
24
  import { MouseEventHandler } from 'react';
27
- import * as React_2 from 'react';
28
25
  import { ReactElement } from 'react';
29
26
  import { ReactNode } from 'react';
30
27
  import { RefAttributes } from 'react';
@@ -302,7 +299,7 @@ export declare interface IPktFooterSimple extends HTMLAttributes<HTMLDivElement>
302
299
  }
303
300
 
304
301
  export declare interface IPktHeader {
305
- children?: React.ReactNode;
302
+ children?: ReactNode;
306
303
  /** Additional CSS class name(s) to apply to the header */
307
304
  className?: string;
308
305
  /** Set dark mode on the header */
@@ -312,13 +309,13 @@ export declare interface IPktHeader {
312
309
  /** Link URL for the logo */
313
310
  logoLink?: string;
314
311
  /** Callback when logo is clicked */
315
- logoClick?: (event: React.MouseEvent) => void;
312
+ logoClick?: (event: MouseEvent_2) => void;
316
313
  /** Name of the service displayed in the header */
317
314
  serviceName?: string;
318
315
  /** Link URL for the service name */
319
316
  serviceLink?: string;
320
317
  /** Callback when service name is clicked */
321
- serviceClick?: (event: React.MouseEvent) => void;
318
+ serviceClick?: (event: MouseEvent_2) => void;
322
319
  /** Use compact header height */
323
320
  compact?: boolean;
324
321
  /** User object with name, shortname, and lastLoggedIn */
@@ -368,8 +365,8 @@ export declare interface IPktHeader {
368
365
  export declare type IPktHeaderService = IPktHeader;
369
366
 
370
367
  declare interface IPktHeading_2 extends IPktHeading {
371
- children?: default_2.ReactNode | default_2.ReactNode[];
372
- ref?: default_2.LegacyRef<HTMLElement>;
368
+ children?: ReactNode | ReactNode[];
369
+ ref?: LegacyRef<HTMLElement>;
373
370
  }
374
371
 
375
372
  declare interface IPktHelptextProps extends HTMLAttributes<HTMLDivElement> {
@@ -509,7 +506,7 @@ export declare interface IPktStep {
509
506
  /**
510
507
  * Step content. Can be a string, a React component or an element.
511
508
  */
512
- children?: React.ReactNode;
509
+ children?: ReactNode;
513
510
  /**
514
511
  * Additional class names
515
512
  */
@@ -694,23 +691,23 @@ declare interface ISearchInput extends ISearch {
694
691
 
695
692
  declare interface ITableBodyProps extends HTMLAttributes<HTMLTableSectionElement> {
696
693
  className?: string;
697
- children: React_2.ReactNode;
694
+ children: ReactNode;
698
695
  }
699
696
 
700
697
  declare interface ITableDataCellProps extends HTMLAttributes<HTMLTableCellElement> {
701
698
  className?: string;
702
- children?: React_2.ReactNode;
699
+ children?: ReactNode;
703
700
  dataLabel?: string;
704
701
  }
705
702
 
706
703
  declare interface ITableHeaderCellProps extends HTMLAttributes<HTMLTableCellElement> {
707
704
  className?: string;
708
- children: React_2.ReactNode;
705
+ children: ReactNode;
709
706
  }
710
707
 
711
708
  declare interface ITableHeaderProps extends HTMLAttributes<HTMLTableSectionElement> {
712
709
  className?: string;
713
- children: React_2.ReactNode;
710
+ children: ReactNode;
714
711
  }
715
712
 
716
713
  declare interface ITableProps extends HTMLAttributes<HTMLTableElement> {
@@ -718,12 +715,12 @@ declare interface ITableProps extends HTMLAttributes<HTMLTableElement> {
718
715
  skin?: 'basic' | 'zebra-blue';
719
716
  responsiveView?: boolean;
720
717
  className?: string;
721
- children: React_2.ReactNode;
718
+ children: ReactNode;
722
719
  }
723
720
 
724
721
  declare interface ITableRowProps extends HTMLAttributes<HTMLTableRowElement> {
725
722
  className?: string;
726
- children: React_2.ReactNode;
723
+ children: ReactNode;
727
724
  }
728
725
 
729
726
  declare interface Link {
@@ -794,8 +791,8 @@ export declare const PktIcon: FC<IPktIcon>;
794
791
  * @param {string} label - Label for the input
795
792
  * @param {string} id - Id for the input
796
793
  * @param {string} validationMessage - Validation message for the input
797
- * @param {React.InputHTMLAttributes<HTMLInputElement>} props - Other props to pass to the input
798
- * @returns {React.ReactElement} - React element
794
+ * @param {InputHTMLAttributes<HTMLInputElement>} props - Other props to pass to the input
795
+ * @returns {ReactElement} - React element
799
796
  *
800
797
  * @example
801
798
  * <Input label="First name" id="firstName" validationMessage="First name is required" />
@@ -848,9 +845,9 @@ export declare const PktTabs: ForwardRefExoticComponent<IPktTabs & RefAttributes
848
845
 
849
846
  export declare const PktTag: ForwardRefExoticComponent<(ButtonPktTagProps | SpanPktTagProps) & RefAttributes<HTMLButtonElement | HTMLSpanElement>>;
850
847
 
851
- export declare const PktTextarea: default_2.ForwardRefExoticComponent<IPktTextarea & default_2.RefAttributes<HTMLTextAreaElement>>;
848
+ export declare const PktTextarea: ForwardRefExoticComponent<IPktTextarea & RefAttributes<HTMLTextAreaElement>>;
852
849
 
853
- export declare const PktTextinput: default_2.ForwardRefExoticComponent<IPktTextinput & default_2.RefAttributes<HTMLInputElement>>;
850
+ export declare const PktTextinput: ForwardRefExoticComponent<IPktTextinput & RefAttributes<HTMLInputElement>>;
854
851
 
855
852
  /** Representing object for header components */
856
853
  declare interface Representing {