@rikstv/shared-components 3.2.7-alpha.2 → 3.2.7-alpha.4

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 (73) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/components/accordion/Accordion.d.ts +0 -1
  3. package/dist/components/alert/{Alert-C5wx7EXq.mjs → Alert-BiVxm3um.mjs} +6 -6
  4. package/dist/components/alert/Alert.d.ts +1 -4
  5. package/dist/components/breadcrumb/Breadcrumb.d.ts +0 -1
  6. package/dist/components/button/ArrowButton.d.ts +0 -1
  7. package/dist/components/button/BaseButton.d.ts +0 -1
  8. package/dist/components/button/BaseDecoratedButton.d.ts +0 -1
  9. package/dist/components/button/BaseLinkButton.d.ts +0 -1
  10. package/dist/components/button/Button.d.ts +0 -1
  11. package/dist/components/button/DecoratedButton.d.ts +0 -1
  12. package/dist/components/button/IconButton.d.ts +0 -1
  13. package/dist/components/button/button-shared.scss +5 -4
  14. package/dist/components/checkbox/BaseCheckbox.d.ts +0 -1
  15. package/dist/components/checkbox/Checkbox.d.ts +0 -1
  16. package/dist/components/checkbox/checkbox.scss +3 -3
  17. package/dist/components/core/Core.d.ts +0 -1
  18. package/dist/components/core/LightMode.d.ts +0 -1
  19. package/dist/components/core/RiksTV.d.ts +0 -1
  20. package/dist/components/core/Strim.d.ts +0 -1
  21. package/dist/components/core/docs/BrandVariables.d.ts +0 -1
  22. package/dist/components/core/docs/Colors.d.ts +0 -1
  23. package/dist/components/core/docs/Spacing.d.ts +0 -1
  24. package/dist/components/core/docs/Variables.d.ts +0 -1
  25. package/dist/components/core/docs/componets/BrandColors/BrandColors.d.ts +0 -1
  26. package/dist/components/core/docs/componets/ColorSwatch/ColorSwatch.d.ts +0 -1
  27. package/dist/components/core/docs/componets/ColorSwatch/ColorSwatch.scss +4 -3
  28. package/dist/components/core/docs/componets/ColorSwatch/ColorSwatchBtn.d.ts +0 -1
  29. package/dist/components/core/docs/componets/ExampleGrid/ExampleGrid.d.ts +0 -1
  30. package/dist/components/core/docs/componets/SpacingBlock/SpacingBlock.d.ts +0 -1
  31. package/dist/components/core/docs/hooks/ClickOutside.d.ts +0 -1
  32. package/dist/components/core/docs/hooks/Intersection.d.ts +0 -1
  33. package/dist/components/core/docs/hooks/animated.d.ts +0 -1
  34. package/dist/components/core/docs/utils/PropertyList.d.ts +0 -1
  35. package/dist/components/core/hooks/useAnimatedHeight.d.ts +0 -1
  36. package/dist/components/core/hooks/useClickOutsideListener.d.ts +0 -1
  37. package/dist/components/core/hooks/useMutationObserver.d.ts +0 -1
  38. package/dist/components/core/mixin/breakpoints.scss +7 -6
  39. package/dist/components/core/spacing/Gutter.d.ts +0 -1
  40. package/dist/components/core/spacing/GutterPadding.d.ts +0 -1
  41. package/dist/components/dropdown/Dropdown.d.ts +0 -1
  42. package/dist/components/icons/Arrow.d.ts +0 -1
  43. package/dist/components/icons/Chevron.d.ts +0 -1
  44. package/dist/components/icons/HeartToggle.d.ts +0 -1
  45. package/dist/components/icons/{Icons-CVv5JxOX.mjs → Icons-2z4jxD15.mjs} +4 -4
  46. package/dist/components/icons/Icons.d.ts +0 -1
  47. package/dist/components/list/{CheckmarkListItem-D86vlUxv.mjs → CheckmarkListItem-B8_bwuQI.mjs} +1 -1
  48. package/dist/components/list/CheckmarkListItem.d.ts +0 -1
  49. package/dist/components/list/{CrossmarkListItem-CXIrUTPd.mjs → CrossmarkListItem-5UQyojvM.mjs} +1 -1
  50. package/dist/components/list/CrossmarkListItem.d.ts +0 -1
  51. package/dist/components/list/List.d.ts +0 -1
  52. package/dist/components/list/ListItem.d.ts +0 -1
  53. package/dist/components/list/OrderedListItem.d.ts +0 -1
  54. package/dist/components/loader/Loader.d.ts +0 -1
  55. package/dist/components/loader/Loader.scss +6 -5
  56. package/dist/components/loader/RawLoader.d.ts +0 -1
  57. package/dist/components/notificationDot/NotificationDot.d.ts +0 -1
  58. package/dist/components/panel/{Panel-CPz2fLQW.mjs → Panel-DLDDq0m-.mjs} +12 -12
  59. package/dist/components/panel/Panel.d.ts +0 -1
  60. package/dist/components/progress/CircularProgress.d.ts +0 -1
  61. package/dist/components/progress/Progress.d.ts +0 -1
  62. package/dist/components/textfield/PasswordTextField.d.ts +0 -1
  63. package/dist/components/textfield/TextField.d.ts +0 -1
  64. package/dist/components/toggle/FieldSet.d.ts +0 -1
  65. package/dist/components/toggle/RadioToggle.d.ts +0 -1
  66. package/dist/components/toggle/docs/Example.d.ts +0 -1
  67. package/dist/components/toggleButton/ToggleButton.d.ts +0 -1
  68. package/dist/components/toggleInlineButton/ToggleInlineButton.d.ts +0 -1
  69. package/dist/components/toggleLinkButton/{ToggleLinkButton-W1wyWc93.mjs → ToggleLinkButton-aFK3jhbx.mjs} +1 -1
  70. package/dist/components/toggleLinkButton/ToggleLinkButton.d.ts +0 -1
  71. package/dist/components/typography/Typography.d.ts +0 -1
  72. package/dist/shared-components.mjs +6 -6
  73. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # 📖 Changelog
