@norges-domstoler/dds-components 0.0.0-dev-20260717081939 → 0.0.0-dev-20260720114143

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.cjs CHANGED
@@ -513,9 +513,6 @@ const combineHandlers = (handler1, handler2) => {
513
513
  function cn(...classNames) {
514
514
  return classNames.filter(Boolean).join(" ") || void 0;
515
515
  }
516
- function convertCamelToHyphen(value) {
517
- return value.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/([a-z])([0-9])/g, "$1-$2").toLowerCase();
518
- }
519
516
  /**
520
517
  * Returnener verdien hvis den er truthy.
521
518
  * Ellers returnerer `undefined`.
@@ -4059,6 +4056,78 @@ const Accordion = ({ isInitiallyExpanded = false, isExpanded, onChange, id, chil
4059
4056
  };
4060
4057
  Accordion.displayName = "Accordion";
4061
4058
  //#endregion
4059
+ //#region src/components/Accordion/AccordionHeader.tsx
4060
+ const AccordionHeader = ({ children, className, style, htmlProps, typographyType = "heading-medium", bold, ...rest }) => {
4061
+ const { isExpanded, headerProps } = useAccordionContext();
4062
+ const { id, ...restHeaderProps } = headerProps ?? {};
4063
+ const iconState = isExpanded ? "up" : "down";
4064
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4065
+ as: StylelessButton,
4066
+ padding: "x1 x1.5 x1 x1",
4067
+ ...getBaseHTMLProps(id, cn(className, Accordion_module_default["header-button"], AccordionBase_module_default["header-button"], _key1), style, htmlProps, rest),
4068
+ ...restHeaderProps,
4069
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4070
+ className: cn(AccordionBase_module_default.header__content, typographyStyles_module_default[typographyType], bold && typographyStyles_module_default.bold),
4071
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {
4072
+ icon: AnimatedChevronUpDownIcon,
4073
+ iconSize: "component",
4074
+ className: Accordion_module_default.chevron,
4075
+ iconState
4076
+ }), children]
4077
+ })
4078
+ });
4079
+ };
4080
+ AccordionHeader.displayName = "AccordionHeader";
4081
+ //#endregion
4082
+ //#region src/components/Accordion/AccordionBody.tsx
4083
+ const AccordionBody = ({ children, className, style, htmlProps, ...rest }) => {
4084
+ const { bodyContentRef, bodyProps } = useAccordionContext();
4085
+ const { className: bodyContextCn, id, height, ...restBodyProps } = bodyProps ?? {};
4086
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4087
+ height: `${height}px`,
4088
+ ...getBaseHTMLProps(id, cn(className, bodyContextCn), style, htmlProps, rest),
4089
+ ...restBodyProps,
4090
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4091
+ ref: bodyContentRef,
4092
+ padding: "x0.5 x1.5 x2 x1",
4093
+ children
4094
+ })
4095
+ });
4096
+ };
4097
+ AccordionBody.displayName = "AccordionBody";
4098
+ //#endregion
4099
+ //#region src/components/BackLink/BackLink.module.css
4100
+ var BackLink_module_default = { "icon": "dds-BackLink-module__icon" };
4101
+ //#endregion
4102
+ //#region src/components/BackLink/BackLink.tsx
4103
+ const BackLink = ({ label, ref, as = "a", ...rest }) => {
4104
+ const { t } = useTranslation();
4105
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("nav", {
4106
+ ref,
4107
+ "aria-label": t(texts$29.goBack),
4108
+ className: typographyStyles_module_default["body-short-medium"],
4109
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
4110
+ as,
4111
+ className: cn(typographyStyles_module_default.a, _key1),
4112
+ rel: "noopener noreferer",
4113
+ ...rest,
4114
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {
4115
+ icon: ArrowLeftIcon,
4116
+ iconSize: "component",
4117
+ className: cn(BackLink_module_default.icon)
4118
+ }), label]
4119
+ })
4120
+ });
4121
+ };
4122
+ BackLink.displayName = "BackLink";
4123
+ const texts$29 = createTexts({ goBack: {
4124
+ nb: "Gå tilbake",
4125
+ no: "Gå tilbake",
4126
+ nn: "Gå tilbake",
4127
+ en: "Go back",
4128
+ se: "Mana ruovttoluotta"
4129
+ } });
4130
+ //#endregion
4062
4131
  //#region src/components/Typography/Typography/TextOverflowEllipsis/TextOverflowEllipsis.module.css
4063
4132
  var TextOverflowEllipsis_module_default = {
4064
4133
  "wrapper": "dds-TextOverflowEllipsis-module__wrapper",
@@ -4083,28 +4152,42 @@ function TextOverflowEllipsisInner({ className, ...rest }) {
4083
4152
  var Typography_module_default = { "container": "dds-Typography-module__container" };
4084
4153
  //#endregion
4085
4154
  //#region src/components/Typography/Typography/Typography.types.ts
4155
+ const TG_BODY_SHORT_TYPES = [
4156
+ "body-short-xsmall",
4157
+ "body-short-small",
4158
+ "body-short-medium",
4159
+ "body-short-large"
4160
+ ];
4161
+ const TG_BODY_LONG_TYPES = [
4162
+ "body-long-xsmall",
4163
+ "body-long-small",
4164
+ "body-long-medium",
4165
+ "body-long-large"
4166
+ ];
4167
+ const TG_BODY_TYPES = [...TG_BODY_SHORT_TYPES, ...TG_BODY_LONG_TYPES];
4168
+ const TG_LEAD_TYPES = ["lead-medium"];
4086
4169
  const TG_HEADING_TYPES = [
4087
- "headingXxsmall",
4088
- "headingXsmall",
4089
- "headingSmall",
4090
- "headingMedium",
4091
- "headingLarge",
4092
- "headingXlarge",
4093
- "headingXxlarge"
4170
+ "heading-xxsmall",
4171
+ "heading-xsmall",
4172
+ "heading-small",
4173
+ "heading-medium",
4174
+ "heading-large",
4175
+ "heading-xlarge",
4176
+ "heading-xxlarge"
4094
4177
  ];
4095
4178
  //#endregion
4096
4179
  //#region src/components/Typography/Typography/Typography.utils.ts
4097
4180
  const getElementType = (element) => {
4098
4181
  switch (element) {
4099
4182
  case "a": return "a";
4100
- case "headingXxsmall": return "h6";
4101
- case "headingXsmall": return "h5";
4102
- case "headingSmall": return "h4";
4103
- case "headingMedium": return "h3";
4104
- case "headingLarge": return "h2";
4105
- case "headingXlarge":
4106
- case "headingXxlarge": return "h1";
4107
- case "labelMedium": return "label";
4183
+ case "heading-xxsmall": return "h6";
4184
+ case "heading-xsmall": return "h5";
4185
+ case "heading-small": return "h4";
4186
+ case "heading-medium": return "h3";
4187
+ case "heading-large": return "h2";
4188
+ case "heading-xlarge":
4189
+ case "heading-xxlarge": return "h1";
4190
+ case "label-medium": return "label";
4108
4191
  default: return "p";
4109
4192
  }
4110
4193
  };
@@ -4173,9 +4256,6 @@ const inlineElements = [
4173
4256
  "wbr"
4174
4257
  ];
4175
4258
  const isInlineElement = (as) => inlineElements.indexOf(as) !== -1;
4176
- function getTypographyCn(value) {
4177
- return convertCamelToHyphen(value);
4178
- }
4179
4259
  const getColorCn = (color) => {
4180
4260
  if (!isTextColor(color)) return null;
4181
4261
  const [prefix] = color.split("-", 1);
@@ -4185,13 +4265,12 @@ const getColorCn = (color) => {
4185
4265
  //#region src/components/Typography/Typography/Typography.tsx
4186
4266
  const isAnchorProps = (props) => props.typographyType === "a";
4187
4267
  const Typography = (props) => {
4188
- const { typographyType = "bodyLongMedium", as: propAs, children, bold, underline, italic, style, id, withMargins, color, className, htmlProps = {}, ...rest } = props;
4268
+ const { typographyType = "body-long-medium", as: propAs, children, bold, underline, italic, style, id, withMargins, color, className, htmlProps = {}, ...rest } = props;
4189
4269
  const as = propAs ? propAs : getElementType(typographyType);
4190
- const typographyCn = getTypographyCn(typographyType);
4191
4270
  let relProp;
4192
4271
  if (isAnchorProps(props)) relProp = as === "a" ? "noopener noreferer" : void 0;
4193
4272
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4194
- ...getBaseHTMLProps(id, cn(className, getColorCn(color), Typography_module_default.container, typographyStyles_module_default[typographyCn], withMargins && typographyStyles_module_default[`${typographyCn}--margins`], isLegend(as) && typographyStyles_module_default.legend, isCaption(as) && typographyStyles_module_default.caption, isCaption(as) && withMargins && typographyStyles_module_default["caption--withMargins"], bold && typographyStyles_module_default.bold, underline && typographyStyles_module_default.underline, italic && typographyStyles_module_default.italic, as === "a" && "dds-focus-module__focusable"), {
4273
+ ...getBaseHTMLProps(id, cn(className, getColorCn(color), Typography_module_default.container, typographyStyles_module_default[typographyType], withMargins && typographyStyles_module_default[`${typographyType}--margins`], isLegend(as) && typographyStyles_module_default.legend, isCaption(as) && typographyStyles_module_default.caption, isCaption(as) && withMargins && typographyStyles_module_default["caption--withMargins"], bold && typographyStyles_module_default.bold, underline && typographyStyles_module_default.underline, italic && typographyStyles_module_default.italic, as === "a" && "dds-focus-module__focusable"), {
4195
4274
  ...style,
4196
4275
  color: color && !isTextColor(color) ? getTextColor(color) : void 0
4197
4276
  }, htmlProps, rest),
@@ -4206,7 +4285,7 @@ Typography.displayName = "Typography";
4206
4285
  const Caption = ({ id, className, style, htmlProps, children, ...rest }) => {
4207
4286
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
4208
4287
  ...getBaseHTMLProps(id, className, style, htmlProps, rest),
4209
- typographyType: "headingLarge",
4288
+ typographyType: "heading-large",
4210
4289
  as: "caption",
4211
4290
  children
4212
4291
  });
@@ -4217,13 +4296,13 @@ Caption.displayName = "Caption";
4217
4296
  const getHeadingElement = (level) => `h${level}`;
4218
4297
  const getDefaultTypographyType = (h) => {
4219
4298
  switch (h) {
4220
- case "h1": return "headingXlarge";
4221
- case "h2": return "headingLarge";
4222
- case "h3": return "headingMedium";
4223
- case "h4": return "headingSmall";
4224
- case "h5": return "headingXsmall";
4225
- case "h6": return "headingXxsmall";
4226
- default: return "headingXlarge";
4299
+ case "h1": return "heading-xlarge";
4300
+ case "h2": return "heading-large";
4301
+ case "h3": return "heading-medium";
4302
+ case "h4": return "heading-small";
4303
+ case "h5": return "heading-xsmall";
4304
+ case "h6": return "heading-xxsmall";
4305
+ default: return "heading-xlarge";
4227
4306
  }
4228
4307
  };
4229
4308
  const Heading = ({ id, className, style, htmlProps, children, typographyType, level, withMargins, withMarginsOverInput, ...rest }) => {
@@ -4258,25 +4337,25 @@ const Label = ({ showRequiredStyling, readOnly, id, className, style, htmlProps,
4258
4337
  ] });
4259
4338
  const labelProps = { ...getBaseHTMLProps(id, cn(className, readOnly && Label_module_default["read-only"]), style, htmlProps, rest) };
4260
4339
  return afterLabelContent ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Typography, {
4261
- typographyType: "labelMedium",
4340
+ typographyType: "label-medium",
4262
4341
  as: "div",
4263
4342
  withMargins: rest.withMargins,
4264
4343
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
4265
4344
  ...labelProps,
4266
- typographyType: "labelMedium",
4345
+ typographyType: "label-medium",
4267
4346
  withMargins: false,
4268
4347
  children: content
4269
4348
  }), afterLabelContent]
4270
4349
  }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
4271
4350
  ...labelProps,
4272
- typographyType: "labelMedium",
4351
+ typographyType: "label-medium",
4273
4352
  children: content
4274
4353
  });
4275
4354
  };
4276
4355
  Label.displayName = "Label";
4277
4356
  //#endregion
4278
4357
  //#region src/components/Typography/Legend/Legend.tsx
4279
- const Legend = ({ id, className, style, htmlProps, typographyType = "headingLarge", withMarginsOverInput, withMargins, ...rest }) => {
4358
+ const Legend = ({ id, className, style, htmlProps, typographyType = "heading-large", withMarginsOverInput, withMargins, ...rest }) => {
4280
4359
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
4281
4360
  ...getBaseHTMLProps(id, cn(className, withMarginsOverInput && typographyStyles_module_default["legend--margins-over-input"]), style, htmlProps, rest),
4282
4361
  as: "legend",
@@ -4292,7 +4371,7 @@ const Link = ({ id, className, htmlProps, children, typographyType, withMargins,
4292
4371
  const aProps = as === "a" || propIsAnchor ? { rel: "noopener noreferrer" } : {};
4293
4372
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ElementAs, {
4294
4373
  as,
4295
- ...getBaseHTMLProps(id, cn(className, typographyStyles_module_default.a, withIconStyling && typographyStyles_module_default["a--with-icon"], withVisited && typographyStyles_module_default["a--visited"], typographyType && typographyStyles_module_default[getTypographyCn(typographyType)], typographyType && withMargins && typographyStyles_module_default[`${getTypographyCn(typographyType)}--margins`], _key1, getColorCn(color)), {
4374
+ ...getBaseHTMLProps(id, cn(className, typographyStyles_module_default.a, withIconStyling && typographyStyles_module_default["a--with-icon"], withVisited && typographyStyles_module_default["a--visited"], typographyType && typographyStyles_module_default[typographyType], typographyType && withMargins && typographyStyles_module_default[`${typographyType}--margins`], _key1, getColorCn(color)), {
4296
4375
  ...style,
4297
4376
  color: color && !isTextColor(color) ? getTextColor(color) : void 0
4298
4377
  }, htmlProps, rest),
@@ -4301,9 +4380,8 @@ const Link = ({ id, className, htmlProps, children, typographyType, withMargins,
4301
4380
  });
4302
4381
  };
4303
4382
  Link.displayName = "Link";
4304
- //#endregion
4305
- //#region src/components/Typography/Paragraph/Paragraph.tsx
4306
- const Paragraph = ({ id, className, style, htmlProps, children, typographyType = "bodyLongMedium", ...rest }) => {
4383
+ [...TG_BODY_TYPES, ...TG_LEAD_TYPES];
4384
+ const Paragraph = ({ id, className, style, htmlProps, children, typographyType = "body-long-medium", ...rest }) => {
4307
4385
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
4308
4386
  ...getBaseHTMLProps(id, className, style, htmlProps, rest),
4309
4387
  typographyType,
@@ -4312,78 +4390,6 @@ const Paragraph = ({ id, className, style, htmlProps, children, typographyType =
4312
4390
  };
4313
4391
  Paragraph.displayName = "Paragraph";
4314
4392
  //#endregion
4315
- //#region src/components/Accordion/AccordionHeader.tsx
4316
- const AccordionHeader = ({ children, className, style, htmlProps, typographyType = "headingMedium", bold, ...rest }) => {
4317
- const { isExpanded, headerProps } = useAccordionContext();
4318
- const { id, ...restHeaderProps } = headerProps ?? {};
4319
- const iconState = isExpanded ? "up" : "down";
4320
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4321
- as: StylelessButton,
4322
- padding: "x1 x1.5 x1 x1",
4323
- ...getBaseHTMLProps(id, cn(className, Accordion_module_default["header-button"], AccordionBase_module_default["header-button"], _key1), style, htmlProps, rest),
4324
- ...restHeaderProps,
4325
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4326
- className: cn(AccordionBase_module_default.header__content, typographyStyles_module_default[getTypographyCn(typographyType)], bold && typographyStyles_module_default.bold),
4327
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {
4328
- icon: AnimatedChevronUpDownIcon,
4329
- iconSize: "component",
4330
- className: Accordion_module_default.chevron,
4331
- iconState
4332
- }), children]
4333
- })
4334
- });
4335
- };
4336
- AccordionHeader.displayName = "AccordionHeader";
4337
- //#endregion
4338
- //#region src/components/Accordion/AccordionBody.tsx
4339
- const AccordionBody = ({ children, className, style, htmlProps, ...rest }) => {
4340
- const { bodyContentRef, bodyProps } = useAccordionContext();
4341
- const { className: bodyContextCn, id, height, ...restBodyProps } = bodyProps ?? {};
4342
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4343
- height: `${height}px`,
4344
- ...getBaseHTMLProps(id, cn(className, bodyContextCn), style, htmlProps, rest),
4345
- ...restBodyProps,
4346
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Box, {
4347
- ref: bodyContentRef,
4348
- padding: "x0.5 x1.5 x2 x1",
4349
- children
4350
- })
4351
- });
4352
- };
4353
- AccordionBody.displayName = "AccordionBody";
4354
- //#endregion
4355
- //#region src/components/BackLink/BackLink.module.css
4356
- var BackLink_module_default = { "icon": "dds-BackLink-module__icon" };
4357
- //#endregion
4358
- //#region src/components/BackLink/BackLink.tsx
4359
- const BackLink = ({ label, ref, as = "a", ...rest }) => {
4360
- const { t } = useTranslation();
4361
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("nav", {
4362
- ref,
4363
- "aria-label": t(texts$29.goBack),
4364
- className: typographyStyles_module_default["body-short-medium"],
4365
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
4366
- as,
4367
- className: cn(typographyStyles_module_default.a, _key1),
4368
- rel: "noopener noreferer",
4369
- ...rest,
4370
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {
4371
- icon: ArrowLeftIcon,
4372
- iconSize: "component",
4373
- className: cn(BackLink_module_default.icon)
4374
- }), label]
4375
- })
4376
- });
4377
- };
4378
- BackLink.displayName = "BackLink";
4379
- const texts$29 = createTexts({ goBack: {
4380
- nb: "Gå tilbake",
4381
- no: "Gå tilbake",
4382
- nn: "Gå tilbake",
4383
- en: "Go back",
4384
- se: "Mana ruovttoluotta"
4385
- } });
4386
- //#endregion
4387
4393
  //#region src/components/Breadcrumbs/Breadcrumb.tsx
4388
4394
  const isAnchorTypographyProps = (props) => {
4389
4395
  return props.href != void 0;
@@ -5020,7 +5026,7 @@ const CardExpandable = ({ isInitiallyExpanded = false, isExpanded, onChange, id,
5020
5026
  CardExpandable.displayName = "CardExpandable";
5021
5027
  //#endregion
5022
5028
  //#region src/components/Card/CardExpandable/CardExpandableHeader.tsx
5023
- const CardExpandableHeader = ({ children, className, style, htmlProps, padding, typographyType = "headingLarge", bold, ...rest }) => {
5029
+ const CardExpandableHeader = ({ children, className, style, htmlProps, padding, typographyType = "heading-large", bold, ...rest }) => {
5024
5030
  const { isExpanded, headerProps } = useAccordionContext();
5025
5031
  const containerStyleVariables = { ["--dds-card-accordion-header-container-padding"]: padding ?? "var(--dds-spacing-x1) var(--dds-spacing-x0-75) var(--dds-spacing-x1) var(--dds-spacing-x1-5)" };
5026
5032
  const { id, ...restHeaderProps } = headerProps ?? {};
@@ -5031,7 +5037,7 @@ const CardExpandableHeader = ({ children, className, style, htmlProps, padding,
5031
5037
  type: "button",
5032
5038
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
5033
5039
  style: containerStyleVariables,
5034
- className: cn(CardExpandable_module_default["header-container"], typographyStyles_module_default[getTypographyCn(typographyType)], bold && typographyStyles_module_default.bold),
5040
+ className: cn(CardExpandable_module_default["header-container"], typographyStyles_module_default[typographyType], bold && typographyStyles_module_default.bold),
5035
5041
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5036
5042
  className: (AccordionBase_module_default.header__content, CardExpandable_module_default.header__content),
5037
5043
  children: [children, /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Icon, {
@@ -5102,7 +5108,7 @@ const Label$1 = ({ disabled, hasText, controlType, className, ...rest }) => {
5102
5108
  const renderGroupLabel = ({ id, showRequiredStyling, readOnly, label }) => {
5103
5109
  if (!!label) return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Typography, {
5104
5110
  as: "span",
5105
- typographyType: "labelMedium",
5111
+ typographyType: "label-medium",
5106
5112
  id,
5107
5113
  className: readOnly ? Label_module_default["read-only"] : void 0,
5108
5114
  withMargins: true,
@@ -5123,7 +5129,7 @@ const renderGroupLabel = ({ id, showRequiredStyling, readOnly, label }) => {
5123
5129
  //#region src/components/SelectionControl/SelectionControl.utils.tsx
5124
5130
  const selectionControlTypographyProps = {
5125
5131
  color: "inherit",
5126
- typographyType: "bodyShortMedium",
5132
+ typographyType: "body-short-medium",
5127
5133
  as: "span"
5128
5134
  };
5129
5135
  //#endregion
@@ -5214,7 +5220,7 @@ const InputMessage = ({ messageType, id, className, style, htmlProps, children,
5214
5220
  ...commonProps,
5215
5221
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
5216
5222
  ...tgCommonProps,
5217
- typographyType: "bodyShortXsmall",
5223
+ typographyType: "body-short-xsmall",
5218
5224
  color: "text-subtle"
5219
5225
  })
5220
5226
  });
@@ -5585,11 +5591,11 @@ function CookieBannerCheckbox({ headerText, description, id, className, style, h
5585
5591
  gap: "x0.5",
5586
5592
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
5587
5593
  as: "span",
5588
- typographyType: "headingSmall",
5594
+ typographyType: "heading-small",
5589
5595
  children: headerText
5590
5596
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
5591
5597
  as: "span",
5592
- typographyType: "bodyLongSmall",
5598
+ typographyType: "body-long-small",
5593
5599
  children: description
5594
5600
  })]
5595
5601
  })
@@ -5607,7 +5613,7 @@ function CookieBanner({ headerText, description, buttons, checkboxes, id, classN
5607
5613
  const headingId = headerText && (id ?? `cookie-banner-${generatedId}-heading`);
5608
5614
  const heading = headerText ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
5609
5615
  level: 2,
5610
- typographyType: "headingMedium",
5616
+ typographyType: "heading-medium",
5611
5617
  id: headingId,
5612
5618
  children: headerText
5613
5619
  }) : "";
@@ -6105,7 +6111,7 @@ function Calendar(props) {
6105
6111
  }),
6106
6112
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
6107
6113
  level: 2,
6108
- typographyType: "headingXsmall",
6114
+ typographyType: "heading-xsmall",
6109
6115
  className: DateInput_module_default.calendar__header__month,
6110
6116
  children: title
6111
6117
  }),
@@ -6839,7 +6845,7 @@ const Drawer = ({ children, header, placement = "right", parentElement, size = "
6839
6845
  id: headerId,
6840
6846
  children: typeof header === "string" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
6841
6847
  level: 2,
6842
- typographyType: "headingLarge",
6848
+ typographyType: "heading-large",
6843
6849
  children: header
6844
6850
  }) : header
6845
6851
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
@@ -6932,7 +6938,7 @@ function EmptyContent({ headerText, children, headerHeadingLevel = 2, ...rest })
6932
6938
  className: typographyStyles_module_default["text-color--medium"],
6933
6939
  children: [headerText && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
6934
6940
  level: headerHeadingLevel,
6935
- typographyType: "headingMedium",
6941
+ typographyType: "heading-medium",
6936
6942
  children: headerText
6937
6943
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
6938
6944
  as: "div",
@@ -6960,7 +6966,7 @@ var List_module_default = {
6960
6966
  const List = ({ listType = "unordered", typographyType = "inherit", children, id, className, style, htmlProps, ...rest }) => {
6961
6967
  return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(listType === "ordered" ? "ol" : "ul", {
6962
6968
  ...getBaseHTMLProps(id, className, style, htmlProps, rest),
6963
- className: cn(List_module_default.list, List_module_default[`list--${listType}`], typographyType === "inherit" ? List_module_default["list--inherit"] : typographyStyles_module_default[getTypographyCn(typographyType)]),
6969
+ className: cn(List_module_default.list, List_module_default[`list--${listType}`], typographyType === "inherit" ? List_module_default["list--inherit"] : typographyStyles_module_default[typographyType]),
6964
6970
  children
6965
6971
  });
6966
6972
  };
@@ -6978,11 +6984,11 @@ const ErrorSummary = ({ heading: pHeading, className, style, children, id, htmlP
6978
6984
  const { t } = useTranslation();
6979
6985
  const heading = typeof pHeading === "string" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
6980
6986
  level: 2,
6981
- typographyType: "headingSmall",
6987
+ typographyType: "heading-small",
6982
6988
  children: pHeading
6983
6989
  }) : pHeading ? pHeading : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
6984
6990
  level: 2,
6985
- typographyType: "headingSmall",
6991
+ typographyType: "heading-small",
6986
6992
  children: t(texts$20.toProceedCorrectErrors)
6987
6993
  });
6988
6994
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Paper, {
@@ -7088,7 +7094,7 @@ function CharCounter(props) {
7088
7094
  id: id ?? `${generatedId}-characterCounter`,
7089
7095
  className: CharCounter_module_default.container,
7090
7096
  as: "div",
7091
- typographyType: "bodyShortXsmall",
7097
+ typographyType: "body-short-xsmall",
7092
7098
  color: "text-subtle",
7093
7099
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
7094
7100
  "aria-hidden": true,
@@ -8104,7 +8110,7 @@ const Footer = ({ className, ...rest }) => /* @__PURE__ */ (0, react_jsx_runtime
8104
8110
  //#region src/components/Footer/FooterListHeader.tsx
8105
8111
  const FooterListHeader = (props) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
8106
8112
  level: 2,
8107
- typographyType: "headingSmall",
8113
+ typographyType: "heading-small",
8108
8114
  ...props
8109
8115
  });
