@altinn/altinn-components 0.7.4 → 0.8.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.
Files changed (162) hide show
  1. package/dist/Autocomplete-DQCs4_zv.js +368 -0
  2. package/dist/assets/Autocomplete.css +1 -1
  3. package/dist/assets/GlobalMenuBase.css +1 -1
  4. package/dist/assets/Header.css +1 -1
  5. package/dist/assets/Heading.css +1 -1
  6. package/dist/assets/HistoryItemBase.css +1 -0
  7. package/dist/assets/HistoryItemMedia.css +1 -0
  8. package/dist/assets/LayoutBase.css +1 -1
  9. package/dist/assets/ListBase.css +1 -1
  10. package/dist/assets/ListItemBase.css +1 -1
  11. package/dist/assets/ListItemLabel.css +1 -1
  12. package/dist/assets/MetaBase.css +1 -1
  13. package/dist/assets/MetaItemBase.css +1 -1
  14. package/dist/assets/MetaItemLabel.css +1 -1
  15. package/dist/assets/QueryLabel.css +1 -1
  16. package/dist/assets/TransmissionItem.css +1 -0
  17. package/dist/components/Attachment/AttachmentLink.d.ts +3 -1
  18. package/dist/components/Attachment/AttachmentLink.js +11 -10
  19. package/dist/components/Attachment/AttachmentLink.stories.js +3 -3
  20. package/dist/components/Attachment/AttachmentList.js +6 -7
  21. package/dist/components/Attachment/AttachmentList.stories.js +1 -1
  22. package/dist/components/Attachment/AttachmentSection.d.ts +6 -0
  23. package/dist/components/Attachment/AttachmentSection.js +12 -0
  24. package/dist/components/{Dialog/DialogAttachments.stories.js → Attachment/AttachmentSection.stories.js} +3 -3
  25. package/dist/components/Attachment/index.d.ts +1 -0
  26. package/dist/components/Attachment/index.js +5 -3
  27. package/dist/components/Bookmarks/BookmarksList.d.ts +1 -3
  28. package/dist/components/Bookmarks/BookmarksList.js +6 -6
  29. package/dist/components/Bookmarks/BookmarksList.stories.js +59 -0
  30. package/dist/components/Bookmarks/BookmarksListItem.d.ts +2 -2
  31. package/dist/components/Bookmarks/BookmarksListItem.js +1 -1
  32. package/dist/components/Bookmarks/BookmarksListItem.stories.js +1 -2
  33. package/dist/components/Bookmarks/BookmarksSection.js +20 -0
  34. package/dist/components/Bookmarks/BookmarksSection.stories.js +61 -0
  35. package/dist/components/Bookmarks/QueryLabel.js +10 -10
  36. package/dist/components/Bookmarks/index.js +1 -1
  37. package/dist/components/Button/Buttons.stories.js +1 -1
  38. package/dist/components/ContextMenu/ContextMenu.js +1 -1
  39. package/dist/components/ContextMenu/ContextMenu.stories.js +1 -1
  40. package/dist/components/ContextMenu/ContextMenuBase.js +1 -1
  41. package/dist/components/ContextMenu/index.js +1 -1
  42. package/dist/components/Dialog/Dialog.d.ts +7 -4
  43. package/dist/components/Dialog/Dialog.js +34 -28
  44. package/dist/components/Dialog/Dialog.stories.js +183 -16
  45. package/dist/components/Dialog/DialogActions.js +1 -1
  46. package/dist/components/Dialog/DialogActivityLog.d.ts +1 -1
  47. package/dist/components/Dialog/DialogActivityLog.js +7 -2
  48. package/dist/components/Dialog/DialogGroup.js +5 -5
  49. package/dist/components/Dialog/DialogHeadings.stories.js +8 -8
  50. package/dist/components/Dialog/DialogHistory.js +5 -3
  51. package/dist/components/Dialog/DialogList.js +1 -1
  52. package/dist/components/Dialog/DialogListItem.d.ts +11 -5
  53. package/dist/components/Dialog/DialogListItem.js +5 -6
  54. package/dist/components/Dialog/DialogListItem.stories.js +1 -1
  55. package/dist/components/Dialog/DialogMetadata.stories.js +3 -3
  56. package/dist/components/Dialog/DialogNav.js +1 -1
  57. package/dist/components/Dialog/DialogNav.stories.js +1 -1
  58. package/dist/components/Dialog/DialogSeenBy.d.ts +1 -1
  59. package/dist/components/Dialog/DialogSeenBy.js +7 -6
  60. package/dist/components/Dialog/DialogSeenBy.stories.js +5 -5
  61. package/dist/components/Dialog/DialogStatus.stories.js +1 -1
  62. package/dist/components/Dialog/DialogTouchedBy.stories.js +1 -1
  63. package/dist/components/Dialog/index.js +1 -1
  64. package/dist/components/Dropdown/DrawerButton.js +1 -1
  65. package/dist/components/Dropdown/DrawerOrDropdown.js +1 -1
  66. package/dist/components/GlobalMenu/AccountButton.js +1 -1
  67. package/dist/components/GlobalMenu/AccountMenu.d.ts +5 -2
  68. package/dist/components/GlobalMenu/AccountMenu.js +35 -27
  69. package/dist/components/GlobalMenu/AccountMenu.stories.js +19 -2
  70. package/dist/components/GlobalMenu/BackButton.js +1 -1
  71. package/dist/components/GlobalMenu/GlobalMenu.js +1 -1
  72. package/dist/components/GlobalMenu/GlobalMenu.stories.js +6 -12
  73. package/dist/components/GlobalMenu/GlobalMenuBase.js +9 -9
  74. package/dist/components/Header/Header.js +13 -13
  75. package/dist/components/Header/HeaderBase.js +1 -1
  76. package/dist/components/History/HistoryItem.d.ts +10 -10
  77. package/dist/components/History/HistoryItem.js +35 -39
  78. package/dist/components/History/HistoryItem.stories.js +53 -2
  79. package/dist/components/History/HistoryItemBase.d.ts +13 -0
  80. package/dist/components/History/HistoryItemBase.js +36 -0
  81. package/dist/components/History/HistoryItemBase.stories.js +48 -0
  82. package/dist/components/History/HistoryItemMedia.d.ts +9 -0
  83. package/dist/components/History/HistoryItemMedia.js +15 -0
  84. package/dist/components/History/HistoryList.stories.js +123 -26
  85. package/dist/components/History/HistoryMetadata.d.ts +11 -0
  86. package/dist/components/History/HistoryMetadata.js +32 -0
  87. package/dist/components/History/index.d.ts +1 -0
  88. package/dist/components/History/index.js +4 -2
  89. package/dist/components/Layout/Layout.js +1 -1
  90. package/dist/components/Layout/Layout.stories.js +131 -42
  91. package/dist/components/Layout/LayoutBase.js +3 -3
  92. package/dist/components/LayoutAction/ActionMenu.js +1 -1
  93. package/dist/components/List/List.js +4 -4
  94. package/dist/components/List/List.stories.js +1 -1
  95. package/dist/components/List/ListBase.d.ts +6 -2
  96. package/dist/components/List/ListBase.js +5 -5
  97. package/dist/components/List/ListItem.d.ts +8 -8
  98. package/dist/components/List/ListItem.js +2 -4
  99. package/dist/components/List/ListItem.stories.js +26 -25
  100. package/dist/components/List/ListItemBase.d.ts +4 -12
  101. package/dist/components/List/ListItemBase.js +30 -64
  102. package/dist/components/List/ListItemControls.js +2 -2
  103. package/dist/components/List/ListItemHeader.d.ts +35 -2
  104. package/dist/components/List/ListItemHeader.js +7 -29
  105. package/dist/components/List/ListItemHeader.stories.js +248 -0
  106. package/dist/components/List/ListItemLabel.js +7 -6
  107. package/dist/components/List/ListItemMenu.d.ts +8 -0
  108. package/dist/components/List/ListItemMenu.js +5 -0
  109. package/dist/components/List/index.js +14 -15
  110. package/dist/components/Menu/Menu.js +1 -1
  111. package/dist/components/Menu/MenuItem.stories.js +1 -1
  112. package/dist/components/Menu/MenuItems.js +1 -1
  113. package/dist/components/Menu/MenuItems.stories.js +1 -1
  114. package/dist/components/Menu/MenuSearch.js +1 -1
  115. package/dist/components/Menu/index.js +1 -1
  116. package/dist/components/Meta/MetaBase.js +3 -3
  117. package/dist/components/Meta/MetaItem.d.ts +2 -0
  118. package/dist/components/Meta/MetaItemBase.js +11 -11
  119. package/dist/components/Meta/MetaItemLabel.js +3 -3
  120. package/dist/components/Page/PageHeader.js +2 -2
  121. package/dist/components/Searchbar/Autocomplete.js +1 -1
  122. package/dist/components/Searchbar/Autocomplete.stories.js +1 -1
  123. package/dist/components/Searchbar/AutocompleteItem.js +2 -2
  124. package/dist/components/Searchbar/ScopeListItem.d.ts +2 -2
  125. package/dist/components/Searchbar/ScopeListItem.js +1 -1
  126. package/dist/components/Searchbar/Searchbar.js +1 -1
  127. package/dist/components/Toolbar/ToolbarAdd.js +8 -8
  128. package/dist/components/Toolbar/ToolbarDaterange.d.ts +13 -0
  129. package/dist/components/Toolbar/ToolbarDaterange.js +24 -15
  130. package/dist/components/Toolbar/ToolbarFilter.js +7 -7
  131. package/dist/components/Toolbar/ToolbarMenu.js +8 -8
  132. package/dist/components/Toolbar/ToolbarOptions.js +1 -1
  133. package/dist/components/Toolbar/ToolbarSearch.js +1 -1
  134. package/dist/components/Toolbar/index.d.ts +3 -0
  135. package/dist/components/Toolbar/index.js +12 -6
  136. package/dist/components/Transmission/TransmissionItem.d.ts +16 -0
  137. package/dist/components/Transmission/TransmissionItem.js +59 -0
  138. package/dist/components/Transmission/TransmissionItem.stories.js +56 -0
  139. package/dist/components/Transmission/TransmissionList.d.ts +6 -0
  140. package/dist/components/Transmission/TransmissionList.js +12 -0
  141. package/dist/components/Transmission/TransmissionList.stories.js +63 -0
  142. package/dist/components/Transmission/TransmissionSection.d.ts +8 -0
  143. package/dist/components/Transmission/TransmissionSection.js +17 -0
  144. package/dist/components/Transmission/TransmissionSection.stories.js +184 -0
  145. package/dist/components/Transmission/index.d.ts +3 -0
  146. package/dist/components/Transmission/index.js +8 -0
  147. package/dist/components/Typography/Heading.d.ts +1 -1
  148. package/dist/components/Typography/Heading.js +3 -3
  149. package/dist/components/Typography/Typography.d.ts +2 -1
  150. package/dist/components/Typography/Typography.js +7 -7
  151. package/dist/components/index.d.ts +1 -0
  152. package/dist/components/index.js +246 -231
  153. package/dist/index.js +252 -237
  154. package/package.json +1 -1
  155. package/dist/Autocomplete-BNV2UfH3.js +0 -284
  156. package/dist/assets/HistoryItem.css +0 -1
  157. package/dist/assets/ListItemHeader.css +0 -1
  158. package/dist/components/Dialog/DialogAttachments.d.ts +0 -6
  159. package/dist/components/Dialog/DialogAttachments.js +0 -13
  160. package/dist/components/Dialog/Examples.stories.js +0 -31
  161. package/dist/components/History/HistoryAttachments.d.ts +0 -6
  162. package/dist/components/History/HistoryAttachments.js +0 -12
