@norges-domstoler/dds-components 0.0.0-dev-20240819123353 → 0.0.0-dev-20240822073709

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/dist/index.mjs CHANGED
@@ -7856,16 +7856,10 @@ var GlobalMessage_default = {
7856
7856
 
7857
7857
  // src/components/GlobalMessage/GlobalMessage.tsx
7858
7858
  import { jsx as jsx237, jsxs as jsxs50 } from "react/jsx-runtime";
7859
- var purposeVariants = {
7860
- info: {
7861
- icon: InfoIcon
7862
- },
7863
- danger: {
7864
- icon: ErrorIcon
7865
- },
7866
- warning: {
7867
- icon: WarningIcon
7868
- }
7859
+ var icons = {
7860
+ info: InfoIcon,
7861
+ danger: ErrorIcon,
7862
+ warning: WarningIcon
7869
7863
  };
7870
7864
  var GlobalMessage = forwardRef54(
7871
7865
  (props, ref) => {
@@ -7905,7 +7899,7 @@ var GlobalMessage = forwardRef54(
7905
7899
  closable && GlobalMessage_default["content--closable"]
7906
7900
  ),
7907
7901
  children: [
7908
- /* @__PURE__ */ jsx237(Icon, { icon: purposeVariants[purpose].icon, className: GlobalMessage_default.icon }),
7902
+ /* @__PURE__ */ jsx237(Icon, { icon: icons[purpose], className: GlobalMessage_default.icon }),
7909
7903
  children != null ? children : /* @__PURE__ */ jsx237("span", { children: message })
7910
7904
  ]
7911
7905
  }
@@ -8673,22 +8667,12 @@ var LocalMessage_default = {
8673
8667
 
8674
8668
  // src/components/LocalMessage/LocalMessage.tsx
8675
8669
  import { Fragment as Fragment7, jsx as jsx250, jsxs as jsxs55 } from "react/jsx-runtime";
8676
- var purposeVariants2 = {
8677
- info: {
8678
- icon: InfoIcon
8679
- },
8680
- danger: {
8681
- icon: ErrorIcon
8682
- },
8683
- warning: {
8684
- icon: WarningIcon
8685
- },
8686
- success: {
8687
- icon: CheckCircledIcon
8688
- },
8689
- tips: {
8690
- icon: TipIcon
8691
- }
8670
+ var icons2 = {
8671
+ info: InfoIcon,
8672
+ danger: ErrorIcon,
8673
+ warning: WarningIcon,
8674
+ success: CheckCircledIcon,
8675
+ tips: TipIcon
8692
8676
  };
8693
8677
  var LocalMessage = forwardRef63(
8694
8678
  (props, ref) => {
@@ -8731,7 +8715,7 @@ var LocalMessage = forwardRef63(
8731
8715
  /* @__PURE__ */ jsx250(
8732
8716
  Icon,
8733
8717
  {
8734
- icon: purposeVariants2[purpose].icon,
8718
+ icon: icons2[purpose],
8735
8719
  className: cn(LocalMessage_default.icon, LocalMessage_default.container__icon)
8736
8720
  }
8737
8721
  ),
@@ -11971,22 +11955,12 @@ var Tag_default = {
11971
11955
 
11972
11956
  // src/components/Tag/Tag.tsx
11973
11957
  import { jsx as jsx289, jsxs as jsxs74 } from "react/jsx-runtime";
11974
- var purposeVariants3 = {
11975
- info: {
11976
- icon: InfoIcon
11977
- },
11978
- danger: {
11979
- icon: ErrorIcon
11980
- },
11981
- warning: {
11982
- icon: WarningIcon
11983
- },
11984
- success: {
11985
- icon: CheckCircledIcon
11986
- },
11987
- default: {
11988
- icon: void 0
11989
- }
11958
+ var icons3 = {
11959
+ info: InfoIcon,
11960
+ danger: ErrorIcon,
11961
+ warning: WarningIcon,
11962
+ success: CheckCircledIcon,
11963
+ default: void 0
11990
11964
  };
11991
11965
  var Tag = forwardRef95((props, ref) => {
11992
11966
  const {
@@ -12000,7 +11974,7 @@ var Tag = forwardRef95((props, ref) => {
12000
11974
  withIcon,
12001
11975
  ...rest
12002
11976
  } = props;
12003
- const icon = purposeVariants3[purpose].icon;
11977
+ const icon = icons3[purpose];
12004
11978
  return /* @__PURE__ */ jsxs74(
12005
11979
  TextOverflowEllipsisWrapper,
12006
11980
  {
@@ -12876,7 +12850,6 @@ export {
12876
12850
  normalizeButton,
12877
12851
  outlineInset,
12878
12852
  outlineOffset,
12879
- purposeVariants,
12880
12853
  removeButtonStyling,
12881
12854
  removeListStyling,
12882
12855
  renderCharCounter,