8110
8116
  //#endregion
@@ -8657,7 +8663,7 @@ const InternalHeader = (props) => {
8657
8663
  ...getBaseHTMLProps(id, cn(className, InternalHeader_module_default.bar, !!navigation && InternalHeader_module_default["bar--with-nav"]), style, htmlProps, rest),
8658
8664
  children: [
8659
8665
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
8660
- typographyType: "headingSmall",
8666
+ typographyType: "heading-small",
8661
8667
  bold: true,
8662
8668
  as: "span",
8663
8669
  children: applicationHref ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
@@ -8668,7 +8674,7 @@ const InternalHeader = (props) => {
8668
8674
  }) : applicationName
8669
8675
  }),
8670
8676
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
8671
- typographyType: "bodyShortMedium",
8677
+ typographyType: "body-short-medium",
8672
8678
  as: "span",
8673
8679
  children: applicationDesc
8674
8680
  }),
@@ -8881,7 +8887,7 @@ const Modal = ({ isOpen = false, parentElement, children, header, onClose, id, t
8881
8887
  id: headerId,
8882
8888
  children: typeof header === "string" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
8883
8889
  level: 2,
8884
- typographyType: "headingLarge",
8890
+ typographyType: "heading-large",
8885
8891
  children: header
8886
8892
  }) : header
