@helsenorge/datepicker 8.6.0-beta.0 → 8.6.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 CHANGED
@@ -1,3 +1,11 @@
1
+ ## [8.5.1](https://github.com/helsenorge/designsystem/branchCompare?baseVersion=GTv8.5.0&targetVersion=GTv8.5.1) (2024-09-25)
2
+
3
+ ### Bug Fixes
4
+
5
+ - progressbar leses opp av skjermlesere
6
+ ([550e7ac](https://github.com/helsenorge/designsystem/commit/550e7acfbb4687d946f36a7dad9e284614aee6a4)), closes
7
+ [#328018](https://github.com/helsenorge/designsystem/issues/328018)
8
+
1
9
  ## [8.5.0](https://github.com/helsenorge/designsystem/branchCompare?baseVersion=GTv8.4.0&targetVersion=GTv8.5.0) (2024-09-23)
2
10
 
3
11
  ### Features
@@ -1773,12 +1781,12 @@ Dette er fordi vi skal kunne dynamisk importere alt som ligger i Icons, så da b
1773
1781
 
1774
1782
  ### Bug Fixes
1775
1783
 
1776
- - økt kontrast på understreking av lenker
1777
- ([50b7fa4](https://github.com/helsenorge/designsystem/commit/50b7fa47fb44cb7d75fb877bd53e2309b35e1e21)), closes
1778
- [#229049](https://github.com/helsenorge/designsystem/issues/229049)
1779
1784
  - panel har avstand fra tittel til badge
1780
1785
  ([09034c4](https://github.com/helsenorge/designsystem/commit/09034c4844408c7cfe8f65d7a1a0d82a7828c2ef)), closes
1781
1786
  [#282359](https://github.com/helsenorge/designsystem/issues/282359)
1787
+ - økt kontrast på understreking av lenker
1788
+ ([50b7fa4](https://github.com/helsenorge/designsystem/commit/50b7fa47fb44cb7d75fb877bd53e2309b35e1e21)), closes
1789
+ [#229049](https://github.com/helsenorge/designsystem/issues/229049)
1782
1790
 
1783
1791
  ## [1.2.2](https://github.com/helsenorge/designsystem/branchCompare?baseVersion=GTv1.2.1&targetVersion=GTv1.2.2) (2022-08-31)
1784
1792
 
@@ -1,6 +1,7 @@
1
1
  import React from 'react';
2
2
  import { Locale } from 'date-fns';
3
3
  import { DayPickerSingleProps } from 'react-day-picker';
4
+ import { PopOverVariant } from '@helsenorge/designsystem-react/components/PopOver';
4
5
  export type DateFormat = 'dd.MM.yyyy';
5
6
  export interface DatePickerProps extends Pick<React.InputHTMLAttributes<HTMLInputElement>, 'name' | 'aria-describedby' | 'onBlur' | 'autoComplete'>, Pick<DayPickerSingleProps, 'dir' | 'initialFocus'> {
6
7
  /** Adds custom classes to the element. */
@@ -43,6 +44,8 @@ export interface DatePickerProps extends Pick<React.InputHTMLAttributes<HTMLInpu
43
44
  onDatePopupClosed?: (date: Date | string | undefined) => void;
44
45
  /** Sets the data-testid attribute. */
45
46
  testId?: string;
47
+ /** Determines the placement of the DatePicker popup. Default: automatic positioning. */
48
+ variant?: keyof typeof PopOverVariant;
46
49
  /** Overrides the default z-index of DatePicker */
47
50
  zIndex?: number;
48
51
  }
@@ -1,9 +1,11 @@
1
1
  import React from 'react';
2
2
  import { DayPickerSingleProps } from 'react-day-picker';
3
+ import { PopOverVariant } from '@helsenorge/designsystem-react/components/PopOver';
3
4
  interface DatePickerPopupProps extends Pick<DayPickerSingleProps, 'dir' | 'disabled' | 'footer' | 'fromDate' | 'initialFocus' | 'locale' | 'month' | 'selected' | 'onSelect' | 'onMonthChange' | 'toDate'> {
4
5
  datepickerWrapperRef: React.RefObject<HTMLDivElement>;
5
6
  inputRef: React.RefObject<HTMLInputElement>;
6
7
  testId?: string;
8
+ variant: keyof typeof PopOverVariant;
7
9
  zIndex?: number;
8
10
  }
9
11
  declare const DatePickerPopup: React.FC<DatePickerPopupProps>;
@@ -1,6 +1,7 @@
1
1
  import React from 'react';
2
2
  export type TimeUnit = 'hours' | 'minutes';
3
3
  export interface DateTimeProps extends Pick<React.InputHTMLAttributes<HTMLInputElement>, 'name' | 'aria-describedby' | 'aria-labelledby' | 'onChange' | 'disabled' | 'autoComplete'> {
4
+ /** Default value that is set on the input field */
4
5
  defaultValue?: number;
5
6
  /** Activates Error style for the input */
6
7
  error?: boolean;
@@ -8,12 +9,14 @@ export interface DateTimeProps extends Pick<React.InputHTMLAttributes<HTMLInputE
8
9
  errorText?: string;
9
10
  /** Error text id */
10
11
  errorTextId?: string;
12
+ /** input id of the checkbox */
13
+ inputId?: string;
11
14
  /** Label of the input */
12
15
  label?: React.ReactNode;
13
16
  /** Sets the unit of time for the input field */
14
17
  timeUnit: TimeUnit;
15
- /** input id of the checkbox */
16
- inputId?: string;
18
+ /** Value that is set on the input field */
19
+ value?: number;
17
20
  /** Sets the data-testid attribute. */
18
21
  testId?: string;
19
22
  }