@@ -0,0 +1,13 @@
1
+ import { MouseEventHandler } from 'react';
2
+ export interface ToolbarDaterangeProps {
3
+ title: string;
4
+ label: string;
5
+ value: string | number;
6
+ description?: string;
7
+ fromLabel?: string;
8
+ toLabel?: string;
9
+ onToggle?: MouseEventHandler;
10
+ expanded?: boolean;
11
+ className?: string;
12
+ }
13
+ export declare const ToolbarDaterange: ({ title, description, fromLabel, toLabel, label, value, expanded, onToggle, }: ToolbarDaterangeProps) => import("react/jsx-runtime").JSX.Element;
@@ -3,14 +3,14 @@ import { useState as m } from "react";
3
3
  import "../../index-L8X2o7IH.js";
4
4
  import "../Icon/SvgIcon.js";
5
5
  import "../RootProvider/RootProvider.js";
6
+ import { ToolbarButton as v } from "./ToolbarButton.js";
6
7
  import { MenuInputField as p } from "../Menu/MenuInputField.js";
7
- import { MenuBase as v } from "../Menu/MenuBase.js";
8
- import { DrawerOrDropdown as C } from "../Dropdown/DrawerOrDropdown.js";
9
- import "../../Autocomplete-BNV2UfH3.js";
10
- import { ToolbarButton as F } from "./ToolbarButton.js";
11
- import { ToolbarFilterBase as T } from "./ToolbarFilterBase.js";
8
+ import { MenuBase as C } from "../Menu/MenuBase.js";
9
+ import { ToolbarFilterBase as F } from "./ToolbarFilterBase.js";
10
+ import { DrawerOrDropdown as T } from "../Dropdown/DrawerOrDropdown.js";
11
+ import "../../Autocomplete-DQCs4_zv.js";
12
12
  import { Datepicker as S } from "../Datepicker/Datepicker.js";
