@altinn/altinn-components 0.33.4 → 0.33.5

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.
@@ -0,0 +1 @@
1
+ ._icon_c8ubg_1{position:relative}._icon_c8ubg_1[data-size=lg]{font-size:2.75rem}._icon_c8ubg_1[data-size=lg] svg,._icon_c8ubg_1[data-size=lg] img{font-size:1.75rem}._icon_c8ubg_1[data-size=md]{font-size:2rem}._icon_c8ubg_1[data-size=md] svg,._icon_c8ubg_1[data-size=md] img{font-size:1.5rem}._icon_c8ubg_1[data-size=sm]{font-size:1.5rem}._icon_c8ubg_1[data-size=sm] svg,._icon_c8ubg_1[data-size=sm] img{font-size:1.25rem}._avatarGroup_c8ubg_32{font-size:.75em}._badge_c8ubg_36{position:absolute;top:0;right:0;margin-top:-.25em;margin-right:-.25em;outline:1px solid white}
@@ -1 +1 @@
1
- ._icon_c8ubg_1{position:relative}._icon_c8ubg_1[data-size=lg]{font-size:2.75rem}._icon_c8ubg_1[data-size=lg] svg,._icon_c8ubg_1[data-size=lg] img{font-size:1.75rem}._icon_c8ubg_1[data-size=md]{font-size:2rem}._icon_c8ubg_1[data-size=md] svg,._icon_c8ubg_1[data-size=md] img{font-size:1.5rem}._icon_c8ubg_1[data-size=sm]{font-size:1.5rem}._icon_c8ubg_1[data-size=sm] svg,._icon_c8ubg_1[data-size=sm] img{font-size:1.25rem}._avatarGroup_c8ubg_32{font-size:.75em}._badge_c8ubg_36{position:absolute;top:0;right:0;margin-top:-.25em;margin-right:-.25em;outline:1px solid white}
1
+ ._icon_1wobj_1{position:relative;min-width:1em;display:flex;align-items:center;justify-content:center}._icon_1wobj_1[data-size=lg]{font-size:2.75rem}._icon_1wobj_1[data-size=lg] svg,._icon_1wobj_1[data-size=lg] img{font-size:1.75rem}._icon_1wobj_1[data-size=md]{font-size:2rem}._icon_1wobj_1[data-size=md] svg,._icon_1wobj_1[data-size=md] img{font-size:1.5rem}._icon_1wobj_1[data-size=sm]{font-size:1.5rem}._icon_1wobj_1[data-size=sm] svg,._icon_1wobj_1[data-size=sm] img{font-size:1.25rem}._avatarGroup_1wobj_36{font-size:.625em}._badge_1wobj_40{position:absolute;top:0;right:0;margin-top:-.25em;margin-right:-.25em;outline:1px solid white}
@@ -1 +1 @@
1
- ._modal_zkvhc_1{padding:0;width:100%;max-width:450px;border:none;background-color:#fff;border-radius:.5rem;box-shadow:var(--ds-shadow-xs)}._modal_zkvhc_1[data-backdrop-color=inherit]::backdrop{background-color:#111d4640}._modal_zkvhc_1[data-backdrop-color=transparent]::backdrop{background-color:transparent}._modal_zkvhc_1[data-variant=full]{width:100%;max-width:none;height:100%;min-height:unset}._modal_zkvhc_1[data-variant=content]{max-width:1056px;margin:auto}._content_zkvhc_30{position:relative}
1
+ ._modal_1tnpv_1{padding:0;width:100%;max-width:450px;border:none;background-color:#fff;border-radius:.5rem;box-shadow:var(--ds-shadow-xs)}._modal_1tnpv_1[data-backdrop-color=inherit]::backdrop{background-color:#111d4640}._modal_1tnpv_1[data-backdrop-color=transparent]::backdrop{background-color:transparent}._modal_1tnpv_1[data-variant=full]{width:100%;max-width:none;height:100%;min-height:unset}._modal_1tnpv_1[data-variant=content]{max-width:988px;margin:auto}._content_1tnpv_30{position:relative}
@@ -9,7 +9,7 @@ import "../RootProvider/RootProvider.js";
9
9
  import "../Searchbar/AutocompleteBase.js";
10
10
  import "../Snackbar/useSnackbar.js";
11
11
  import { S as c } from "../../XMark-DIqxCTTQ.js";
12
- import '../../assets/MenuItemIcon.css';const _ = "_icon_c8ubg_1", v = "_avatarGroup_c8ubg_32", G = "_badge_c8ubg_36", o = {
12
+ import '../../assets/DashboardIcon.css';const _ = "_icon_c8ubg_1", v = "_avatarGroup_c8ubg_32", G = "_badge_c8ubg_36", o = {
13
13
  icon: _,
14
14
  avatarGroup: v,
15
15
  badge: G
@@ -1,37 +1,29 @@
1
1
  "use client";
2
- import { jsxs as t, jsx as e } from "react/jsx-runtime";
3
- import { useState as u } from "react";
2
+ import { jsxs as m, jsx as o } from "react/jsx-runtime";
3
+ import { useState as u, Fragment as a, createElement as h } from "react";
4
4
  import "../../index-L8X2o7IH.js";
5
- import { Badge as _ } from "../Badge/Badge.js";
6
- import { Byline as y } from "../Byline/Byline.js";
7
5
  import "../RootProvider/RootProvider.js";
8
- import { SeenByLogButton as B } from "./SeenByLogButton.js";
6
+ import { SeenByLogButton as p } from "./SeenByLogButton.js";
7
+ import { SeenByLogItem as l } from "./SeenByLogItem.js";
8
+ import { Divider as c } from "../Divider/Divider.js";
9
9
  import "../Searchbar/AutocompleteBase.js";
10
- import { List as L } from "../List/List.js";
10
+ import { List as S } from "../List/List.js";
11
11
  import "../Snackbar/useSnackbar.js";
12
- import { Section as S } from "../Page/Section.js";
13
- import '../../assets/SeenByLog.css';const x = "_list_1cnrr_19", j = "_item_1cnrr_25", s = {
14
- list: x,
15
- item: j
16
- }, q = ({ collapsible: c, expanded: m, title: n, items: o, endUserLabel: l = "You" }) => {
17
- const [p, a] = u(m || !c);
18
- return /* @__PURE__ */ t(S, { spacing: 2, children: [
19
- n && /* @__PURE__ */ e("div", { children: /* @__PURE__ */ e(B, { icon: { items: o }, onClick: () => {
20
- a((r) => !r);
21
- }, children: n }) }),
22
- p && /* @__PURE__ */ e(L, { className: s.list, children: o == null ? void 0 : o.map((r) => {
23
- const { id: d, name: i, seenAt: g, seenAtLabel: h, isEndUser: f } = r;
24
- return /* @__PURE__ */ t("li", { className: s.item, children: [
25
- /* @__PURE__ */ t(y, { size: "sm", datetime: g, avatar: { name: i, type: "person" }, children: [
26
- /* @__PURE__ */ e("strong", { children: i + "," }),
27
- " ",
28
- h
29
- ] }),
30
- f && /* @__PURE__ */ e(_, { theme: "surface", children: l })
31
- ] }, d);
32
- }) })
12
+ import { Flex as x } from "../Page/Flex.js";
13
+ import { Section as y } from "../Page/Section.js";
14
+ const Y = ({ collapsible: i, expanded: d, title: e, items: r, endUserLabel: g = "You" }) => {
15
+ const [t, s] = u(d || !i && !0);
16
+ return /* @__PURE__ */ m(y, { spacing: 1, children: [
17
+ e && /* @__PURE__ */ o(x, { children: i ? /* @__PURE__ */ o(p, { icon: { items: r }, as: "button", onClick: () => {
18
+ s((n) => !n);
19
+ }, children: e }) : /* @__PURE__ */ o(p, { icon: { items: r }, as: "div", children: e }) }),
20
+ e && t && /* @__PURE__ */ o(c, {}),
21
+ t && /* @__PURE__ */ o(S, { size: "sm", spacing: 1, children: r == null ? void 0 : r.map((n, f) => /* @__PURE__ */ m(a, { children: [
22
+ f > 0 && /* @__PURE__ */ o(c, {}),
23
+ /* @__PURE__ */ h(l, { ...n, key: n.id, endUserLabel: g })
24
+ ] }, n.id)) })
33
25
  ] });
34
26
  };
35
27
  export {
36
- q as SeenByLog
28
+ Y as SeenByLog
37
29
  };
@@ -2,11 +2,11 @@ import { jsx as o } from "react/jsx-runtime";
2
2
  import "../../index-L8X2o7IH.js";
3
3
  import "react";
4
4
  import "../RootProvider/RootProvider.js";
5
- import { MetaItemLabel as i } from "../Metadata/MetaItemLabel.js";
6
- import { MetaItem as p } from "../Metadata/MetaItem.js";
5
+ import { MetaItemLabel as p } from "../Metadata/MetaItemLabel.js";
6
+ import { MetaItem as s } from "../Metadata/MetaItem.js";
7
7
  import "../Searchbar/AutocompleteBase.js";
8
8
  import "../Snackbar/useSnackbar.js";
9
- const B = ({ icon: r, children: t, className: m, onClick: e }) => /* @__PURE__ */ o(p, { as: "button", size: "xs", className: m, icon: r, onClick: e, children: t && /* @__PURE__ */ o(i, { size: "xs", children: t }) });
9
+ const L = ({ as: r, icon: m, children: t, className: e, onClick: i }) => /* @__PURE__ */ o(s, { as: r, size: "xs", className: e, icon: m, onClick: i, children: t && /* @__PURE__ */ o(p, { size: "xs", children: t }) });
10
10
  export {
11
- B as SeenByLogButton
11
+ L as SeenByLogButton
12
12
  };
@@ -0,0 +1,23 @@
1
+ import { jsxs as e, jsx as o } from "react/jsx-runtime";
2
+ import "../../index-L8X2o7IH.js";
3
+ import "react";
4
+ import { Badge as s } from "../Badge/Badge.js";
5
+ import { Byline as a } from "../Byline/Byline.js";
6
+ import "../RootProvider/RootProvider.js";
7
+ import "../Searchbar/AutocompleteBase.js";
8
+ import "../Snackbar/useSnackbar.js";
9
+ import { Flex as l } from "../Page/Flex.js";
10
+ const j = ({ name: r, seenAt: i, seenAtLabel: m, isEndUser: n, endUserLabel: p }) => {
11
+ const t = n && { label: p };
12
+ return /* @__PURE__ */ e(l, { align: "center", spacing: 2, children: [
13
+ /* @__PURE__ */ e(a, { size: "sm", datetime: i, avatar: { name: r, type: "person" }, children: [
14
+ /* @__PURE__ */ o("strong", { children: r + "," }),
15
+ " ",
16
+ m
17
+ ] }),
18
+ t && /* @__PURE__ */ o(s, { variant: "subtle", ...t })
19
+ ] });
20
+ };
21
+ export {
22
+ j as SeenByLogItem
23
+ };
@@ -1,13 +1,13 @@
1
1
  import { Dialog as t } from "./Dialog.js";
2
2
  import { DialogLayout as i } from "./DialogLayout.js";
3
3
  import { DialogHeader as m } from "./DialogHeader.js";
4
- import { DialogBody as l } from "./DialogBody.js";
5
- import { DialogTabs as f } from "./DialogTabs.js";
4
+ import { DialogBody as p } from "./DialogBody.js";
5
+ import { DialogTabs as l } from "./DialogTabs.js";
6
6
  import { DialogSection as D } from "./DialogSection.js";
7
7
  import { DialogContact as s } from "./DialogContact.js";
8
8
  import { DialogHistory as S } from "./DialogHistory.js";
9
- import { DialogHistorySegment as c } from "./DialogHistorySegment.js";
10
- import { DialogHistoryItem as B } from "./DialogHistoryItem.js";
9
+ import { DialogHistorySegment as B } from "./DialogHistorySegment.js";
10
+ import { DialogHistoryItem as u } from "./DialogHistoryItem.js";
11
11
  import { DialogList as d } from "./DialogList.js";
12
12
  import { DialogListGroup as I } from "./DialogListGroup.js";
13
13
  import { DialogListItem as h } from "./DialogListItem.js";
@@ -21,18 +21,19 @@ import { DialogStatus as K, DialogStatusEnum as N } from "./DialogStatus.js";
21
21
  import { DialogAttachments as P } from "./DialogAttachments.js";
22
22
  import { SeenByLog as R } from "./SeenByLog.js";
23
23
  import { SeenByLogButton as V } from "./SeenByLogButton.js";
24
+ import { SeenByLogItem as X } from "./SeenByLogItem.js";
24
25
  export {
25
26
  t as Dialog,
26
27
  T as DialogActions,
27
28
  k as DialogActivityLog,
28
29
  P as DialogAttachments,
29
- l as DialogBody,
30
+ p as DialogBody,
30
31
  G as DialogByline,
31
32
  s as DialogContact,
32
33
  m as DialogHeader,
33
34
  S as DialogHistory,
34
- B as DialogHistoryItem,
35
- c as DialogHistorySegment,
35
+ u as DialogHistoryItem,
36
+ B as DialogHistorySegment,
36
37
  i as DialogLayout,
37
38
  d as DialogList,
38
39
  I as DialogListGroup,
@@ -43,7 +44,8 @@ export {
43
44
  F as DialogSelect,
44
45
  K as DialogStatus,
45
46
  N as DialogStatusEnum,
46
- f as DialogTabs,
47
+ l as DialogTabs,
47
48
  R as SeenByLog,
48
- V as SeenByLogButton
49
+ V as SeenByLogButton,
50
+ X as SeenByLogItem
49
51
  };
@@ -1,26 +1,26 @@
1
- import { jsx as a, jsxs as i } from "react/jsx-runtime";
1
+ import { jsx as o, jsxs as i } from "react/jsx-runtime";
2
2
  import { isValidElement as n } from "react";
3
- import { Icon as s, isIconProps as u } from "../Icon/Icon.js";
3
+ import { Icon as s, isIconProps as f } from "../Icon/Icon.js";
4
4
  import "../../index-L8X2o7IH.js";
5
- import { isAvatarProps as f, Avatar as g } from "../Avatar/Avatar.js";
6
- import { isAvatarGroupProps as l, AvatarGroup as d } from "../Avatar/AvatarGroup.js";
7
- import { Badge as c } from "../Badge/Badge.js";
5
+ import { isAvatarProps as l, Avatar as u } from "../Avatar/Avatar.js";
6
+ import { isAvatarGroupProps as d, AvatarGroup as g } from "../Avatar/AvatarGroup.js";
7
+ import { Badge as _ } from "../Badge/Badge.js";
8
8
  import "../RootProvider/RootProvider.js";
9
9
  import "../Searchbar/AutocompleteBase.js";
10
10
  import "../Snackbar/useSnackbar.js";
11
- import { S as _ } from "../../XMark-DIqxCTTQ.js";
12
- import '../../assets/MenuItemIcon.css';const b = "_icon_c8ubg_1", v = "_avatarGroup_c8ubg_32", G = "_badge_c8ubg_36", o = {
13
- icon: b,
14
- avatarGroup: v,
11
+ import { S as b } from "../../XMark-DIqxCTTQ.js";
12
+ import '../../assets/MenuItemIcon.css';const v = "_icon_1wobj_1", c = "_avatarGroup_1wobj_36", G = "_badge_1wobj_40", a = {
13
+ icon: v,
14
+ avatarGroup: c,
15
15
  badge: G
16
16
  };
17
- function N(t) {
17
+ function j(t) {
18
18
  return typeof t == "string" || typeof t == "number" || typeof t == "boolean" || t === null || n(t);
19
19
  }
20
- const z = ({ loading: t, size: p, icon: r, theme: e, badge: m }) => r ? t ? /* @__PURE__ */ a(s, { className: o.icon, svgElement: _, loading: !0 }) : /* @__PURE__ */ i("div", { className: o.icon, "data-size": p, children: [
21
- f(r) && /* @__PURE__ */ a(g, { ...r }) || l(r) && /* @__PURE__ */ a(d, { ...r, className: o.avatarGroup }) || u(r) && /* @__PURE__ */ a(s, { ...r, theme: (r == null ? void 0 : r.theme) || e }) || N(r) && r || /* @__PURE__ */ a(s, { theme: e, svgElement: r }),
22
- m && /* @__PURE__ */ a(c, { ...m, className: o.badge })
20
+ const k = ({ loading: t, size: p, icon: r, theme: e, badge: m }) => r ? t ? /* @__PURE__ */ o(s, { className: a.icon, svgElement: b, loading: !0 }) : /* @__PURE__ */ i("div", { className: a.icon, "data-size": p, children: [
21
+ l(r) && /* @__PURE__ */ o(u, { ...r }) || d(r) && /* @__PURE__ */ o(g, { ...r, className: a.avatarGroup }) || f(r) && /* @__PURE__ */ o(s, { ...r, theme: (r == null ? void 0 : r.theme) || e }) || j(r) && r || /* @__PURE__ */ o(s, { theme: e, svgElement: r }),
22
+ m && /* @__PURE__ */ o(_, { ...m, className: a.badge })
23
23
  ] }) : null;
24
24
  export {
25
- z as MenuItemIcon
25
+ k as MenuItemIcon
26
26
  };
@@ -6,20 +6,20 @@ import "../RootProvider/RootProvider.js";
6
6
  import "../Searchbar/AutocompleteBase.js";
7
7
  import "../Snackbar/useSnackbar.js";
8
8
  import { Section as x } from "../Page/Section.js";
9
- import '../../assets/ModalBase.css';const R = "_modal_zkvhc_1", z = "_content_zkvhc_30", d = {
9
+ import '../../assets/ModalBase.css';const R = "_modal_1tnpv_1", I = "_content_1tnpv_30", d = {
10
10
  modal: R,
11
- content: z
12
- }, Y = ({
11
+ content: I
12
+ }, z = ({
13
13
  open: c,
14
14
  onClose: a,
15
15
  closedBy: n = "any",
16
16
  children: p,
17
17
  backdropColor: v = "inherit",
18
- size: h,
19
- color: E,
20
- padding: k = 0,
21
- spacing: y = 0,
22
- variant: b = "default"
18
+ size: E,
19
+ color: h,
20
+ padding: y = 0,
21
+ spacing: b = 0,
22
+ variant: k = "default"
23
23
  }) => {
24
24
  const r = S(null);
25
25
  return u(() => {
@@ -53,17 +53,17 @@ import '../../assets/ModalBase.css';const R = "_modal_zkvhc_1", z = "_content_zk
53
53
  },
54
54
  "data-backdrop-color": v,
55
55
  className: d.modal,
56
- "data-variant": b,
56
+ "data-variant": k,
57
57
  onClose: n !== "none" ? a : void 0,
58
58
  children: /* @__PURE__ */ f(
59
59
  x,
60
60
  {
61
61
  className: d.content,
62
62
  "aria-label": "modal content",
63
- size: h,
64
- color: E,
65
- padding: k,
66
- spacing: y,
63
+ size: E,
64
+ color: h,
65
+ padding: y,
66
+ spacing: b,
67
67
  children: p
68
68
  }
69
69
  )
@@ -71,5 +71,5 @@ import '../../assets/ModalBase.css';const R = "_modal_zkvhc_1", z = "_content_zk
71
71
  );
72
72
  };
73
73
  export {
74
- Y as ModalBase
74
+ z as ModalBase
75
75
  };
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { jsx as i, jsxs as n, Fragment as g } from "react/jsx-runtime";
2
+ import { jsx as o, jsxs as n, Fragment as g } from "react/jsx-runtime";
3
3
  import { useState as h } from "react";
4
4
  import "../../index-L8X2o7IH.js";
5
5
  import { AttachmentList as v } from "../Attachment/AttachmentList.js";
@@ -15,7 +15,7 @@ import { TransmissionType as j } from "./TransmissionType.js";
15
15
  import '../../assets/Transmission.css';const k = "_title_cy7ua_1", w = {
16
16
  title: k
17
17
  }, O = ({
18
- type: o,
18
+ type: i,
19
19
  unread: l,
20
20
  size: c = "xs",
21
21
  color: p = "neutral",
@@ -31,12 +31,12 @@ import '../../assets/Transmission.css';const k = "_title_cy7ua_1", w = {
31
31
  ...m
32
32
  }) => {
33
33
  const [r, u] = h(m.expanded || !1);
34
- return /* @__PURE__ */ i(
34
+ return /* @__PURE__ */ o(
35
35
  S,
36
36
  {
37
37
  ...m,
38
38
  icon: b,
39
- badge: o && /* @__PURE__ */ i(j, { value: o == null ? void 0 : o.value, label: o == null ? void 0 : o.label }),
39
+ badge: i && /* @__PURE__ */ o(j, { value: i == null ? void 0 : i.value, label: i == null ? void 0 : i.label }),
40
40
  size: c,
41
41
  variant: l ? "subtle" : "default",
42
42
  border: r ? "none" : "solid",
@@ -46,8 +46,8 @@ import '../../assets/Transmission.css';const k = "_title_cy7ua_1", w = {
46
46
  as: "span",
47
47
  className: w.title,
48
48
  children: /* @__PURE__ */ n(g, { children: [
49
- /* @__PURE__ */ i("h2", { children: s }),
50
- l && /* @__PURE__ */ i(L, { variant: "tinted", size: "xs", ...f })
49
+ /* @__PURE__ */ o("h2", { children: s }),
50
+ l && /* @__PURE__ */ o(L, { variant: "tinted", size: "xs", ...f })
51
51
  ] }),
52
52
  weight: l ? "bold" : "normal"
53
53
  },
@@ -58,13 +58,13 @@ import '../../assets/Transmission.css';const k = "_title_cy7ua_1", w = {
58
58
  linkIcon: !0,
59
59
  as: "button",
60
60
  ariaLabel: s,
61
- children: /* @__PURE__ */ n(_, { padding: 4, children: [
61
+ children: /* @__PURE__ */ n(_, { padding: 4, spacing: 4, children: [
62
62
  /* @__PURE__ */ n(T, { size: "md", children: [
63
- a && /* @__PURE__ */ i("p", { children: a }),
63
+ a && /* @__PURE__ */ o("p", { children: a }),
64
64
  r ? typeof t == "function" ? t() : t : null,
65
- (e == null ? void 0 : e.items) && /* @__PURE__ */ i(v, { ...e })
65
+ (e == null ? void 0 : e.items) && /* @__PURE__ */ o(v, { ...e })
66
66
  ] }),
67
- d && /* @__PURE__ */ i(A, { ...d })
67
+ d && /* @__PURE__ */ o(A, { ...d })
68
68
  ] })
69
69
  }
70
70
  );