@altinn/altinn-components 0.35.8 → 0.36.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.
- package/dist/assets/SearchField.css +1 -1
- package/dist/assets/SearchbarField.css +1 -1
- package/dist/assets/TimelineBase.css +1 -1
- package/dist/components/Dialog/DialogBody.js +17 -16
- package/dist/components/Dialog/DialogHistorySegment.js +17 -9
- package/dist/components/Forms/SearchField.js +33 -23
- package/dist/components/Searchbar/Searchbar.js +18 -18
- package/dist/components/Searchbar/SearchbarField.js +28 -26
- package/dist/components/Timeline/TimelineBase.js +8 -8
- package/dist/components/Timeline/TimelineSection.js +17 -16
- package/dist/components/Timeline/TimelineSegment.js +19 -18
- package/dist/types/lib/components/Dialog/DialogBody.d.ts +3 -1
- package/dist/types/lib/components/Dialog/DialogBody.stories.d.ts +1 -1
- package/dist/types/lib/components/Dialog/DialogHistorySegment.d.ts +2 -1
- package/dist/types/lib/components/Timeline/TimelineSection.d.ts +2 -1
- package/dist/types/lib/components/Timeline/TimelineSection.stories.d.ts +1 -1
- package/dist/types/lib/components/Timeline/TimelineSegment.d.ts +2 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._field_zk1f7_1{position:relative}._icon_zk1f7_5{position:absolute;top:1px;left:1px;font-size:1.25em;color:var(--ds-color-text-subtle);margin:.5em}._input_zk1f7_14{padding-left:2.25em;padding-right:2.25em}._input_zk1f7_14[type=search]::-webkit-search-decoration,._input_zk1f7_14[type=search]::-webkit-search-cancel-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}._clear_zk1f7_24{font-size:inherit;position:absolute;top:0;right:0;margin:.375em;border:0;border-radius:100%;font-size:.75em;background-color:var(--ds-color-surface-tinted);color:var(--ds-color-base-default)}._clear_zk1f7_24:focus-visible{outline-offset:0;outline-width:2px}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._field_1f56c_1{position:relative;display:flex;align-items:center;font-size:1.125rem;background-color:transparent;color:currentColor}._icon_1f56c_10{position:absolute;left:0;font-size:1.5rem;margin:0 1rem}._input_1f56c_17{height:3.5rem;background-color:transparent;font-size:inherit;flex-grow:1;padding:1rem 1rem 1rem 3rem;border:2px solid;border-radius:.25rem;outline:none}._input_1f56c_17[type=search]::-webkit-search-decoration,._input_1f56c_17[type=search]::-webkit-search-cancel-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}._input_1f56c_17[data-expanded=true],._input_1f56c_17:focus,._input_1f56c_17:not(:placeholder-shown){background-color:var(--ds-color-background-default)}._clear_1f56c_39{background-color:var(--ds-color-surface-tinted);color:var(--ds-color-base-default);border:0;position:absolute;right:0;margin:.75rem;border-radius:100%;width:1.5rem;height:1.5rem}._clear_1f56c_39:focus-visible{outline-offset:0;outline-width:2px}._dismiss_1f56c_56{position:absolute;right:0;margin:.5rem}._dismiss_1f56c_56:focus-visible{outline-offset:0;outline-width:2px}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._section_1030v_1{width:100%;display:flex;column-gap:.5rem;min-height:1.5rem}._sidebar_1030v_8{flex-shrink:0;flex-grow:0;display:flex;flex-direction:column;align-items:center;justify-content:center;row-gap:.375rem;width:1.5rem}._sidebar_1030v_8[data-level="2"]{width:1.5rem}@media (min-width: 1024px){._sidebar_1030v_8{width:2.25rem}._sidebar_1030v_8[data-level="2"]{width:1.5rem}}._content_1030v_33{flex-grow:1;display:flex;flex-direction:column}._border_1030v_39{border-left:.25rem solid;border-color:var(--ds-color-surface-tinted);flex-grow:1}._border_1030v_39{border-color:var(--ds-color-surface-active);border-width:.125rem;flex-grow:1;transition:border-color .5s ease-out}._border_1030v_39[data-variant=hidden]{display:none}._border_1030v_39[data-variant=strong]{border-width:2px;border-style:solid}._border_1030v_39[data-variant=solid]{border-width:1px;border-style:solid}._border_1030v_39[data-variant=dashed]{border-width:1px;border-style:dashed}._border_1030v_39[data-loading=true]{border-width:1px;border-style:dashed;border-color:var(--ds-color-border-subtle)}
|
|
@@ -1,31 +1,32 @@
|
|
|
1
|
-
import { jsxs as t, jsx as r, Fragment as
|
|
1
|
+
import { jsxs as t, jsx as r, Fragment as h } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { Timeline as
|
|
6
|
-
import { TimelineSection as
|
|
7
|
-
import { TimelineHeader as
|
|
8
|
-
import { Typography as
|
|
9
|
-
import { SeenByLog as
|
|
5
|
+
import { Timeline as n } from "../Timeline/Timeline.js";
|
|
6
|
+
import { TimelineSection as e } from "../Timeline/TimelineSection.js";
|
|
7
|
+
import { TimelineHeader as f } from "../Timeline/TimelineHeader.js";
|
|
8
|
+
import { Typography as T } from "../Typography/Typography.js";
|
|
9
|
+
import { SeenByLog as x } from "./SeenByLog.js";
|
|
10
10
|
import "../Searchbar/AutocompleteBase.js";
|
|
11
11
|
import "../Snackbar/useSnackbar.js";
|
|
12
|
-
const
|
|
12
|
+
const F = ({
|
|
13
13
|
loading: o,
|
|
14
|
+
unread: l,
|
|
14
15
|
sender: m,
|
|
15
16
|
recipient: i,
|
|
16
|
-
recipientLabel:
|
|
17
|
-
children:
|
|
17
|
+
recipientLabel: a = "to",
|
|
18
|
+
children: c,
|
|
18
19
|
seenByLog: p
|
|
19
|
-
}) => /* @__PURE__ */ t(
|
|
20
|
-
/* @__PURE__ */ t(
|
|
20
|
+
}) => /* @__PURE__ */ t(n, { children: [
|
|
21
|
+
/* @__PURE__ */ t(f, { loading: o, icon: m, children: [
|
|
21
22
|
/* @__PURE__ */ r("strong", { children: m == null ? void 0 : m.name }),
|
|
22
|
-
|
|
23
|
+
a + " " + (i == null ? void 0 : i.name)
|
|
23
24
|
] }),
|
|
24
|
-
/* @__PURE__ */ r(
|
|
25
|
-
/* @__PURE__ */ r(
|
|
26
|
-
p && /* @__PURE__ */ r(
|
|
25
|
+
/* @__PURE__ */ r(e, { unread: l, loading: o, spacing: 4, color: o ? "neutral" : void 0, children: !o && /* @__PURE__ */ t(h, { children: [
|
|
26
|
+
/* @__PURE__ */ r(T, { maxWidth: "60ch", style: { marginTop: "0.5em" }, children: c }),
|
|
27
|
+
p && /* @__PURE__ */ r(x, { ...p, collapsible: !0 })
|
|
27
28
|
] }) })
|
|
28
29
|
] });
|
|
29
30
|
export {
|
|
30
|
-
|
|
31
|
+
F as DialogBody
|
|
31
32
|
};
|
|
@@ -1,17 +1,25 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { createElement as
|
|
1
|
+
import { jsxs as g, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { createElement as a } from "react";
|
|
3
3
|
import "../../index-L8X2o7IH.js";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { DialogHistoryItem as
|
|
5
|
+
import { DialogHistoryItem as c } from "./DialogHistoryItem.js";
|
|
6
6
|
import "../Searchbar/AutocompleteBase.js";
|
|
7
7
|
import "../Snackbar/useSnackbar.js";
|
|
8
|
-
import { TimelineSegment as
|
|
9
|
-
import { Typography as
|
|
10
|
-
const
|
|
11
|
-
|
|
8
|
+
import { TimelineSegment as f } from "../Timeline/TimelineSegment.js";
|
|
9
|
+
import { Typography as y } from "../Typography/Typography.js";
|
|
10
|
+
const k = ({
|
|
11
|
+
id: p,
|
|
12
|
+
items: r,
|
|
13
|
+
datetime: t,
|
|
14
|
+
byline: m,
|
|
15
|
+
children: e,
|
|
16
|
+
summary: o,
|
|
17
|
+
unread: n
|
|
18
|
+
}) => /* @__PURE__ */ g(f, { unread: n, datetime: t, byline: m, spacing: 2, id: p, children: [
|
|
19
|
+
o && /* @__PURE__ */ l(y, { children: o }),
|
|
12
20
|
e,
|
|
13
|
-
r == null ? void 0 : r.map((i) => /* @__PURE__ */
|
|
21
|
+
r == null ? void 0 : r.map((i) => /* @__PURE__ */ a(c, { ...i, key: i.id }))
|
|
14
22
|
] });
|
|
15
23
|
export {
|
|
16
|
-
|
|
24
|
+
k as DialogHistorySegment
|
|
17
25
|
};
|
|
@@ -1,34 +1,44 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as i, jsxs as l } from "react/jsx-runtime";
|
|
2
2
|
import { Icon as p } from "../Icon/Icon.js";
|
|
3
3
|
import "../../index-L8X2o7IH.js";
|
|
4
4
|
import "react";
|
|
5
|
+
import { IconButton as f } from "../Button/IconButton.js";
|
|
5
6
|
import "../RootProvider/RootProvider.js";
|
|
6
7
|
import "../Searchbar/AutocompleteBase.js";
|
|
7
8
|
import "../Snackbar/useSnackbar.js";
|
|
8
9
|
import { Input as _ } from "./Input.js";
|
|
9
|
-
import { FieldBase as
|
|
10
|
-
import { S as
|
|
11
|
-
import { S as
|
|
12
|
-
import '../../assets/SearchField.css';const
|
|
13
|
-
field:
|
|
10
|
+
import { FieldBase as d } from "./FieldBase.js";
|
|
11
|
+
import { S as u } from "../../MagnifyingGlass-3Ln1MufI.js";
|
|
12
|
+
import { S as k } from "../../XMark-DIqxCTTQ.js";
|
|
13
|
+
import '../../assets/SearchField.css';const g = "_field_zk1f7_1", h = "_icon_zk1f7_5", z = "_input_zk1f7_14", S = "_clear_zk1f7_24", o = {
|
|
14
|
+
field: g,
|
|
14
15
|
icon: h,
|
|
15
|
-
input:
|
|
16
|
-
clear:
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
/* @__PURE__ */
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
|
|
16
|
+
input: z,
|
|
17
|
+
clear: S
|
|
18
|
+
}, G = ({
|
|
19
|
+
className: s,
|
|
20
|
+
size: c,
|
|
21
|
+
color: e = "neutral",
|
|
22
|
+
label: n,
|
|
23
|
+
value: t,
|
|
24
|
+
onClear: r,
|
|
25
|
+
clearButtonAltText: m = "Clear search",
|
|
26
|
+
...a
|
|
27
|
+
}) => /* @__PURE__ */ i(d, { size: c, color: e, label: n, className: s, children: /* @__PURE__ */ l("div", { className: o.field, children: [
|
|
28
|
+
/* @__PURE__ */ i(_, { ...a, type: "search", value: t, className: o.input }),
|
|
29
|
+
/* @__PURE__ */ i(p, { svgElement: u, className: o.icon }),
|
|
30
|
+
r && !!t && /* @__PURE__ */ i(
|
|
31
|
+
f,
|
|
32
|
+
{
|
|
33
|
+
icon: k,
|
|
34
|
+
variant: "solid",
|
|
35
|
+
size: "custom",
|
|
36
|
+
className: o.clear,
|
|
37
|
+
onClick: r,
|
|
38
|
+
iconAltText: m
|
|
39
|
+
}
|
|
40
|
+
)
|
|
31
41
|
] }) });
|
|
32
42
|
export {
|
|
33
|
-
|
|
43
|
+
G as SearchField
|
|
34
44
|
};
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import { jsxs as f, jsx as
|
|
1
|
+
import { jsxs as f, jsx as b } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
5
|
-
import { SearchbarBase as
|
|
6
|
-
import { SearchbarField as
|
|
5
|
+
import { SearchbarBase as T } from "./SearchbarBase.js";
|
|
6
|
+
import { SearchbarField as A } from "./SearchbarField.js";
|
|
7
7
|
import "./AutocompleteBase.js";
|
|
8
|
-
import { Autocomplete as
|
|
8
|
+
import { Autocomplete as S } from "./Autocomplete.js";
|
|
9
9
|
import "../Snackbar/useSnackbar.js";
|
|
10
|
-
const
|
|
11
|
-
className:
|
|
10
|
+
const q = ({
|
|
11
|
+
className: g,
|
|
12
12
|
autocomplete: e,
|
|
13
13
|
expanded: a = !1,
|
|
14
|
-
onClose:
|
|
15
|
-
tabIndex:
|
|
16
|
-
...
|
|
14
|
+
onClose: r,
|
|
15
|
+
tabIndex: h,
|
|
16
|
+
...n
|
|
17
17
|
}) => /* @__PURE__ */ f(
|
|
18
|
-
|
|
18
|
+
T,
|
|
19
19
|
{
|
|
20
|
-
className:
|
|
20
|
+
className: g,
|
|
21
21
|
expanded: a,
|
|
22
22
|
autocomplete: !!e,
|
|
23
|
-
onBlurCapture: (
|
|
24
|
-
var c, s,
|
|
25
|
-
const i = (
|
|
26
|
-
(i === "search-button-clear" || i === "search-button-close" || i === "searchbar-input" && ((
|
|
23
|
+
onBlurCapture: (t) => {
|
|
24
|
+
var c, u, o, s, l, m, d, p;
|
|
25
|
+
const i = (o = (u = (c = t.target) == null ? void 0 : c.attributes) == null ? void 0 : u.getNamedItem("data-testid")) == null ? void 0 : o.value;
|
|
26
|
+
(s = t == null ? void 0 : t.relatedTarget) != null && s.closest('[data-autocomplete="true"]') || t.relatedTarget === null || (i === "search-button-clear" || i === "search-button-close" || i === "searchbar-input" && ((l = t.relatedTarget) == null ? void 0 : l.getAttribute("data-testid")) !== "searchbar-input" && ((m = t.relatedTarget) == null ? void 0 : m.getAttribute("data-testid")) !== "search-button-clear" && ((d = t.relatedTarget) == null ? void 0 : d.getAttribute("data-testid")) !== "search-button-close" && ((p = t.relatedTarget) == null ? void 0 : p.getAttribute("data-testid")) !== "autocomplete-list") && (r == null || r());
|
|
27
27
|
},
|
|
28
28
|
children: [
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
e && /* @__PURE__ */
|
|
29
|
+
/* @__PURE__ */ b(A, { ...n, expanded: a, onClose: r, tabIndex: h }),
|
|
30
|
+
e && /* @__PURE__ */ b(S, { ...e, expanded: a, onSelect: r })
|
|
31
31
|
]
|
|
32
32
|
}
|
|
33
33
|
);
|
|
34
34
|
export {
|
|
35
|
-
|
|
35
|
+
q as Searchbar
|
|
36
36
|
};
|
|
@@ -9,42 +9,42 @@ import "./AutocompleteBase.js";
|
|
|
9
9
|
import "../Snackbar/useSnackbar.js";
|
|
10
10
|
import { S as T } from "../../MagnifyingGlass-3Ln1MufI.js";
|
|
11
11
|
import { S as m } from "../../XMark-DIqxCTTQ.js";
|
|
12
|
-
import '../../assets/SearchbarField.css';const j = "
|
|
12
|
+
import '../../assets/SearchbarField.css';const j = "_field_1f56c_1", z = "_icon_1f56c_10", A = "_input_1f56c_17", K = "_clear_1f56c_39", M = "_dismiss_1f56c_56", s = {
|
|
13
13
|
field: j,
|
|
14
|
-
icon:
|
|
15
|
-
input:
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
icon: z,
|
|
15
|
+
input: A,
|
|
16
|
+
clear: K,
|
|
17
|
+
dismiss: M
|
|
18
18
|
}, H = ({
|
|
19
19
|
className: p,
|
|
20
20
|
expanded: e,
|
|
21
|
-
name:
|
|
22
|
-
value:
|
|
21
|
+
name: f = "q",
|
|
22
|
+
value: a,
|
|
23
23
|
placeholder: d = "Search",
|
|
24
|
-
closeButtonAltText:
|
|
24
|
+
closeButtonAltText: u = "Close search",
|
|
25
25
|
clearButtonAltText: _ = "Clear search",
|
|
26
26
|
onFocus: h,
|
|
27
|
-
onBlur:
|
|
28
|
-
onChange:
|
|
29
|
-
onClear:
|
|
30
|
-
onClose:
|
|
27
|
+
onBlur: x,
|
|
28
|
+
onChange: b,
|
|
29
|
+
onClear: y,
|
|
30
|
+
onClose: S,
|
|
31
31
|
onEnter: i,
|
|
32
|
-
tabIndex:
|
|
32
|
+
tabIndex: g
|
|
33
33
|
}) => {
|
|
34
|
-
const
|
|
34
|
+
const c = N(null), k = (o) => {
|
|
35
35
|
var r, n;
|
|
36
|
-
o.key === "Escape" && ((r =
|
|
36
|
+
o.key === "Escape" && ((r = c.current) == null || r.blur()), o.key === "Enter" && ((n = c.current) == null || n.blur(), i == null || i());
|
|
37
37
|
};
|
|
38
|
-
return /* @__PURE__ */ C("div", { className: I(s.field, p),
|
|
38
|
+
return /* @__PURE__ */ C("div", { className: I(s.field, p), children: [
|
|
39
39
|
/* @__PURE__ */ t(
|
|
40
40
|
"input",
|
|
41
41
|
{
|
|
42
|
-
ref:
|
|
42
|
+
ref: c,
|
|
43
43
|
onFocus: h,
|
|
44
|
-
onBlur:
|
|
45
|
-
name:
|
|
46
|
-
value:
|
|
47
|
-
onChange:
|
|
44
|
+
onBlur: x,
|
|
45
|
+
name: f,
|
|
46
|
+
value: a,
|
|
47
|
+
onChange: b,
|
|
48
48
|
placeholder: d,
|
|
49
49
|
className: s.input,
|
|
50
50
|
onKeyUp: k,
|
|
@@ -52,19 +52,20 @@ import '../../assets/SearchbarField.css';const j = "_field_73ung_1", A = "_icon_
|
|
|
52
52
|
"aria-haspopup": !0,
|
|
53
53
|
autoComplete: "off",
|
|
54
54
|
"aria-autocomplete": "list",
|
|
55
|
-
tabIndex:
|
|
55
|
+
tabIndex: g ?? 0,
|
|
56
|
+
"data-expanded": e,
|
|
56
57
|
"data-testid": "searchbar-input"
|
|
57
58
|
}
|
|
58
59
|
),
|
|
59
60
|
/* @__PURE__ */ t(v, { svgElement: T, className: s.icon }),
|
|
60
|
-
|
|
61
|
+
a && /* @__PURE__ */ t(
|
|
61
62
|
l,
|
|
62
63
|
{
|
|
63
64
|
icon: m,
|
|
64
65
|
variant: "solid",
|
|
65
66
|
size: "custom",
|
|
66
67
|
className: s.clear,
|
|
67
|
-
onClick:
|
|
68
|
+
onClick: y,
|
|
68
69
|
dataTestId: "search-button-clear",
|
|
69
70
|
iconAltText: _
|
|
70
71
|
}
|
|
@@ -72,11 +73,12 @@ import '../../assets/SearchbarField.css';const j = "_field_73ung_1", A = "_icon_
|
|
|
72
73
|
l,
|
|
73
74
|
{
|
|
74
75
|
icon: m,
|
|
76
|
+
size: "sm",
|
|
75
77
|
variant: "text",
|
|
76
78
|
className: s.dismiss,
|
|
77
|
-
onClick:
|
|
79
|
+
onClick: S,
|
|
78
80
|
dataTestId: "search-button-close",
|
|
79
|
-
iconAltText:
|
|
81
|
+
iconAltText: u
|
|
80
82
|
}
|
|
81
83
|
)
|
|
82
84
|
] });
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsxs as i, jsx as
|
|
1
|
+
import { jsxs as i, jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../RootProvider/RootProvider.js";
|
|
@@ -6,29 +6,29 @@ import { TimelineIcon as b } from "./TimelineIcon.js";
|
|
|
6
6
|
import "../Searchbar/AutocompleteBase.js";
|
|
7
7
|
import "../Snackbar/useSnackbar.js";
|
|
8
8
|
import { Flex as v } from "../Page/Flex.js";
|
|
9
|
-
import '../../assets/TimelineBase.css';const x = "
|
|
9
|
+
import '../../assets/TimelineBase.css';const x = "_section_1030v_1", N = "_sidebar_1030v_8", f = "_content_1030v_33", h = "_border_1030v_39", e = {
|
|
10
10
|
section: x,
|
|
11
11
|
sidebar: N,
|
|
12
12
|
content: f,
|
|
13
13
|
border: h
|
|
14
14
|
}, g = ({
|
|
15
15
|
as: n = "section",
|
|
16
|
-
loading:
|
|
16
|
+
loading: o,
|
|
17
17
|
border: a = "solid",
|
|
18
18
|
level: c = 1,
|
|
19
19
|
color: s,
|
|
20
20
|
icon: r,
|
|
21
|
-
iconColor:
|
|
22
|
-
iconTheme:
|
|
21
|
+
iconColor: m,
|
|
22
|
+
iconTheme: d,
|
|
23
23
|
children: l,
|
|
24
24
|
id: _,
|
|
25
25
|
...p
|
|
26
26
|
}) => /* @__PURE__ */ i(v, { as: n, className: e.section, color: s, ...p, id: _, children: [
|
|
27
27
|
/* @__PURE__ */ i("aside", { className: e.sidebar, "data-level": c, children: [
|
|
28
|
-
r && /* @__PURE__ */
|
|
29
|
-
/* @__PURE__ */
|
|
28
|
+
r && /* @__PURE__ */ t(b, { loading: o, icon: r, theme: d, color: m, size: "sm" }),
|
|
29
|
+
/* @__PURE__ */ t("div", { className: e.border, "data-loading": o, "data-variant": a, "data-color": s })
|
|
30
30
|
] }),
|
|
31
|
-
/* @__PURE__ */
|
|
31
|
+
/* @__PURE__ */ t("div", { className: e.content, children: l })
|
|
32
32
|
] });
|
|
33
33
|
export {
|
|
34
34
|
g as TimelineBase
|
|
@@ -1,29 +1,30 @@
|
|
|
1
|
-
import { jsxs as y, jsx as
|
|
1
|
+
import { jsxs as y, jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import { Byline as T } from "../Byline/Byline.js";
|
|
5
5
|
import "../RootProvider/RootProvider.js";
|
|
6
|
-
import { TimelineBase as
|
|
7
|
-
import { Typography as
|
|
6
|
+
import { TimelineBase as a } from "./TimelineBase.js";
|
|
7
|
+
import { Typography as j } from "../Typography/Typography.js";
|
|
8
8
|
import "../Searchbar/AutocompleteBase.js";
|
|
9
9
|
import "../Snackbar/useSnackbar.js";
|
|
10
|
-
import { Section as
|
|
11
|
-
const
|
|
10
|
+
import { Section as u } from "../Page/Section.js";
|
|
11
|
+
const C = ({
|
|
12
12
|
loading: o,
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
unread: i,
|
|
14
|
+
level: p,
|
|
15
|
+
margin: e,
|
|
16
|
+
spacing: s,
|
|
17
|
+
as: n = "li",
|
|
17
18
|
border: f = "strong",
|
|
18
|
-
color:
|
|
19
|
-
typographyProps:
|
|
19
|
+
color: c,
|
|
20
|
+
typographyProps: l = {},
|
|
20
21
|
datetime: x,
|
|
21
|
-
byline:
|
|
22
|
+
byline: m,
|
|
22
23
|
children: r
|
|
23
|
-
}) => /* @__PURE__ */ y(
|
|
24
|
-
|
|
25
|
-
/* @__PURE__ */
|
|
24
|
+
}) => /* @__PURE__ */ y(a, { loading: o, level: p, border: f, color: i ? c : "neutral", as: n, children: [
|
|
25
|
+
m && /* @__PURE__ */ t(T, { loading: o, datetime: x, children: m }),
|
|
26
|
+
/* @__PURE__ */ t(u, { margin: e, spacing: s, children: r && typeof r == "string" ? /* @__PURE__ */ t(j, { as: "p", loading: o, size: "md", ...l, children: r }) : r })
|
|
26
27
|
] });
|
|
27
28
|
export {
|
|
28
|
-
|
|
29
|
+
C as TimelineSection
|
|
29
30
|
};
|
|
@@ -1,29 +1,30 @@
|
|
|
1
|
-
import { jsx as i, jsxs as
|
|
1
|
+
import { jsx as i, jsxs as S } from "react/jsx-runtime";
|
|
2
2
|
import "../../index-L8X2o7IH.js";
|
|
3
3
|
import "react";
|
|
4
|
-
import { Byline as
|
|
4
|
+
import { Byline as a } from "../Byline/Byline.js";
|
|
5
5
|
import "../RootProvider/RootProvider.js";
|
|
6
|
-
import { TimelineBase as
|
|
6
|
+
import { TimelineBase as h } from "./TimelineBase.js";
|
|
7
7
|
import "../Searchbar/AutocompleteBase.js";
|
|
8
8
|
import "../Snackbar/useSnackbar.js";
|
|
9
|
-
import { Section as
|
|
10
|
-
import { S as
|
|
11
|
-
const
|
|
9
|
+
import { Section as x } from "../Page/Section.js";
|
|
10
|
+
import { S as d } from "../../CircleFill-BkDF4Wm0.js";
|
|
11
|
+
const w = ({
|
|
12
12
|
loading: r,
|
|
13
|
-
|
|
13
|
+
unread: m,
|
|
14
|
+
datetime: t,
|
|
14
15
|
byline: o,
|
|
15
|
-
icon:
|
|
16
|
-
color:
|
|
17
|
-
spacing:
|
|
18
|
-
margin:
|
|
19
|
-
children:
|
|
16
|
+
icon: e = d,
|
|
17
|
+
color: p,
|
|
18
|
+
spacing: l = 2,
|
|
19
|
+
margin: n = "bottom",
|
|
20
|
+
children: c,
|
|
20
21
|
id: s,
|
|
21
|
-
footer:
|
|
22
|
-
...
|
|
23
|
-
}) => /* @__PURE__ */ i(
|
|
24
|
-
o && /* @__PURE__ */ i(
|
|
25
|
-
|
|
22
|
+
footer: j,
|
|
23
|
+
...f
|
|
24
|
+
}) => /* @__PURE__ */ i(h, { loading: r, color: m ? p : "neutral", icon: e, as: "li", ...f, id: s, children: /* @__PURE__ */ S(x, { margin: n, spacing: l, children: [
|
|
25
|
+
o && /* @__PURE__ */ i(a, { loading: r, datetime: t, children: o }),
|
|
26
|
+
c
|
|
26
27
|
] }) });
|
|
27
28
|
export {
|
|
28
|
-
|
|
29
|
+
w as TimelineSegment
|
|
29
30
|
};
|
|
@@ -3,6 +3,8 @@ import { AvatarProps, SeenByLogProps } from '..';
|
|
|
3
3
|
export interface DialogBodyProps {
|
|
4
4
|
/** Loading */
|
|
5
5
|
loading?: boolean;
|
|
6
|
+
/** Unread */
|
|
7
|
+
unread?: boolean;
|
|
6
8
|
/** Sender */
|
|
7
9
|
sender?: AvatarProps;
|
|
8
10
|
/** Recipient */
|
|
@@ -17,4 +19,4 @@ export interface DialogBodyProps {
|
|
|
17
19
|
children?: ReactNode;
|
|
18
20
|
}
|
|
19
21
|
/** DialogBody represents the body, or main part of a dialog, including sender and recipient. */
|
|
20
|
-
export declare const DialogBody: ({ loading, sender, recipient, recipientLabel, children, seenByLog, }: DialogBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare const DialogBody: ({ loading, unread, sender, recipient, recipientLabel, children, seenByLog, }: DialogBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { StoryObj } from '@storybook/react-vite';
|
|
2
2
|
declare const meta: {
|
|
3
3
|
title: string;
|
|
4
|
-
component: ({ loading, sender, recipient, recipientLabel, children, seenByLog, }: import('./DialogBody').DialogBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
component: ({ loading, unread, sender, recipient, recipientLabel, children, seenByLog, }: import('./DialogBody').DialogBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
tags: string[];
|
|
6
6
|
args: {
|
|
7
7
|
sender: {
|
|
@@ -7,5 +7,6 @@ export interface DialogHistorySegmentProps {
|
|
|
7
7
|
byline?: string;
|
|
8
8
|
children?: ReactNode;
|
|
9
9
|
summary?: ReactNode;
|
|
10
|
+
unread?: boolean;
|
|
10
11
|
}
|
|
11
|
-
export declare const DialogHistorySegment: ({ id, items, datetime, byline, children, summary }: DialogHistorySegmentProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export declare const DialogHistorySegment: ({ id, items, datetime, byline, children, summary, unread, }: DialogHistorySegmentProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,6 +2,7 @@ import { ElementType, ReactNode } from 'react';
|
|
|
2
2
|
import { SectionProps, TimelineBaseProps, TypographyProps } from '..';
|
|
3
3
|
export interface TimelineSectionProps {
|
|
4
4
|
loading?: boolean;
|
|
5
|
+
unread?: boolean;
|
|
5
6
|
level?: TimelineBaseProps['level'];
|
|
6
7
|
border?: TimelineBaseProps['border'];
|
|
7
8
|
color?: TimelineBaseProps['color'];
|
|
@@ -13,4 +14,4 @@ export interface TimelineSectionProps {
|
|
|
13
14
|
children?: ReactNode | string;
|
|
14
15
|
as?: ElementType;
|
|
15
16
|
}
|
|
16
|
-
export declare const TimelineSection: ({ loading, level, margin, spacing, as, border, color, typographyProps, datetime, byline, children, }: TimelineSectionProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare const TimelineSection: ({ loading, unread, level, margin, spacing, as, border, color, typographyProps, datetime, byline, children, }: TimelineSectionProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { StoryObj } from '@storybook/react-vite';
|
|
2
2
|
declare const meta: {
|
|
3
3
|
title: string;
|
|
4
|
-
component: ({ loading, level, margin, spacing, as, border, color, typographyProps, datetime, byline, children, }: import('./TimelineSection').TimelineSectionProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
component: ({ loading, unread, level, margin, spacing, as, border, color, typographyProps, datetime, byline, children, }: import('./TimelineSection').TimelineSectionProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
tags: string[];
|
|
6
6
|
parameters: {};
|
|
7
7
|
args: {
|
|
@@ -3,6 +3,7 @@ import { FlexMargin, FlexSpacing, TimelineBaseProps, TimelineBorder, TypographyP
|
|
|
3
3
|
export interface TimelineSegmentProps extends TimelineBaseProps {
|
|
4
4
|
id?: string;
|
|
5
5
|
loading?: boolean;
|
|
6
|
+
unread?: boolean;
|
|
6
7
|
icon?: TimelineBaseProps['icon'];
|
|
7
8
|
datetime?: string;
|
|
8
9
|
border?: TimelineBorder;
|
|
@@ -13,4 +14,4 @@ export interface TimelineSegmentProps extends TimelineBaseProps {
|
|
|
13
14
|
margin?: FlexMargin;
|
|
14
15
|
spacing?: FlexSpacing;
|
|
15
16
|
}
|
|
16
|
-
export declare const TimelineSegment: ({ loading, datetime, byline, icon, color, spacing, margin, children, id, footer, ...props }: TimelineSegmentProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare const TimelineSegment: ({ loading, unread, datetime, byline, icon, color, spacing, margin, children, id, footer, ...props }: TimelineSegmentProps) => import("react/jsx-runtime").JSX.Element;
|