13
- import '../../assets/ToolbarDaterange.css';const y = "_datepicker_mqb1p_1", q = "_fields_mqb1p_6", w = "_description_mqb1p_10", c = {
13
+ import '../../assets/ToolbarDaterange.css';const y = "_datepicker_mqb1p_1", q = "_fields_mqb1p_6", w = "_description_mqb1p_10", n = {
14
14
  datepicker: y,
15
15
  fields: q,
16
16
  description: w
@@ -21,7 +21,7 @@ import '../../assets/ToolbarDaterange.css';const y = "_datepicker_mqb1p_1", q =
21
21
  toLabel: D = "To date",
22
22
  label: u = "Select daterange",
23
23
  value: _,
24
- expanded: n = !1,
24
+ expanded: c = !1,
25
25
  onToggle: l
26
26
  }) => {
27
27
  const [t, r] = m(""), [s, a] = m(""), b = (e) => {
@@ -31,16 +31,25 @@ import '../../assets/ToolbarDaterange.css';const y = "_datepicker_mqb1p_1", q =
31
31
  }, k = (e) => {
32
32
  s ? (r(e), a("")) : t && e < t ? (a(t), r(e)) : t ? a(e) : r(e);
33
33
  };
34
- return /* @__PURE__ */ i(T, { expanded: n, children: [
35
- /* @__PURE__ */ o(F, { type: "switch", onToggle: l, active: !!_, children: u }),
36
- /* @__PURE__ */ o(C, { expanded: n, title: d, onClose: l, children: /* @__PURE__ */ i(v, { children: [
37
- /* @__PURE__ */ i("div", { className: c.fields, children: [
38
- /* @__PURE__ */ o(p, { value: t, type: "date", label: h, onChange: b }),
39
- /* @__PURE__ */ o(p, { value: s, type: "date", label: D, onChange: g })
34
+ return /* @__PURE__ */ i(F, { expanded: c, children: [
35
+ /* @__PURE__ */ o(v, { type: "switch", onToggle: l, active: !!_, children: u }),
36
+ /* @__PURE__ */ o(T, { expanded: c, title: d, onClose: l, children: /* @__PURE__ */ i(C, { children: [
37
+ /* @__PURE__ */ i("div", { className: n.fields, children: [
38
+ /* @__PURE__ */ o(
39
+ p,
40
+ {
41
+ name: "fromDate",
42
+ value: t,
43
+ type: "date",
44
+ label: h,
45
+ onChange: b
46
+ }
47
+ ),
48
+ /* @__PURE__ */ o(p, { name: "toDate", value: s, type: "date", label: D, onChange: g })
40
49
  ] }),
41
- /* @__PURE__ */ i("section", { className: c.datepicker, children: [
50
+ /* @__PURE__ */ i("section", { className: n.datepicker, children: [
42
51
  /* @__PURE__ */ o(S, { onSelect: k, selectFrom: t, selectTo: s }),
43
- /* @__PURE__ */ o("p", { className: c.description, children: f })
52
+ /* @__PURE__ */ o("p", { className: n.description, children: f })
44
53
  ] })
45
54
  ] }) })
46
55
  ] });
@@ -3,10 +3,10 @@ import "../../index-L8X2o7IH.js";
3
3
  import "../Icon/SvgIcon.js";
4
4
  import "react";
5
5
  import "../RootProvider/RootProvider.js";
6
- import { DrawerOrDropdown as j } from "../Dropdown/DrawerOrDropdown.js";
7
- import "../../Autocomplete-BNV2UfH3.js";
8
- import { ToolbarButton as O } from "./ToolbarButton.js";
9
- import { ToolbarFilterBase as k } from "./ToolbarFilterBase.js";
6
+ import { ToolbarButton as j } from "./ToolbarButton.js";
7
+ import { ToolbarFilterBase as O } from "./ToolbarFilterBase.js";
8
+ import { DrawerOrDropdown as k } from "../Dropdown/DrawerOrDropdown.js";
9
+ import "../../Autocomplete-DQCs4_zv.js";
10
10
  import { ToolbarOptions as u } from "./ToolbarOptions.js";
11
11
  const w = (t, o) => Array.isArray(o) ? o.join(", ") : o, e = ({
12
12
  expanded: t = !1,
@@ -29,9 +29,9 @@ const w = (t, o) => Array.isArray(o) ? o.join(", ") : o, e = ({
29
29
  checked: Array.isArray(r) ? r.includes(p.value) : p.value === r
30
30
  })
31
31
  ), d = (n == null ? void 0 : n(i, r)) ?? w(i, r);
32
- return /* @__PURE__ */ b(k, { expanded: t, children: [
32
+ return /* @__PURE__ */ b(O, { expanded: t, children: [
33
33
  /* @__PURE__ */ f(
34
- O,
34
+ j,
35
35
  {
36
36
  type: "select",
37
37
  removable: o,
@@ -42,7 +42,7 @@ const w = (t, o) => Array.isArray(o) ? o.join(", ") : o, e = ({
42
42
  }
43
43
  ),
44
44
  /* @__PURE__ */ f(
45
- j,
45
+ k,
46
46
  {
47
47
  expanded: t,
48
48
  title: m,
@@ -3,14 +3,14 @@ import "../../index-L8X2o7IH.js";
3
3
  import "../Icon/SvgIcon.js";
4
4
  import "react";
5
5
  import "../RootProvider/RootProvider.js";
6
- import { Menu as s } from "../Menu/Menu.js";
7
- import { DrawerOrDropdown as a } from "../Dropdown/DrawerOrDropdown.js";
8
- import "../../Autocomplete-BNV2UfH3.js";
9
- import { ToolbarButton as f } from "./ToolbarButton.js";
10
- import { ToolbarFilterBase as c } from "./ToolbarFilterBase.js";
11
- const M = ({ expanded: r = !1, onToggle: t, label: e, value: i, groups: m, search: l, items: p }) => /* @__PURE__ */ n(c, { expanded: r, children: [
12
- /* @__PURE__ */ o(f, { type: "switch", onToggle: t, active: !!i, children: e }),
13
- /* @__PURE__ */ o(a, { expanded: r, title: "Endre konto", onClose: t, children: /* @__PURE__ */ o(s, { theme: "global", defaultItemColor: "subtle", groups: m, search: l, items: p }) })
6
+ import { ToolbarButton as s } from "./ToolbarButton.js";
7
+ import { Menu as a } from "../Menu/Menu.js";
8
+ import { ToolbarFilterBase as f } from "./ToolbarFilterBase.js";
9
+ import { DrawerOrDropdown as c } from "../Dropdown/DrawerOrDropdown.js";
10
+ import "../../Autocomplete-DQCs4_zv.js";
11
+ const M = ({ expanded: r = !1, onToggle: t, label: e, value: i, groups: m, search: l, items: p }) => /* @__PURE__ */ n(f, { expanded: r, children: [
12
+ /* @__PURE__ */ o(s, { type: "switch", onToggle: t, active: !!i, children: e }),
13
+ /* @__PURE__ */ o(c, { expanded: r, title: "Endre konto", onClose: t, children: /* @__PURE__ */ o(a, { theme: "global", defaultItemColor: "subtle", groups: m, search: l, items: p }) })
14
14
  ] });
15
15
  export {
16
16
  M as ToolbarMenu
@@ -6,7 +6,7 @@ import { MenuOption as v } from "../Menu/MenuOption.js";
6
6
  import { MenuSearch as j } from "../Menu/MenuSearch.js";
7
7
  import { MenuHeader as x } from "../Menu/MenuHeader.js";
8
8
  import "../RootProvider/RootProvider.js";
9
- import "../../Autocomplete-BNV2UfH3.js";
9
+ import "../../Autocomplete-DQCs4_zv.js";
10
10
  import { MenuBase as O, MenuList as I, MenuListItem as m } from "../Menu/MenuBase.js";
11
11
  const w = ({ search: d, optionGroups: n = {}, options: h, onChange: b, optionType: g }) => {
12
12
  var a;
@@ -5,7 +5,7 @@ import "../../index-L8X2o7IH.js";
5
5
  import "react";
6
6
  import { IconButton as m } from "../Button/IconButton.js";
7
7
  import "../RootProvider/RootProvider.js";
8
- import "../../Autocomplete-BNV2UfH3.js";
8
+ import "../../Autocomplete-DQCs4_zv.js";
9
9
  import '../../assets/ToolbarSearch.css';const l = "_field_dvezx_1", p = "_icon_dvezx_5", d = "_input_dvezx_14", _ = "_clear_dvezx_30", o = {
10
10
  field: l,
11
11
  icon: p,
@@ -1,3 +1,6 @@
1
1
  export * from './ToolbarBase';
2
2
  export * from './ToolbarButton';
3
3
  export * from './Toolbar';
4
+ export * from './ToolbarSearch';
5
+ export * from './ToolbarFilter';
6
+ export * from './ToolbarDaterange';
@@ -1,8 +1,14 @@
1
- import { ToolbarBase as t } from "./ToolbarBase.js";
2
- import { ToolbarButton as e } from "./ToolbarButton.js";
3
- import { Toolbar as f } from "./Toolbar.js";
1
+ import { ToolbarBase as e } from "./ToolbarBase.js";
2
+ import { ToolbarButton as t } from "./ToolbarButton.js";
3
+ import { Toolbar as b } from "./Toolbar.js";
4
+ import { ToolbarSearch as m } from "./ToolbarSearch.js";
5
+ import { ToolbarFilter as x } from "./ToolbarFilter.js";
6
+ import { ToolbarDaterange as n } from "./ToolbarDaterange.js";
4
7
  export {
5
- f as Toolbar,
6
- t as ToolbarBase,
7
- e as ToolbarButton
8
+ b as Toolbar,
9
+ e as ToolbarBase,
10
+ t as ToolbarButton,
11
+ n as ToolbarDaterange,
12
+ x as ToolbarFilter,
13
+ m as ToolbarSearch
8
14
  };
@@ -0,0 +1,16 @@
1
+ import { AttachmentSectionProps } from '../Attachment';
2
+ import { AvatarProps } from '../Avatar';
3
+ import { BadgeProps } from '../Badge';
4
+ export interface TransmissionItemProps {
5
+ loading?: boolean;
6
+ expanded?: boolean;
7
+ sender: AvatarProps;
8
+ createdAt?: string;
9
+ createdAtLabel?: string;
10
+ badge?: BadgeProps;
11
+ title?: string;
12
+ description?: string | undefined;
13
+ summary?: string;
14
+ attachments?: AttachmentSectionProps;
15
+ }
16
+ export declare const TransmissionItem: ({ loading, sender, createdAt, createdAtLabel, badge, title, description, summary, attachments, }: TransmissionItemProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,59 @@
1
+ import { jsxs as i, jsx as m } from "react/jsx-runtime";
2
+ import { useState as f } from "react";
3
+ import "../../index-L8X2o7IH.js";
4
+ import "../Icon/SvgIcon.js";
5
+ import { Typography as x } from "../Typography/Typography.js";
6
+ import { AttachmentSection as b } from "../Attachment/AttachmentSection.js";
7
+ import { MetaTimestamp as T } from "../Meta/MetaTimestamp.js";
8
+ import { ListItemBase as u } from "../List/ListItemBase.js";
9
+ import { L as v } from "../../Autocomplete-DQCs4_zv.js";
10
+ import "../RootProvider/RootProvider.js";
11
+ import '../../assets/TransmissionItem.css';const I = "_body_1m345_1", z = {
12
+ body: I
13
+ }, H = ({
14
+ loading: c,
15
+ sender: o,
16
+ createdAt: a,
17
+ createdAtLabel: l,
18
+ badge: r,
19
+ title: n,
20
+ description: s,
21
+ summary: g,
22
+ attachments: p
23
+ }) => {
24
+ const [t, h] = f(!1);
25
+ return /* @__PURE__ */ i(u, { expanded: t, children: [
26
+ /* @__PURE__ */ m(
27
+ v,
28
+ {
29
+ as: "button",
30
+ onClick: () => {
31
+ h((y) => !y);
32
+ },
33
+ size: "sm",
34
+ avatar: {
35
+ type: o == null ? void 0 : o.type,
36
+ imageUrl: o == null ? void 0 : o.imageUrl,
37
+ name: o == null ? void 0 : o.name
38
+ },
39
+ title: n,
40
+ description: t ? "" : s,
41
+ badge: r,
42
+ linkIcon: t ? "chevron-down" : "chevron-up"
43
+ }
44
+ ),
45
+ t && /* @__PURE__ */ i("div", { className: z.body, children: [
46
+ a && /* @__PURE__ */ i(T, { loading: c, datetime: a, size: "xs", children: [
47
+ o && /* @__PURE__ */ m("strong", { children: (o == null ? void 0 : o.name) + ", " }),
48
+ l
49
+ ] }),
50
+ /* @__PURE__ */ i(x, { size: "lg", children: [
51
+ /* @__PURE__ */ m("p", { children: g }),
52
+ p && /* @__PURE__ */ m(b, { ...p })
53
+ ] })
54
+ ] })
55
+ ] });
56
+ };
57
+ export {
58
+ H as TransmissionItem
59
+ };
@@ -0,0 +1,56 @@
1
+ import { TransmissionItem as e } from "./TransmissionItem.js";
2
+ const a = {
3
+ title: "Transmission/TransmissionItem",
4
+ component: e,
5
+ tags: ["autodocs"],
6
+ parameters: {},
7
+ args: {
8
+ createdAt: "2024-09-22 13:34",
9
+ createdAtLabel: "22. september 2024 kl 13.34",
10
+ sender: {
11
+ type: "person",
12
+ name: "Eirik Horneland"
13
+ },
14
+ title: "Leveransen er godkjent, men inneholder feil",
15
+ description: "22.09.2024 kl 13.34",
16
+ badge: {
17
+ label: "Godkjent"
18
+ },
19
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding og feilliste under"
20
+ }
21
+ }, r = {
22
+ args: {}
23
+ }, n = {
24
+ args: {
25
+ attachments: {
26
+ title: "6 vedlegg",
27
+ items: [
28
+ {
29
+ href: "#",
30
+ label: "1-0 Castro.pdf"
31
+ },
32
+ {
33
+ href: "#",
34
+ label: "2-0 Kornvig.pdf"
35
+ },
36
+ {
37
+ href: "#",
38
+ label: "3-0 Kartum.pdf"
39
+ },
40
+ {
41
+ href: "#",
42
+ label: "3-1 Zinkernagel.pdf"
43
+ },
44
+ {
45
+ href: "#",
46
+ label: "4-1 Castro.pdf"
47
+ }
48
+ ]
49
+ }
50
+ }
51
+ };
52
+ export {
53
+ n as Attachments,
54
+ r as Default,
55
+ a as default
56
+ };
@@ -0,0 +1,6 @@
1
+ import { TransmissionItemProps } from './TransmissionItem';
2
+ export interface TransmissionListProps {
3
+ items: TransmissionItemProps[];
4
+ className?: string;
5
+ }
6
+ export declare const TransmissionList: ({ items }: TransmissionListProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,12 @@
1
+ import { jsx as o } from "react/jsx-runtime";
2
+ import { createElement as i } from "react";
3
+ import "../../index-L8X2o7IH.js";
4
+ import "../Icon/SvgIcon.js";
5
+ import { TransmissionItem as e } from "./TransmissionItem.js";
6
+ import "../RootProvider/RootProvider.js";
7
+ import "../../Autocomplete-DQCs4_zv.js";
8
+ import { ListBase as n } from "../List/ListBase.js";
9
+ const x = ({ items: r }) => r.length ? /* @__PURE__ */ o(n, { children: r.map((t, m) => /* @__PURE__ */ i(e, { ...t, key: m })) }) : null;
10
+ export {
11
+ x as TransmissionList
12
+ };
@@ -0,0 +1,63 @@
1
+ import { TransmissionList as e } from "./TransmissionList.js";
2
+ const n = {
3
+ title: "Transmission/TransmissionList",
4
+ component: e,
5
+ tags: ["autodocs"],
6
+ parameters: {},
7
+ args: {
8
+ items: [
9
+ {
10
+ createdAt: "2024-09-22 13:34",
11
+ createdAtLabel: "22. september 2024 kl 13.34",
12
+ badge: {
13
+ label: "Godkjent, med feil"
14
+ },
15
+ sender: {
16
+ name: "Skatteetaten",
17
+ type: "Company",
18
+ imageUrl: "https://cdn.sanity.io/images/z3it2oa7/production/e16a4f384d1d5ed959e1d74f0626259711d67509-88x88.png?w=96"
19
+ },
20
+ title: "Leveransen er godkjent, men inneholder feil",
21
+ description: "22. sept 11.10",
22
+ summary: "Leveransen er godkjent, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding og feilliste under.",
23
+ attachments: {
24
+ title: "6 vedlegg",
25
+ items: [
26
+ {
27
+ href: "#",
28
+ label: "Feilliste.pdf"
29
+ }
30
+ ]
31
+ }
32
+ },
33
+ {
34
+ createdAt: "2004-09-09 11:05",
35
+ createdAtLabel: "22. september 2024 kl 11.05",
36
+ sender: {
37
+ name: "Eirik Horneland"
38
+ },
39
+ badge: {
40
+ label: "Sendt inn"
41
+ },
42
+ title: "Tredjepartsopplysninger ble sendt inn",
43
+ description: "22. sept 11.05",
44
+ summary: "Dere får tilbakemelding om en kort stund.",
45
+ attachments: {
46
+ title: "1 vedlegg",
47
+ items: [
48
+ {
49
+ href: "#",
50
+ label: "Innsendte opplysninger.pdf"
51
+ }
52
+ ]
53
+ }
54
+ }
55
+ ]
56
+ }
57
+ }, a = {
58
+ args: {}
59
+ };
60
+ export {
61
+ a as Default,
62
+ n as default
63
+ };
@@ -0,0 +1,8 @@
1
+ import { ToolbarProps } from '../Toolbar';
2
+ import { TransmissionItemProps } from '../Transmission';
3
+ export interface TransmissionSectionProps {
4
+ title?: string;
5
+ items?: TransmissionItemProps[];
6
+ toolbar?: ToolbarProps;
7
+ }
8
+ export declare const TransmissionSection: ({ title, items, toolbar }: TransmissionSectionProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,17 @@
1
+ import { jsxs as s, jsx as o } from "react/jsx-runtime";
2
+ import "../../index-L8X2o7IH.js";
3
+ import "../Icon/SvgIcon.js";
4
+ import { Toolbar as m } from "../Toolbar/Toolbar.js";
5
+ import { Heading as t } from "../Typography/Heading.js";
6
+ import "react";
7
+ import "../RootProvider/RootProvider.js";
8
+ import { TransmissionList as p } from "./TransmissionList.js";
9
+ import "../../Autocomplete-DQCs4_zv.js";
10
+ const u = ({ title: n = "Transmissions", items: r, toolbar: i }) => r != null && r.length ? /* @__PURE__ */ s("section", { children: [
11
+ /* @__PURE__ */ o(t, { as: "h2", size: "xs", children: n }),
12
+ i && /* @__PURE__ */ o(m, { ...i }),
13
+ /* @__PURE__ */ o(p, { items: r })
14
+ ] }) : null;
15
+ export {
16
+ u as TransmissionSection
17
+ };
@@ -0,0 +1,184 @@
1
+ import { TransmissionSection as e } from "./TransmissionSection.js";
2
+ const r = {
3
+ title: "Transmission/TransmissionSection",
4
+ component: e,
5
+ tags: ["autodocs"],
6
+ parameters: {},
7
+ args: {
8
+ title: "6 forsendelser",
9
+ items: [
10
+ {
11
+ createdAt: "1999-01-01",
12
+ createdAtLabel: "Skatteetaten, 1. mars 2024",
13
+ sender: {
14
+ type: "company",
15
+ name: "Skatteetaten",
16
+ imageUrl: "https://cdn.sanity.io/images/z3it2oa7/production/e16a4f384d1d5ed959e1d74f0626259711d67509-88x88.png?w=96"
17
+ },
18
+ badge: {
19
+ label: "Godkjent, med feil"
20
+ },
21
+ title: "Leveransen er godkjent, men inneholder feil",
22
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under.",
23
+ attachments: {
24
+ title: "2 vedlegg",
25
+ items: [
26
+ {
27
+ label: "Dokument 1.pdf",
28
+ href: ""
29
+ },
30
+ {
31
+ label: "Dokument 2.pdf",
32
+ href: ""
33
+ }
34
+ ]
35
+ }
36
+ },
37
+ {
38
+ sender: {
39
+ name: "Per Olav Olsen"
40
+ },
41
+ title: "Tredjepartsopplysninger ble levert",
42
+ createdAtLabel: "1. mars 2024",
43
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under."
44
+ },
45
+ {
46
+ createdAt: "1999-01-01",
47
+ createdAtLabel: "Skatteetaten, 1. mars 2024",
48
+ sender: {
49
+ type: "company",
50
+ name: "Skatteetaten",
51
+ imageUrl: "https://cdn.sanity.io/images/z3it2oa7/production/e16a4f384d1d5ed959e1d74f0626259711d67509-88x88.png?w=96"
52
+ },
53
+ badge: {
54
+ label: "Godkjent"
55
+ },
56
+ title: "Leveransen er godkjent",
57
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under.",
58
+ attachments: {
59
+ title: "2 vedlegg",
60
+ items: [
61
+ {
62
+ label: "Dokument 1.pdf",
63
+ href: ""
64
+ },
65
+ {
66
+ label: "Dokument 2.pdf",
67
+ href: ""
68
+ }
69
+ ]
70
+ }
71
+ },
72
+ {
73
+ sender: {
74
+ name: "Kari Susanne Pettersen"
75
+ },
76
+ title: "Tredjepartsopplysninger ble levert",
77
+ createdAtLabel: "1. mars 2024",
78
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under."
79
+ },
80
+ {
81
+ createdAt: "1999-01-01",
82
+ createdAtLabel: "Skatteetaten, 1. mars 2024",
83
+ sender: {
84
+ type: "company",
85
+ name: "Skatteetaten",
86
+ imageUrl: "https://cdn.sanity.io/images/z3it2oa7/production/e16a4f384d1d5ed959e1d74f0626259711d67509-88x88.png?w=96"
87
+ },
88
+ badge: {
89
+ label: "Avvist"
90
+ },
91
+ title: "Leveransen er avvist",
92
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under.",
93
+ attachments: {
94
+ title: "2 vedlegg",
95
+ items: [
96
+ {
97
+ label: "Dokument 1.pdf",
98
+ href: ""
99
+ },
100
+ {
101
+ label: "Dokument 2.pdf",
102
+ href: ""
103
+ }
104
+ ]
105
+ }
106
+ },
107
+ {
108
+ sender: {
109
+ name: "Siren Søftebø"
110
+ },
111
+ title: "Tredjepartsopplysninger ble levert",
112
+ createdAtLabel: "1. mars 2024",
113
+ summary: "Skatteetaten har godkjent leveransen, men det er feil i oppgaver du må se nærmere på. Se tilbakemelding of feilliste under."
114
+ }
115
+ ]
116
+ }
117
+ }, n = {
118
+ args: {}
119
+ }, t = {
120
+ args: {
121
+ toolbar: {
122
+ search: {
123
+ label: "Søk i forsendelser",
124
+ placeholder: "Søk i forsendelser"
125
+ }
126
+ }
127
+ }
128
+ }, l = {
129
+ args: {
130
+ toolbar: {
131
+ ...t.args.toolbar,
132
+ filters: [
133
+ {
134
+ name: "type",
135
+ label: "Alle typer",
136
+ optionType: "checkbox",
137
+ options: [
138
+ {
139
+ groupId: "1",
140
+ label: "Innsending",
141
+ value: "submission"
142
+ },
143
+ {
144
+ groupId: "1",
145
+ label: "Rettelse",
146
+ value: "correction"
147
+ },
148
+ {
149
+ groupId: "2",
150
+ label: "Godkjent",
151
+ value: "acceptance"
152
+ },
153
+ {
154
+ groupId: "2",
155
+ label: "Avvist",
156
+ value: "rejection"
157
+ },
158
+ {
159
+ groupId: "3",
160
+ label: "Avgjørelse",
161
+ value: "decisision"
162
+ },
163
+ {
164
+ groupId: "3",
165
+ label: "Forespørsel",
166
+ value: "request"
167
+ },
168
+ {
169
+ groupId: "4",
170
+ label: "Varsel",
171
+ value: "alert"
172
+ }
173
+ ]
174
+ }
175
+ ]
176
+ }
177
+ }
178
+ };
179
+ export {
180
+ n as Default,
181
+ l as WithFilters,
182
+ t as WithSearch,
183
+ r as default
184
+ };
@@ -0,0 +1,3 @@
1
+ export * from './TransmissionItem';
2
+ export * from './TransmissionList';
3
+ export * from './TransmissionSection';
@@ -0,0 +1,8 @@
1
+ import { TransmissionItem as r } from "./TransmissionItem.js";
2
+ import { TransmissionList as m } from "./TransmissionList.js";
3
+ import { TransmissionSection as t } from "./TransmissionSection.js";
4
+ export {
5
+ r as TransmissionItem,
6
+ m as TransmissionList,
7
+ t as TransmissionSection
8
+ };
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- export type HeadingSize = 'sm' | 'md' | 'lg';
2
+ export type HeadingSize = 'xs' | 'sm' | 'md' | 'lg';
3
3
  export type HeadingComponent = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
4
4
  export interface HeadingProps {
5
5
  as?: HeadingComponent;
@@ -1,8 +1,8 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import { c as o } from "../../index-L8X2o7IH.js";
3
- import '../../assets/Heading.css';const i = "_heading_1kfgw_1", c = {
3
+ import '../../assets/Heading.css';const i = "_heading_1ay9p_1", c = {
4
4
  heading: i
5
- }, m = ({ as: s = "h2", size: a = "md", className: e, children: n }) => /* @__PURE__ */ t(s, { className: o(c.heading, e), "data-size": a, children: n });
5
+ }, g = ({ as: a = "h2", size: s = "md", className: e, children: n }) => /* @__PURE__ */ t(a, { className: o(c.heading, e), "data-size": s, children: n });
6
6
  export {
7
- m as Heading
7
+ g as Heading
8
8
  };
@@ -7,5 +7,6 @@ export interface TypographyProps {
7
7
  theme?: LayoutTheme;
8
8
  className?: string;
9
9
  children?: ReactNode;
10
+ href?: string;
10
11
  }
11
- export declare const Typography: ({ as, size, theme, className, children }: TypographyProps) => import("react/jsx-runtime").JSX.Element;
12
+ export declare const Typography: ({ as, size, theme, className, children, ...restProps }: TypographyProps) => import("react/jsx-runtime").JSX.Element;