8887
8893
  }), onClose && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
@@ -9019,7 +9025,7 @@ const NewsPopover = ({ id, className, style, htmlProps, header, news, defaultAct
9019
9025
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
9020
9026
  id: headerId,
9021
9027
  level: 2,
9022
- typographyType: "headingSmall",
9028
+ typographyType: "heading-small",
9023
9029
  children: header
9024
9030
  })
9025
9031
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
@@ -9839,7 +9845,7 @@ const Pagination = ({ itemsAmount, defaultItemsPerPage = 10, defaultActivePage =
9839
9845
  componentSize: "small",
9840
9846
  "aria-label": t(texts$8.itemsPerPage)
9841
9847
  }), withCounter && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Paragraph, {
9842
- typographyType: "bodyShortMedium",
9848
+ typographyType: "body-short-medium",
9843
9849
  children: t(texts$8.showsAmountOfTotalItems(activePageFirstItem, activePageLastItem, itemsAmount))
9844
9850
  })]
9845
9851
  }), navigation]
@@ -11409,7 +11415,7 @@ const Popover = ({ id, header, withCloseButton = true, onBlur, children, placeme
11409
11415
  className: Popover_module_default.header,
11410
11416
  children: typeof header === "string" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading, {
11411
11417
  level: 2,
11412
- typographyType: "headingMedium",
11418
+ typographyType: "heading-medium",
11413
11419
  children: header
11414
11420
  }) : header
11415
11421
  }),