2
2
 
3
+ ## 3.3.0
4
+
5
+ - update `vite` to v6 (uses sass modern compiler by default)
6
+ - update sass to latest version
7
+ - fix all sass compilation (deprecation) warnings
8
+
3
9
  ## 3.2.3
4
10
 
5
11
  - Add scss font-size-variables for rds-typography
@@ -1,5 +1,4 @@
1
1
  import { DetailedHTMLProps, FC, DetailsHTMLAttributes, ReactNode } from 'react';
2
-
3
2
  interface Props extends DetailedHTMLProps<DetailsHTMLAttributes<HTMLDetailsElement>, HTMLDetailsElement> {
4
3
  heading: ReactNode;
5
4
  initialOpen?: boolean;
@@ -1,8 +1,8 @@
1
1
  import { jsxs as a, jsx as s } from "react/jsx-runtime";
2
2
  import { forwardRef as B, useState as o } from "react";
3
+ import { H as F, B as T } from "../typography/Typography-CXNJ1SFo.mjs";
3
4
  import "../icons/HeartToggle-Bwgo4FxH.mjs";
4
- import { S as F, a as T, b as d, c as b } from "../icons/Icons-CVv5JxOX.mjs";
5
- import { H as x, B as O } from "../typography/Typography-CXNJ1SFo.mjs";
5
+ import { S as b, a as d, b as x, c as O } from "../icons/Icons-2z4jxD15.mjs";
6
6
  const H = "_rds-alert--icon_m8jce_67", R = "_rds-alert--content-title_m8jce_79", D = "_rds-alert--content_m8jce_79", E = "_rds-alert--dismiss_m8jce_109", M = "_dismissed_m8jce_138", V = "_dismiss-fade-out_m8jce_1", e = {
7
7
  rdsAlertIcon: H,
8
8
  rdsAlertContentTitle: R,
@@ -11,7 +11,7 @@ const H = "_rds-alert--icon_m8jce_67", R = "_rds-alert--content-title_m8jce_79",
11
11
  dismissed: M,
12
12
  dismissFadeOut: V
13
13
  }, q = {
14
- warning: { title: "Advarsel", Icon: T },
14
+ warning: { title: "Advarsel", Icon: x },
15
15
  error: { title: "Feil", Icon: d },
16
16
  info: { title: "Informasjon", Icon: d },
17
17
  success: { title: "Vellykket", Icon: b }
@@ -52,11 +52,11 @@ const H = "_rds-alert--icon_m8jce_67", R = "_rds-alert--content-title_m8jce_79",
52
52
  children: [
53
53
  /* @__PURE__ */ s(S, { className: e.rdsAlertIcon }),
54
54
  /* @__PURE__ */ a("div", { className: e.rdsAlertContent, children: [
55
- /* @__PURE__ */ s(x, { className: e.rdsAlertContentTitle, as: "span", children: A || N }),
56
- /* @__PURE__ */ s(O, { as: "div", children: f }),
55
+ /* @__PURE__ */ s(F, { className: e.rdsAlertContentTitle, as: "span", children: A || N }),
56
+ /* @__PURE__ */ s(T, { as: "div", children: f }),
57
57
  u
58
58
  ] }),
59
- w && /* @__PURE__ */ s("div", { className: e.rdsAlertDismiss, children: /* @__PURE__ */ s("button", { "aria-label": "Avvis varsel", onClick: () => l(!0), children: /* @__PURE__ */ s(F, {}) }) })
59
+ w && /* @__PURE__ */ s("div", { className: e.rdsAlertDismiss, children: /* @__PURE__ */ s("button", { "aria-label": "Avvis varsel", onClick: () => l(!0), children: /* @__PURE__ */ s(O, {}) }) })
60
60
  ]
61
61
  }
62
62
  );
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes, ReactElement, ReactNode } from 'react';
2
-
3
2
  /**
4
3
  * Alerts are styled by props "intent" (color), "variant" (background and padding) and take an optional heading.
5
4
  *
@@ -10,9 +9,7 @@ import { HTMLAttributes, ReactElement, ReactNode } from 'react';
10
9
  * Dismiss icon can be hidden by passing `dismissible={false}`
11
10
  *
12
11
  * An optional link to details can be passed as `LinkToDetails={JsxElement}`
13
-
14
-
15
- */
12
+ */
16
13
  export declare const Alert: import('react').ForwardRefExoticComponent<Props & import('react').RefAttributes<HTMLDivElement>>;