@@ -11575,7 +11581,7 @@ const ProgressTrackerItem = (props) => {
11575
11581
  children: stepNumberContent
11576
11582
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
11577
11583
  as: "div",
11578
- typographyType: "bodyShortMedium",
11584
+ typographyType: "body-short-medium",
11579
11585
  className: cn(ProgressTracker_module_default["item-text"], typographyStyles_module_default["a--nested__child"], isInactiveLink && ProgressTracker_module_default["item-text--inactive-link"]),
11580
11586
  color: getTextColor(),
11581
11587
  children
@@ -12060,7 +12066,7 @@ const SkipToContent = ({ text = "Til hovedinnhold", top = 0, id, className, html
12060
12066
  ...rest,
12061
12067
  ...htmlProps,
12062
12068
  id,
12063
- typographyType: "bodyShortMedium",
12069
+ typographyType: "body-short-medium",
12064
12070
  children: text
12065
12071
  })
12066
12072
  });
@@ -12856,7 +12862,7 @@ const ToggleBar = (props) => {
12856
12862
  children: [label && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Typography, {
12857
12863
  id: labelId,
12858
12864
  as: "span",
12859
- typographyType: "labelMedium",
12865
+ typographyType: "label-medium",
12860
12866
  children: label
12861
12867
  }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Grid, {
12862
12868
  defaultPageLayout: false,
@@ -13273,7 +13279,11 @@ exports.StylelessOList = StylelessOList;
13273
13279
  exports.SunIcon = SunIcon;
13274
13280
  exports.SupportIcon = SupportIcon;
13275
13281
  exports.SyncIcon = SyncIcon;
13282
+ exports.TG_BODY_LONG_TYPES = TG_BODY_LONG_TYPES;
13283
+ exports.TG_BODY_SHORT_TYPES = TG_BODY_SHORT_TYPES;
13284
+ exports.TG_BODY_TYPES = TG_BODY_TYPES;
13276
13285
  exports.TG_HEADING_TYPES = TG_HEADING_TYPES;
13286
+ exports.TG_LEAD_TYPES = TG_LEAD_TYPES;
13277
13287
  exports.Tab = Tab;
13278
13288
  exports.TabList = TabList;
13279
13289
  exports.TabPanel = TabPanel;
@@ -13335,7 +13345,6 @@ exports.focusVisibleTransitionValue = focusVisibleTransitionValue;
13335
13345
  exports.getBaseHTMLProps = getBaseHTMLProps;
13336
13346
  exports.getColorCn = getColorCn;
13337
13347
  exports.getElementType = getElementType;
13338
- exports.getTypographyCn = getTypographyCn;
13339
13348
  exports.handleElementWithBackdropMount = handleElementWithBackdropMount;
13340
13349
  exports.handleElementWithBackdropUnmount = handleElementWithBackdropUnmount;
13341
13350
  exports.hideInput = hideInput;