17
14
  export interface Props extends HTMLAttributes<HTMLDivElement> {
18
15
  className?: string;
@@ -1,5 +1,4 @@
1
1
  import { FC, HTMLAttributes, PropsWithChildren, ReactNode } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLElement> {
4
3
  crumbs: Array<{
5
4
  name: string;
@@ -1,5 +1,4 @@
1
1
  import { DecoratedButtonProps } from './BaseDecoratedButton';
2
-
3
2
  interface ArrowButtonProps extends Omit<DecoratedButtonProps, "arrow"> {
4
3
  forwards?: boolean;
5
4
  }
@@ -1,6 +1,5 @@
1
1
  import { ButtonHTMLAttributes } from 'react';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  export type ButtonStyles = "primary" | "secondary" | "tertiary" | "ghost";
5
4
  export type ButtonBackgroundStyles = boolean | "white";
6
5
  export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
@@ -1,6 +1,5 @@
1
1
  import { BaseButtonProps, ButtonProps } from './BaseButton';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  export interface DecoratedButtonProps extends ButtonProps {
5
4
  postfix?: string;
6
5
  icon?: () => JSX.Element;
@@ -1,6 +1,5 @@
1
1
  import { ButtonBackgroundStyles, ButtonStyles } from './BaseButton';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  export type LinkButtonStyles = ButtonStyles | "highlighted";
5
4
  interface BaseLinkButtonPropsWithElement<ElementProps> {
6
5
  element: (props: ElementProps) => JSX.Element;
@@ -1,5 +1,4 @@
1
1
  import { ButtonProps } from './BaseButton';
2
-
3
2
  export declare const PrimaryButton: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
4
3
  export declare const SecondaryButton: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
5
4
  export declare const TertiaryButton: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
@@ -1,5 +1,4 @@
1
1
  import { BaseDecoratedButtonProps } from './BaseDecoratedButton';
2
-
3
2
  export declare const PrimaryDecoratedButton: import('react').ForwardRefExoticComponent<Omit<BaseDecoratedButtonProps, "buttonStyle"> & import('react').RefAttributes<HTMLButtonElement>>;
4
3
  export declare const SecondaryDecoratedButton: import('react').ForwardRefExoticComponent<Omit<BaseDecoratedButtonProps, "buttonStyle"> & import('react').RefAttributes<HTMLButtonElement>>;
5
4
  export declare const TertiaryDecoratedButton: import('react').ForwardRefExoticComponent<Omit<BaseDecoratedButtonProps, "buttonStyle"> & import('react').RefAttributes<HTMLButtonElement>>;
@@ -1,6 +1,5 @@
1
1
  import { DecoratedButtonProps } from './BaseDecoratedButton';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  interface IconButtonProps extends Omit<DecoratedButtonProps, "icon"> {
5
4
  icon: () => JSX.Element;
6
5
  }
@@ -132,6 +132,11 @@
132
132
  // Need fluid line-height on order to keep height at 48px for accessibility when font changes
133
133
  line-height: clamp(150%, 156.4288% + -1.1161vw, 135%);
134
134
 
135
+ color: var(--common-button--color);
136
+ background-color: var(--common-button--bg);
137
+ outline: var(--common-button--outline);
138
+ outline-offset: -2px;
139
+
135
140
  @include break.min("sm") {
136
141
  --button-font-family: var(--rds-font-family-headlines);
137
142
  }
@@ -149,10 +154,6 @@
149
154
  /*#endregion reset end */
150
155
 
151
156
  /*#region Button styles */
152
- color: var(--common-button--color);
153
- background-color: var(--common-button--bg);
154
- outline: var(--common-button--outline);
155
- outline-offset: -2px;
156
157
 
157
158
  @media (hover: hover) {
158
159
  &:hover,
@@ -1,5 +1,4 @@
1
1
  import { DetailedHTMLProps, InputHTMLAttributes } from 'react';
2
-
3
2
  export interface Props extends Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> {
4
3
  containerClassName?: string;
5
4
  inputClassName?: string;
@@ -1,5 +1,4 @@
1
1
  import { DetailedHTMLProps, InputHTMLAttributes } from 'react';
2
-
3
2
  export interface Props extends Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> {
4
3
  className?: string;
5
4
  lightBackground?: boolean;
@@ -10,6 +10,9 @@
10
10
  --checkbox-label-color: var(--rds-foreground-primary);
11
11
  --checkbox-error-color: var(--rds-feedback-error);
12
12
 
13
+ display: flex;
14
+ gap: 0.75em;
15
+
13
16
  /* light mode overrides */
14
17
  :where(.rds-light) & {
15
18
  --checkbox-border-color: var(--rds-button-primary-fg);
@@ -40,9 +43,6 @@
40
43
  }
41
44
  }
42
45
 
43
- display: flex;
44
- gap: 0.75em;
45
-
46
46
  .rds-checkbox {
47
47
  &__input {
48
48
  cursor: pointer;
@@ -1,5 +1,4 @@
1
1
  import { FC, PropsWithChildren } from 'react';
2
-
3
2
  export declare const Core: FC<PropsWithChildren<{
4
3
  brand: "strm" | "rtv";
5
4
  }>>;
@@ -1,3 +1,2 @@
1
1
  import { HtmlHTMLAttributes } from 'react';
2
-
3
2
  export declare const LightMode: import('react').ForwardRefExoticComponent<HtmlHTMLAttributes<HTMLDivElement> & import('react').RefAttributes<HTMLDivElement>>;
@@ -1,3 +1,2 @@
1
1
  import { FC, PropsWithChildren } from 'react';
2
-
3
2
  export declare const RiksTVProvider: FC<PropsWithChildren>;
@@ -1,3 +1,2 @@
1
1
  import { FC, PropsWithChildren } from 'react';
2
-
3
2
  export declare const StrimProvider: FC<PropsWithChildren>;
@@ -1,4 +1,3 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Roundness: FC;
4
3
  export declare const Font: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Colors: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Spacing: FC;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Breakpoints: FC;
4
3
  export declare const Gutters: FC;
5
4
  export declare const Widths: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const BrandColors: FC;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const ColorSwatch: FC<{
4
3
  color: string;
5
4
  }>;
@@ -27,9 +27,6 @@
27
27
 
28
28
  &--copied::before {
29
29
  --color-swatch-animation-offset: 10px;
30
- @media (prefers-reduced-motion) {
31
- --color-swatch-animation-offset: 0px;
32
- }
33
30
 
34
31
  content: attr(data-copied);
35
32
  position: absolute;
@@ -48,6 +45,10 @@
48
45
  animation-name: color-swatch-copy-fade;
49
46
  animation-timing-function: ease;
50
47
  box-shadow: var(--rds-box-shadow--default);
48
+
49
+ @media (prefers-reduced-motion) {
50
+ --color-swatch-animation-offset: 0px;
51
+ }
51
52
  }
52
53
  }
53
54
 
@@ -1,5 +1,4 @@
1
1
  import { FC, ReactNode } from 'react';
2
-
3
2
  interface Props {
4
3
  onClick: () => void;
5
4
  children: ReactNode;
@@ -1,5 +1,4 @@
1
1
  import { FC, PropsWithChildren } from 'react';
2
-
3
2
  export declare const ExampleGrid: FC<PropsWithChildren<{
4
3
  title: string;
5
4
  }>>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const SpacingBlock: FC<{
4
3
  size: number;
5
4
  }>;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const ClickOutside: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Intersection: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const AnimationExample: FC;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const PropertyList: FC<{
4
3
  properties: string[];
5
4
  }>;
@@ -1,5 +1,4 @@
1
1
  import { RefObject } from 'react';
2
-
3
2
  export interface UseAnimatedHeightOptions {
4
3
  onTransitionStart?: (isOpening: boolean) => void;
5
4
  onTransitionEnd?: (isOpen: boolean) => void;
@@ -1,5 +1,4 @@
1
1
  import { RefObject } from 'react';
2
-
3
2
  interface Props {
4
3
  ref?: RefObject<HTMLElement | null>;
5
4
  callback: (e: MouseEvent) => void;
@@ -1,3 +1,2 @@
1
1
  import { RefObject } from 'react';
2
-
3
2
  export declare const useMutationObserver: (target: Element | RefObject<Element | null>, onObservation: MutationCallback, config?: MutationObserverInit) => void;
@@ -1,3 +1,4 @@
1
+ @use "sass:map";
1
2
  $xs: 568px;
2
3
  $sm: 768px;
3
4
  $md: 992px;
@@ -18,27 +19,27 @@ $breakpoints: (
18
19
 
19
20
  @mixin breakpoint($breakpoint) {
20
21
  // If the key exists in the map
21
- @if map-has-key($breakpoints, $breakpoint) {
22
+ @if map.has-key($breakpoints, $breakpoint) {
22
23
  // Prints a media query based on the value
23
- @media (max-width: map-get($breakpoints, $breakpoint)) {
24
+ @media (max-width: map.get($breakpoints, $breakpoint)) {
24
25
  @content;
25
26
  }
26
27
  }
27
28
 
28
29
  // If the key doesn't exist in the map
29
30
  @else {
30
- @warn 'Unfortunately, no value could be retrieved from `#{$breakpoint}`. ' + 'Available breakpoints are: #{map-keys($breakpoints)}.';
31
+ @warn 'Unfortunately, no value could be retrieved from `#{$breakpoint}`. ' + 'Available breakpoints are: #{map.keys($breakpoints)}.';
31
32
  }
32
33
  }
33
34
 
34
35
  @mixin min($breakpoint) {
35
36
  // If the key exists in the map
36
- @if map-has-key($breakpoints, $breakpoint) {
37
+ @if map.has-key($breakpoints, $breakpoint) {
37
38
  // Prints a media query based on the value
38
- @media (min-width: map-get($breakpoints, $breakpoint)) {
39
+ @media (min-width: map.get($breakpoints, $breakpoint)) {
39
40
  @content;
40
41
  }
41
42
  } @else {
42
- @warn 'Unfortunately, no value could be retrieved from `#{$breakpoint}`. ' + 'Available breakpoints are: #{map-keys($breakpoints)}.';
43
+ @warn 'Unfortunately, no value could be retrieved from `#{$breakpoint}`. ' + 'Available breakpoints are: #{map.keys($breakpoints)}.';
43
44
  }
44
45
  }
@@ -1,3 +1,2 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
-
3
2
  export declare const Gutter: FC<HTMLAttributes<HTMLDivElement>>;
@@ -1,3 +1,2 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
-
3
2
  export declare const GutterPadding: FC<HTMLAttributes<HTMLDivElement>>;
@@ -1,6 +1,5 @@
1
1
  import { RefObject } from 'react';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  interface BaseDropdownOption {
5
4
  title: string;
6
5
  value: string;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Arrow: FC;
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Chevron: FC;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const HeartToggle: FC<{
4
3
  checked: boolean;
5
4
  }>;
@@ -21,10 +21,10 @@ const n = (t) => /* @__PURE__ */ e.createElement("svg", { viewBox: "4 4 24 24",
21
21
  }, Symbol.toStringTag, { value: "Module" }));
22
22
  export {
23
23
  h as I,
24
- i as S,
25
- w as a,
26
- g as b,
27
- m as c,
24
+ m as S,
25
+ g as a,
26
+ w as b,
27
+ i as c,
28
28
  n as d,
29
29
  v as e,
30
30
  d as f
@@ -12,5 +12,4 @@ import { default as AlertTriangle } from './AlertTriangle.svg?react';
12
12
  import { default as CheckCircle } from './CheckCircle.svg?react';
13
13
  import { default as Add } from './Add.svg?react';
14
14
  import { default as Subtract } from './Subtract.svg?react';
15
-
16
15
  export { Arrow, Checkmark, Chevron, Heart, HeartToggle, HeartUnfilled, Pause, Play, Close, InfoCircle, AlertTriangle, CheckCircle, Add, Subtract, };
@@ -1,7 +1,7 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import "react";
3
3
  import "../icons/HeartToggle-Bwgo4FxH.mjs";
4
- import { d as o } from "../icons/Icons-CVv5JxOX.mjs";
4
+ import { d as o } from "../icons/Icons-2z4jxD15.mjs";
5
5
  import { L as i } from "./ListItem-ClQsSisn.mjs";
6
6
  const k = ({ children: r, ...m }) => /* @__PURE__ */ t(i, { testId: "rds-list-item--check", icon: /* @__PURE__ */ t(o, {}), ...m, children: r });
7
7
  export {
@@ -1,6 +1,5 @@
1
1
  import { FC } from 'react';
2
2
  import { ListItemProps } from './ListItem';
3
-
4
3
  type Props = Omit<ListItemProps, "icon" | "testId">;
5
4
  export declare const CheckmarkListItem: FC<Props>;
6
5
  export {};
@@ -1,7 +1,7 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import "react";
3
3
  import "../icons/HeartToggle-Bwgo4FxH.mjs";
4
- import { S as o } from "../icons/Icons-CVv5JxOX.mjs";
4
+ import { c as o } from "../icons/Icons-2z4jxD15.mjs";
5
5
  import { L as m } from "./ListItem-ClQsSisn.mjs";
6
6
  const f = ({ children: r, ...s }) => /* @__PURE__ */ t(m, { testId: "rds-list-item--cross", icon: /* @__PURE__ */ t(o, {}), ...s, children: r });
7
7
  export {
@@ -1,6 +1,5 @@
1
1
  import { FC } from 'react';
2
2
  import { ListItemProps } from './ListItem';
3
-
4
3
  type Props = Omit<ListItemProps, "icon" | "testId">;
5
4
  export declare const CrossmarkListItem: FC<Props>;
6
5
  export {};
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLUListElement | HTMLOListElement> {
4
3
  className?: string;
5
4
  ordered?: boolean;
@@ -1,6 +1,5 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  export interface ListItemProps extends HTMLAttributes<HTMLLIElement> {
5
4
  className?: string;
6
5
  color?: "error" | "success" | "faded";
@@ -1,5 +1,4 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLLIElement> {
4
3
  className?: string;
5
4
  innerClassName?: string;
@@ -1,5 +1,4 @@
1
1
  import { Props as LoaderProps } from './RawLoader';
2
-
3
2
  interface Props extends LoaderProps {
4
3
  delay?: number;
5
4
  }
@@ -1,3 +1,4 @@
1
+ @use "sass:list";
1
2
  .rds-loader-container {
2
3
  display: grid;
3
4
  place-items: center;
@@ -11,15 +12,15 @@
11
12
  $deg: 0deg, 22.5deg, 45deg, 67.5deg, 90deg, 112.5deg, 135deg, 157.5deg, 180deg, 202.5deg, 225deg, 247.5deg, 270deg,
12
13
  292.5deg, 315deg, 337.5deg;
13
14
 
14
- @for $i from 1 through length($deg) {
15
+ @for $i from 1 through list.length($deg) {
15
16
  @keyframes loader-container-spinner-child-#{$i} {
16
17
  0% {
17
18
  opacity: 1;
18
- transform: rotate(nth($deg, $i)) scaleY(1.2);
19
+ transform: rotate(list.nth($deg, $i)) scaleY(1.2);
19
20
  }
20
21
  10%,
21
22
  100% {
22
- transform: rotate(nth($deg, $i));
23
+ transform: rotate(list.nth($deg, $i));
23
24
  }
24
25
  100% {
25
26
  opacity: 0;
@@ -28,6 +29,8 @@
28
29
  }
29
30
 
30
31
  &__spinner {
32
+ transform: translate(-50px, -50px) scale(0.5) translate(50px, 50px);
33
+
31
34
  &__large {
32
35
  span {
33
36
  position: absolute;
@@ -136,8 +139,6 @@
136
139
  animation: loader-container-spinner-child-16 linear 2s infinite;
137
140
  animation-delay: 0s;
138
141
  }
139
-
140
- transform: translate(-50px, -50px) scale(0.5) translate(50px, 50px);
141
142
  }
142
143
  }
143
144
 
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes } from 'react';
2
-
3
2
  export interface Props extends HTMLAttributes<HTMLDivElement> {
4
3
  className?: string;
5
4
  size?: "small" | "large";
@@ -1,5 +1,4 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLSpanElement> {
4
3
  numberOfNotifications?: number;
5
4
  large?: boolean;
@@ -1,34 +1,34 @@
1
- import { jsxs as e, jsx as s } from "react/jsx-runtime";
1
+ import { jsx as s, jsxs as e } from "react/jsx-runtime";
2
2
  import { forwardRef as v } from "react";
3
3
  import { S as N } from "../typography/Typography-CXNJ1SFo.mjs";
4
4
  import "../icons/HeartToggle-Bwgo4FxH.mjs";
5
- import { b as l, c as b, a as P } from "../icons/Icons-CVv5JxOX.mjs";
6
- const y = "_rds-panel_297es_1", A = "_content-and-buttons_297es_34", S = "_content_297es_34", j = "_title_297es_60", k = "_icon_297es_68", x = "_buttons_297es_75", n = {
7
- rdsPanel: y,
8
- contentAndButtons: A,
9
- content: S,
5
+ import { b, S as P, a as c } from "../icons/Icons-2z4jxD15.mjs";
6
+ const S = "_rds-panel_297es_1", y = "_content-and-buttons_297es_34", A = "_content_297es_34", j = "_title_297es_60", k = "_icon_297es_68", x = "_buttons_297es_75", n = {
7
+ rdsPanel: S,
8
+ contentAndButtons: y,
9
+ content: A,
10
10
  title: j,
11
11
  icon: k,
12
12
  buttons: x
13
13
  }, B = {
14
14
  error: {
15
15
  title: "Feil",
16
- icon: /* @__PURE__ */ s(l, {})
16
+ icon: /* @__PURE__ */ s(c, {})
17
17
  },
18
18
  info: {
19
19
  title: "Informasjon",
20
- icon: /* @__PURE__ */ s(l, {})
20
+ icon: /* @__PURE__ */ s(c, {})
21
21
  },
22
22
  success: {
23
23
  title: "Vellykket",
24
- icon: /* @__PURE__ */ s(b, {})
24
+ icon: /* @__PURE__ */ s(P, {})
25
25
  },
26
26
  warning: {
27
27
  title: "Advarsel",
28
- icon: /* @__PURE__ */ s(P, {})
28
+ icon: /* @__PURE__ */ s(b, {})
29
29
  }
30
30
  }, C = v(
31
- ({ className: r = "", intent: o = "info", heading: t, action: c, id: i, children: a, ..._ }, m) => {
31
+ ({ className: r = "", intent: o = "info", heading: t, action: l, id: i, children: a, ..._ }, m) => {
32
32
  const { title: p, icon: d } = B[o], f = typeof t == "string" ? t : (t == null ? void 0 : t.title) ?? p, u = typeof t == "string" ? "span" : (t == null ? void 0 : t.level) ?? "span";
33
33
  return /* @__PURE__ */ e(
34
34
  "div",
@@ -46,7 +46,7 @@ const y = "_rds-panel_297es_1", A = "_content-and-buttons_297es_34", S = "_conte
46
46
  /* @__PURE__ */ s(u, { className: `${n.title} rds-title-4`, children: f }),
47
47
  /* @__PURE__ */ s(N, { children: a })
48
48
  ] }),
49
- c && /* @__PURE__ */ s("div", { className: n.buttons, children: c })
49
+ l && /* @__PURE__ */ s("div", { className: n.buttons, children: l })
50
50
  ] })
51
51
  ]
52
52
  }
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes, ReactNode } from 'react';
2
-
3
2
  type Intent = "info" | "warning" | "success" | "error";
4
3
  export interface Props extends HTMLAttributes<HTMLDivElement> {
5
4
  className?: string;
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLDivElement> {
4
3
  progressRatio: number;
5
4
  label: string;
@@ -1,5 +1,4 @@
1
1
  import { HTMLAttributes } from 'react';
2
-
3
2
  interface Props extends HTMLAttributes<HTMLProgressElement> {
4
3
  label: string;
5
4
  ratio: number;
@@ -1,3 +1,2 @@
1
1
  import { TextFieldProps } from './TextField';
2
-
3
2
  export declare const PasswordTextField: import('react').ForwardRefExoticComponent<Omit<TextFieldProps, "type"> & import('react').RefAttributes<HTMLInputElement>>;
@@ -1,5 +1,4 @@
1
1
  import { DetailedHTMLProps, InputHTMLAttributes } from 'react';
2
-
3
2
  export interface TextFieldProps extends Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> {
4
3
  className?: string;
5
4
  name: string;
@@ -1,5 +1,4 @@
1
1
  import { FieldsetHTMLAttributes } from 'react';
2
-
3
2
  interface FieldSetProps extends FieldsetHTMLAttributes<HTMLFieldSetElement> {
4
3
  legend: string;
5
4
  name: string;
@@ -1,5 +1,4 @@
1
1
  import { InputHTMLAttributes } from 'react';
2
-
3
2
  interface RadioToggleInputProps extends InputHTMLAttributes<HTMLInputElement> {
4
3
  label: string;
5
4
  }
@@ -1,3 +1,2 @@
1
1
  import { FC } from 'react';
2
-
3
2
  export declare const Example: FC;
@@ -1,6 +1,5 @@
1
1
  import { FC, InputHTMLAttributes } from 'react';
2
2
  import { JSX } from 'react/jsx-runtime';
3
-
4
3
  interface Props extends Omit<InputHTMLAttributes<HTMLInputElement>, "type"> {
5
4
  children: string;
6
5
  alwaysShowLabel?: boolean;
@@ -1,5 +1,4 @@
1
1
  import { InputHTMLAttributes } from 'react';
2
-
3
2
  interface Props extends Omit<InputHTMLAttributes<HTMLInputElement>, "type"> {
4
3
  lightBackground?: boolean;
5
4
  inputClassName?: string;
@@ -2,7 +2,7 @@ import { jsx as n, jsxs as m } from "react/jsx-runtime";
2
2
  import { forwardRef as b, useRef as p, useState as h } from "react";
3
3
  import { B as C } from "../checkbox/BaseCheckbox-BGkrjof6.mjs";
4
4
  import "../icons/HeartToggle-Bwgo4FxH.mjs";
5
- import { e as N, f as x } from "../icons/Icons-CVv5JxOX.mjs";
5
+ import { e as N, f as x } from "../icons/Icons-2z4jxD15.mjs";
6
6
  const B = b(
7
7
  ({ defaultChecked: a, toggledContentId: i, lightBackground: r, children: c, onChange: o, id: g, className: d = "", ...u }, _) => {
8
8
  const f = p(null), [t, l] = h(!!a), e = _ || f;
@@ -1,5 +1,4 @@
1
1
  import { InputHTMLAttributes } from 'react';
2
-
3
2
  interface Props extends Omit<InputHTMLAttributes<HTMLInputElement>, "type"> {
4
3
  children: string;
5
4
  toggledContentId: string;
@@ -1,5 +1,4 @@
1
1
  import { ForwardRefExoticComponent, HTMLAttributes } from 'react';
2
-
3
2
  type HeadingLevels = 1 | 2 | 3 | 4;
4
3
  type SubHeadingLevels = 2 | 3;
5
4
  type AcceptedHTMLElements = HTMLSpanElement | HTMLHeadingElement | HTMLParagraphElement;
@@ -5,8 +5,8 @@ import { G as k } from "./components/spacing/Gutter-PXX_UdiX.mjs";
5
5
  import { G as N } from "./components/spacing/GutterPadding-Bd7tSm3F.mjs";
6
6
  import { N as Q } from "./components/notificationDot/NotificationDot-C2_j4FdL.mjs";
7
7
  import { A as _ } from "./components/accordion/Accordion-rewqLwCV.mjs";
8
- import { P as U } from "./components/panel/Panel-CPz2fLQW.mjs";
9
- import { A as z } from "./components/alert/Alert-C5wx7EXq.mjs";
8
+ import { P as U } from "./components/panel/Panel-DLDDq0m-.mjs";
9
+ import { A as z } from "./components/alert/Alert-BiVxm3um.mjs";
10
10
  import { B as K, a as X } from "./components/breadcrumb/Breadcrumb-BJNLZ7iB.mjs";
11
11
  import { P as Z } from "./components/progress/Progress-CjnegHvC.mjs";
12
12
  import { L as re } from "./components/loader/Loader-gjL6yh1f.mjs";
@@ -17,7 +17,7 @@ import { G as fe, P as le, S as xe, T as ge } from "./components/button/ArrowBut
17
17
  import { G as ye, P as Te, S as ve, T as Be } from "./components/button/IconButton-DVEZ8K3d.mjs";
18
18
  import { T as we } from "./components/toggleButton/ToggleButton-CGLyQll6.mjs";
19
19
  import { T as Ie } from "./components/toggleInlineButton/ToggleInlineButton-Cnet1doK.mjs";
20
- import { T as be } from "./components/toggleLinkButton/ToggleLinkButton-W1wyWc93.mjs";
20
+ import { T as be } from "./components/toggleLinkButton/ToggleLinkButton-aFK3jhbx.mjs";
21
21
  import { C as Pe } from "./components/checkbox/Checkbox-Cl4PCYXu.mjs";
22
22
  import { R as Se } from "./components/toggle/RadioToggle-C_79eEFl.mjs";
23
23
  import { F as Ce } from "./components/toggle/FieldSet-BM_JN_UL.mjs";
@@ -25,12 +25,12 @@ import { T as Fe } from "./components/textfield/TextField-Ct-ceRzE.mjs";
25
25
  import { P as De } from "./components/textfield/PasswordTextField-BfvT8zYj.mjs";
26
26
  import { B as ke, d as Ve, D as Ne, a as $e, b as Qe, c as We, H as _e, L as qe, M as Ue, S as je, e as ze, f as Je, g as Ke, T as Xe } from "./components/typography/Typography-CXNJ1SFo.mjs";
27
27
  import { L as Ze } from "./components/list/List-4jHnUXn_.mjs";
28
- import { C as rr } from "./components/list/CheckmarkListItem-D86vlUxv.mjs";
28
+ import { C as rr } from "./components/list/CheckmarkListItem-B8_bwuQI.mjs";
29
29
  import { L as nr } from "./components/list/ListItem-ClQsSisn.mjs";
30
- import { C as sr } from "./components/list/CrossmarkListItem-CXIrUTPd.mjs";
30
+ import { C as sr } from "./components/list/CrossmarkListItem-5UQyojvM.mjs";
31
31
  import { O as ar } from "./components/list/OrderedListItem-CphW2Aa0.mjs";
32
32
  import { useState as x, useEffect as m, useRef as c, useCallback as g, useLayoutEffect as y } from "react";
33
- import { I as ur } from "./components/icons/Icons-CVv5JxOX.mjs";
33
+ import { I as ur } from "./components/icons/Icons-2z4jxD15.mjs";
34
34
  import { B as mr } from "./components/button/BaseLinkButton-niQ474XP.mjs";
35
35
  const h = "(prefers-reduced-motion: reduce)", T = (e) => typeof window < "u" && window.matchMedia ? window.matchMedia(e).matches : !1, v = (e, t) => {
36
36
  typeof e.addEventListener < "u" && e.addEventListener("change", t);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rikstv/shared-components",
3
- "version": "3.2.7-alpha.2",
3
+ "version": "3.2.7-alpha.4",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },