@telia-ace/knowledge-widget-ui 1.0.38-next.1 → 1.0.38

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.js CHANGED
@@ -9,7 +9,7 @@ var re = (t, e, a) => e in t ? He(t, e, { enumerable: !0, configurable: !0, writ
9
9
  for (var a of R(e))
10
10
  se.call(e, a) && re(t, a, e[a]);
11
11
  return t;
12
- }, k = (t, e) => je(t, Oe(e));
12
+ }, E = (t, e) => je(t, Oe(e));
13
13
  var w = (t, e) => {
14
14
  var a = {};
15
15
  for (var r in t)
@@ -19,13 +19,13 @@ var w = (t, e) => {
19
19
  e.indexOf(r) < 0 && se.call(t, r) && (a[r] = t[r]);
20
20
  return a;
21
21
  };
22
- import { css as $, keyframes as he } from "@emotion/react";
23
- import d from "@emotion/styled";
24
- import { useRouteData as ge, Link as Ye, Icon as H, List as Z, list as pe, invertedHoverButton as ye, Drawer as _e, ItemList as O, itemList as Y, Dropdown as $e, headingElement as ee, Text as ve, Button as te, paddedBorderTabStyle as ie, Confirm as Ke, SymbolBadge as N, StyledText as J, convertToStringAttributes as xe, useKeyPress as W, useContainer as Ve, useEventListener as le, DateFormats as be, Timestamp as we, useIsTabbing as qe, usePrevious as Ge, TextLink as Q, borderTabStyle as X, Paragraph as Ue, genericHtml as Je, AnchorLink as Qe, WidgetLink as Xe } from "@telia-ace/widget-ui";
22
+ import { useRouteData as he, Link as Ye, Icon as H, List as Z, list as ge, invertedHoverButton as pe, ItemList as O, itemList as Y, Drawer as _e, Dropdown as ye, headingElement as ee, Text as $e, Button as te, paddedBorderTabStyle as ie, Confirm as Ve, SymbolBadge as N, StyledText as J, convertToStringAttributes as ve, useKeyPress as W, useContainer as Ke, useEventListener as le, Timestamp as xe, DateFormats as be, TextLink as Q, useIsTabbing as qe, usePrevious as Ge, borderTabStyle as X, Paragraph as Ue, genericHtml as Je, AnchorLink as Qe, WidgetLink as Xe } from "@telia-ace/widget-ui";
25
23
  export * from "@telia-ace/widget-ui";
26
- import n, { forwardRef as _, useCallback as z, useState as T, useEffect as K, useMemo as Ze, useRef as Ee, useImperativeHandle as et } from "react";
27
- import { createParams as j, formatUrl as ce, appendClassNames as S, htmlParentContains as tt } from "@telia-ace/widget-utilities";
28
- const at = ({
24
+ import { createParams as j, formatUrl as ce, appendClassNames as z, htmlParentContains as Ze } from "@telia-ace/widget-utilities";
25
+ import n, { forwardRef as _, useCallback as k, useState as A, useEffect as V, useMemo as et, useRef as we, useImperativeHandle as tt } from "react";
26
+ import d from "@emotion/styled";
27
+ import { css as $, keyframes as Ee } from "@emotion/react";
28
+ const ke = ({
29
29
  title: t = "",
30
30
  className: e,
31
31
  id: a,
@@ -34,40 +34,38 @@ const at = ({
34
34
  type: i,
35
35
  target: o,
36
36
  href: c,
37
- children: m,
38
- connectionKey: f
37
+ children: m
39
38
  }) => {
40
- const u = {}, { name: l, params: h } = ge();
39
+ const f = {}, { name: u, params: l } = he();
41
40
  switch (i) {
42
41
  case "default":
43
42
  case "guide":
44
- const { id: E, title: g } = r;
45
- let v = f || s;
46
- E !== a && !f && (v = void 0), u.routeName = l, u.params = j(k(y({}, h), {
43
+ const { id: h, title: S } = r;
44
+ f.routeName = u, f.params = j(E(y({}, l), {
47
45
  guide: a,
48
- connection: v,
49
- uriName: a === E ? ce(g) : ce(t)
46
+ connection: a === h ? s : void 0,
47
+ uriName: a === h ? ce(S) : ce(t)
50
48
  }));
51
49
  break;
52
50
  case "link":
53
- u.href = c, u.target = o;
51
+ f.href = c, f.target = o;
54
52
  break;
55
53
  }
56
- return /* @__PURE__ */ n.createElement(Ye, y({ className: S(e, "humany-dialog-link") }, u), m || /* @__PURE__ */ n.createElement(n.Fragment, null, i === "link" && /* @__PURE__ */ n.createElement(H, { faIcon: "link" }), /* @__PURE__ */ n.createElement("span", null, t)));
57
- }, ke = at, ta = _((s, r) => {
54
+ return /* @__PURE__ */ n.createElement(Ye, y({ className: z(e, "humany-dialog-link") }, f), m || /* @__PURE__ */ n.createElement(n.Fragment, null, i === "link" && /* @__PURE__ */ n.createElement(H, { faIcon: "link" }), /* @__PURE__ */ n.createElement("span", null, t)));
55
+ }, Ot = _((s, r) => {
58
56
  var i = s, { className: t, dialog: e } = i, a = w(i, ["className", "dialog"]);
59
57
  return e.length ? /* @__PURE__ */ n.createElement(
60
- nt,
61
- k(y({
62
- className: S(t, "humany-dialog"),
58
+ at,
59
+ E(y({
60
+ className: z(t, "humany-dialog"),
63
61
  items: e,
64
62
  renderItem: (o) => /* @__PURE__ */ n.createElement("li", { key: o.connection, "data-dialog": o.connection }, /* @__PURE__ */ n.createElement(ke, y({}, o)))
65
63
  }, a), {
66
64
  ref: r
67
65
  })
68
66
  ) : null;
69
- }), nt = d(Z)`
70
- ${pe}
67
+ }), at = d(Z)`
68
+ ${ge}
71
69
  a {
72
70
  min-width: 150px;
73
71
  max-width: 400px;
@@ -75,7 +73,7 @@ const at = ({
75
73
  white-space: normal;
76
74
  ${(t) => {
77
75
  var e, a;
78
- return ((e = t.theme.colors) == null ? void 0 : e.primary) && ye({
76
+ return ((e = t.theme.colors) == null ? void 0 : e.primary) && pe({
79
77
  primaryColor: (a = t.theme.colors) == null ? void 0 : a.primary,
80
78
  secondaryColor: "#FFFFFF",
81
79
  theme: t.theme
@@ -89,7 +87,7 @@ const at = ({
89
87
  return (e = t.theme.sizes) == null ? void 0 : e.small;
90
88
  }} 0 0;
91
89
  }
92
- `, rt = (u) => {
90
+ `, Yt = (u) => {
93
91
  var l = u, {
94
92
  trigger: t,
95
93
  header: e,
@@ -114,7 +112,7 @@ const at = ({
114
112
  return /* @__PURE__ */ n.createElement(
115
113
  _e,
116
114
  {
117
- className: S(a, "humany-drawer-list"),
115
+ className: z(a, "humany-drawer-list"),
118
116
  trigger: t,
119
117
  header: e,
120
118
  animation: r,
@@ -122,9 +120,9 @@ const at = ({
122
120
  onToggle: i,
123
121
  closeButtonAriaLabel: m
124
122
  },
125
- /* @__PURE__ */ n.createElement(ot, y({}, f), o)
123
+ /* @__PURE__ */ n.createElement(nt, y({}, f), o)
126
124
  );
127
- }, aa = rt, ot = d(O)`
125
+ }, nt = d(O)`
128
126
  ${Y}
129
127
  font-family: ${(t) => {
130
128
  var e;
@@ -142,7 +140,7 @@ const at = ({
142
140
  return (e = t.theme.fonts) == null ? void 0 : e.normal;
143
141
  }};
144
142
  }
145
- `, st = ({ items: t, renderItem: e, trigger: a, header: r, children: s }) => /* @__PURE__ */ n.createElement($e, { className: "humany-dropdown-actions", trigger: a }, /* @__PURE__ */ n.createElement(it, null, !!r && /* @__PURE__ */ n.createElement(lt, null, r), t && e && /* @__PURE__ */ n.createElement(ct, { items: t, renderItem: e }), s)), na = st, it = d.div`
143
+ `, _t = ({ items: t, renderItem: e, trigger: a, header: r, children: s }) => /* @__PURE__ */ n.createElement(ye, { className: "humany-dropdown-actions", trigger: a }, /* @__PURE__ */ n.createElement(rt, null, !!r && /* @__PURE__ */ n.createElement(ot, null, r), t && e && /* @__PURE__ */ n.createElement(st, { items: t, renderItem: e }), s)), rt = d.div`
146
144
  background: #fff;
147
145
  border: #ccc 1px solid;
148
146
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
@@ -154,7 +152,7 @@ const at = ({
154
152
  var e;
155
153
  return (e = t.theme.fonts) == null ? void 0 : e.normal;
156
154
  }};
157
- `, lt = d.div`
155
+ `, ot = d.div`
158
156
  padding: ${(t) => {
159
157
  var e;
160
158
  return (e = t.theme.sizes) == null ? void 0 : e.normal;
@@ -187,7 +185,7 @@ const at = ({
187
185
  return (e = t.theme.sizes) == null ? void 0 : e.small;
188
186
  }};
189
187
  }
190
- `, ct = d(Z)`
188
+ `, st = d(Z)`
191
189
  list-style: none;
192
190
  padding: 0;
193
191
  margin: 0;
@@ -222,7 +220,7 @@ const at = ({
222
220
  }
223
221
  }
224
222
  }
225
- `, mt = (i) => {
223
+ `, Vt = (i) => {
226
224
  var o = i, {
227
225
  trigger: t,
228
226
  className: e,
@@ -235,15 +233,15 @@ const at = ({
235
233
  "closeButtonAriaLabel"
236
234
  ]);
237
235
  return /* @__PURE__ */ n.createElement(
238
- $e,
236
+ ye,
239
237
  {
240
- className: S(e, "humany-dropdown-list"),
238
+ className: z(e, "humany-dropdown-list"),
241
239
  closeButtonAriaLabel: r,
242
240
  trigger: t
243
241
  },
244
- /* @__PURE__ */ n.createElement(dt, y({}, s), a)
242
+ /* @__PURE__ */ n.createElement(it, y({}, s), a)
245
243
  );
246
- }, ra = mt, dt = d(O)`
244
+ }, it = d(O)`
247
245
  ${Y}
248
246
  font-family: ${(t) => {
249
247
  var e;
@@ -279,7 +277,7 @@ const at = ({
279
277
  }
280
278
  }
281
279
  }
282
- `, ut = (t) => $`
280
+ `, lt = (t) => $`
283
281
  ${t["data-loading"] && "position: relative;"};
284
282
  ${t["data-loading"] && "min-height: 150px;"}
285
283
  > * {
@@ -289,7 +287,7 @@ const at = ({
289
287
  .humany-loader {
290
288
  opacity: ${t["data-loading"] ? "1" : "0"};
291
289
  }
292
- `, oa = d(H)`
290
+ `, Kt = d(H)`
293
291
  && {
294
292
  font-size: ${(t) => {
295
293
  var e;
@@ -297,7 +295,7 @@ const at = ({
297
295
  }};
298
296
  }
299
297
  width: 1.2em;
300
- `, sa = d(ve)`
298
+ `, qt = d($e)`
301
299
  font-size: ${(t) => {
302
300
  var e;
303
301
  return (e = t.theme.fonts) == null ? void 0 : e.medium;
@@ -308,7 +306,7 @@ const at = ({
308
306
  var e;
309
307
  return (e = t.theme.colors) == null ? void 0 : e.text;
310
308
  }};
311
- `, ft = d(te)`
309
+ `, ct = d(te)`
312
310
  display: flex;
313
311
  align-items: center;
314
312
 
@@ -336,7 +334,7 @@ const at = ({
336
334
  flex: 1;
337
335
  font-weight: 300;
338
336
  }
339
- `, ht = ({
337
+ `, mt = ({
340
338
  addFavoriteTooltip: t,
341
339
  removeFavoriteCancelLabel: e,
342
340
  removeFavoriteConfirmLabel: a,
@@ -349,20 +347,20 @@ const at = ({
349
347
  buttonLabel: f = "",
350
348
  actions: { addFavorite: u, removeFavorite: l }
351
349
  }) => {
352
- const h = z(() => {
350
+ const h = k(() => {
353
351
  l(o);
354
- }, [o, l]), E = z(() => {
352
+ }, [o, l]), S = k(() => {
355
353
  u(o);
356
- }, [o, u]), g = `${c ? i : t}${m ? `: "${m}"` : ""}`;
354
+ }, [o, u]), p = `${c ? i : t}${m ? `: "${m}"` : ""}`;
357
355
  return /* @__PURE__ */ n.createElement(n.Fragment, null, c ? /* @__PURE__ */ n.createElement(
358
- Ke,
356
+ Ve,
359
357
  {
360
358
  trigger: /* @__PURE__ */ n.createElement(
361
359
  me,
362
360
  {
363
361
  className: "humany-favorite-button",
364
- title: g,
365
- "aria-label": g,
362
+ title: p,
363
+ "aria-label": p,
366
364
  "data-favorite": "true",
367
365
  "data-has-label": f ? "true" : "false",
368
366
  "data-has-symbol": "true"
@@ -386,9 +384,9 @@ const at = ({
386
384
  me,
387
385
  {
388
386
  className: "humany-favorite-button",
389
- title: g,
390
- "aria-label": g,
391
- onClick: E,
387
+ title: p,
388
+ "aria-label": p,
389
+ onClick: S,
392
390
  "data-favorite": "false",
393
391
  "data-has-label": f ? "true" : "false",
394
392
  "data-has-symbol": "true"
@@ -396,7 +394,7 @@ const at = ({
396
394
  /* @__PURE__ */ n.createElement(N, { size: 16, symbol: { type: "Svg", content: "star-empty" } }),
397
395
  f && /* @__PURE__ */ n.createElement(J, null, f)
398
396
  ));
399
- }, gt = ht, me = d(ft)`
397
+ }, me = d(ct)`
400
398
  grid-area: favorite;
401
399
 
402
400
  &:focus-visible {
@@ -458,7 +456,7 @@ const at = ({
458
456
  }
459
457
  `;
460
458
  }}
461
- `, ia = _(
459
+ `, Gt = _(
462
460
  (f, m) => {
463
461
  var u = f, {
464
462
  onFeedback: t = () => {
@@ -479,14 +477,14 @@ const at = ({
479
477
  "selected"
480
478
  ]);
481
479
  return /* @__PURE__ */ n.createElement(
482
- yt,
483
- k(y({
484
- className: S(a, "humany-feedback"),
480
+ ft,
481
+ E(y({
482
+ className: z(a, "humany-feedback"),
485
483
  "data-direction": e
486
- }, xe(c)), {
484
+ }, ve(c)), {
487
485
  ref: m
488
486
  }),
489
- !!r && /* @__PURE__ */ n.createElement(pt, null, r),
487
+ !!r && /* @__PURE__ */ n.createElement(dt, null, r),
490
488
  /* @__PURE__ */ n.createElement(
491
489
  de,
492
490
  {
@@ -515,7 +513,7 @@ const at = ({
515
513
  )
516
514
  );
517
515
  }
518
- ), pt = d(J)`
516
+ ), dt = d(J)`
519
517
  font-weight: normal;
520
518
  margin: 0 0 ${(t) => {
521
519
  var e;
@@ -554,7 +552,7 @@ const at = ({
554
552
 
555
553
  ${(t) => {
556
554
  var e, a;
557
- return ((e = t.theme.colors) == null ? void 0 : e.primary) && ye({
555
+ return ((e = t.theme.colors) == null ? void 0 : e.primary) && pe({
558
556
  active: t["data-selected"],
559
557
  primaryColor: (a = t.theme.colors) == null ? void 0 : a.primary,
560
558
  secondaryColor: "#FFFFFF",
@@ -568,7 +566,7 @@ const at = ({
568
566
  return (e = t.theme.sizes) == null ? void 0 : e.small;
569
567
  }} 0 0;
570
568
  }
571
- `, yt = d.div`
569
+ `, ft = d.div`
572
570
  ${(t) => {
573
571
  var e;
574
572
  return t["data-direction"] === "vertical" && $`
@@ -580,16 +578,16 @@ const at = ({
580
578
  }
581
579
  `;
582
580
  }}
583
- `, $t = () => {
584
- const [t, e] = T(null), a = W("ArrowLeft"), r = W("ArrowRight"), s = W("ArrowUp"), i = W("ArrowDown");
585
- return K(() => {
581
+ `, Ut = () => {
582
+ const [t, e] = A(null), a = W("ArrowLeft"), r = W("ArrowRight"), s = W("ArrowUp"), i = W("ArrowDown");
583
+ return V(() => {
586
584
  e(a ? "left" : r ? "right" : s ? "up" : i ? "down" : null);
587
585
  }, [a, r, s, i]), t;
588
- }, la = $t, vt = (t, e) => {
589
- const [a, r] = T(t), s = z(() => setTimeout(() => {
586
+ }, Jt = (t, e) => {
587
+ const [a, r] = A(t), s = k(() => setTimeout(() => {
590
588
  r(t);
591
589
  }, e), [e, r, t]);
592
- return K(
590
+ return V(
593
591
  () => {
594
592
  const i = s();
595
593
  return () => {
@@ -598,9 +596,9 @@ const at = ({
598
596
  },
599
597
  [s]
600
598
  ), a;
601
- }, ca = vt, xt = () => {
602
- const t = Ve(), [e, a] = T([]), r = t.get("favorites");
603
- K(() => {
599
+ }, ut = () => {
600
+ const t = Ke(), [e, a] = A([]), r = t.get("favorites");
601
+ V(() => {
604
602
  if (r) {
605
603
  a(r.get());
606
604
  const { events: m } = t.get("$widget");
@@ -609,13 +607,13 @@ const at = ({
609
607
  });
610
608
  }
611
609
  }, []);
612
- const s = (m) => r ? r.add(m) : Promise.resolve([]), i = (m) => r ? r.remove(m) : Promise.resolve([]), o = () => r ? r.clear() : Promise.resolve([]), c = z(
610
+ const s = (m) => r ? r.add(m) : Promise.resolve([]), i = (m) => r ? r.remove(m) : Promise.resolve([]), o = () => r ? r.clear() : Promise.resolve([]), c = k(
613
611
  (m) => e.indexOf(m) > -1 ? i(m) : s(m),
614
612
  [e]
615
613
  );
616
614
  return [
617
615
  e,
618
- Ze(
616
+ et(
619
617
  () => ({
620
618
  addFavorite: s,
621
619
  removeFavorite: i,
@@ -625,10 +623,10 @@ const at = ({
625
623
  [e]
626
624
  )
627
625
  ];
628
- }, bt = xt, ma = () => {
629
- const [t, e] = T(!1), a = Ee(), r = z(() => e(!0), [e]), s = z(() => e(!1), [e]);
626
+ }, Qt = () => {
627
+ const [t, e] = A(!1), a = we(), r = k(() => e(!0), [e]), s = k(() => e(!1), [e]);
630
628
  return le("mouseenter", r, a.current), le("mouseleave", s, a.current), [t, a];
631
- }, wt = ({
629
+ }, ht = ({
632
630
  format: t = be.YYYY_MM_DD_HH_MM,
633
631
  className: e = "",
634
632
  byLabel: a = "",
@@ -641,33 +639,33 @@ const at = ({
641
639
  modified: f,
642
640
  published: u
643
641
  }) => {
644
- const l = m && u ? /* @__PURE__ */ n.createElement(ue, { format: t, timestamp: u }) : null, h = c && f ? /* @__PURE__ */ n.createElement(ue, { format: t, timestamp: f }) : null;
645
- return !l && !h ? null : /* @__PURE__ */ n.createElement(U, { className: S(e, "humany-metadata") }, l && /* @__PURE__ */ n.createElement(U, { className: "humany-published" }, s, l, a && o && ` ${a.replace("{{editor}}", o)}`), h && /* @__PURE__ */ n.createElement(U, { className: "humany-modified" }, l && ", ", r, h, a && i && ` ${a.replace("{{editor}}", i)}`));
646
- }, Et = wt, ue = d(we)`
642
+ const l = m && u ? /* @__PURE__ */ n.createElement(fe, { format: t, timestamp: u }) : null, h = c && f ? /* @__PURE__ */ n.createElement(fe, { format: t, timestamp: f }) : null;
643
+ return !l && !h ? null : /* @__PURE__ */ n.createElement(U, { className: z(e, "humany-metadata") }, l && /* @__PURE__ */ n.createElement(U, { className: "humany-published" }, s, l, a && o && ` ${a.replace("{{editor}}", o)}`), h && /* @__PURE__ */ n.createElement(U, { className: "humany-modified" }, l && ", ", r, h, a && i && ` ${a.replace("{{editor}}", i)}`));
644
+ }, fe = d(xe)`
647
645
  &:not(:first-child) {
648
646
  margin-left: 4px;
649
647
  }
650
648
  &:not(:last-child) {
651
649
  margin-right: 4px;
652
650
  }
653
- `, U = d(ve)`
651
+ `, U = d($e)`
654
652
  font-style: italic;
655
- `, kt = ({ tags: t }) => t.filter((e) => e.symbol).length ? /* @__PURE__ */ n.createElement(
656
- Nt,
653
+ `, gt = ({ tags: t }) => t.filter((e) => e.symbol).length ? /* @__PURE__ */ n.createElement(
654
+ $t,
657
655
  {
658
656
  className: "humany-guide-list-tags",
659
657
  items: t,
660
- renderItem: ({ id: e, symbol: a, title: r }) => a && /* @__PURE__ */ n.createElement("li", { key: e, "data-tag": e }, /* @__PURE__ */ n.createElement(Lt, { size: 18, symbol: a, title: r }))
658
+ renderItem: ({ id: e, symbol: a, title: r }) => a && /* @__PURE__ */ n.createElement("li", { key: e, "data-tag": e }, /* @__PURE__ */ n.createElement(vt, { size: 18, symbol: a, title: r }))
661
659
  }
662
- ) : null, da = _(({ title: t, id: e, route: a, symbolSize: r, collapseUri: s, children: i }, o) => {
663
- const { params: c } = ge();
664
- return /* @__PURE__ */ n.createElement(zt, { ref: o, "data-guide": e }, /* @__PURE__ */ n.createElement(
660
+ ) : null, Xt = _(({ title: t, id: e, route: a, symbolSize: r, collapseUri: s, children: i }, o) => {
661
+ const { params: c } = he();
662
+ return /* @__PURE__ */ n.createElement(pt, { ref: o, "data-guide": e }, /* @__PURE__ */ n.createElement(
665
663
  Q,
666
664
  {
667
665
  title: t,
668
666
  "aria-label": t,
669
667
  routeName: a,
670
- params: j(k(y({}, c), {
668
+ params: j(E(y({}, c), {
671
669
  uriName: s || void 0,
672
670
  id: void 0,
673
671
  guide: void 0,
@@ -677,7 +675,7 @@ const at = ({
677
675
  },
678
676
  /* @__PURE__ */ n.createElement(N, { size: r, symbol: { type: "Svg", content: "caret-up" } })
679
677
  ), i);
680
- }), zt = d.li`
678
+ }), pt = d.li`
681
679
  > a {
682
680
  grid-column: 1/-1;
683
681
  font-weight: bold;
@@ -690,9 +688,9 @@ const at = ({
690
688
  > div {
691
689
  grid-column: 1/-1;
692
690
  }
693
- `, ua = _(
694
- (Gt, Fe) => {
695
- var ae = Gt, {
691
+ `, Zt = _(
692
+ (Mt, Ie) => {
693
+ var ae = Mt, {
696
694
  expandable: t = !1,
697
695
  routing: e = {},
698
696
  paramMappers: a = {},
@@ -708,9 +706,9 @@ const at = ({
708
706
  },
709
707
  metadata: l = {},
710
708
  pageLabel: h,
711
- className: E,
712
- children: g,
713
- items: v,
709
+ className: S,
710
+ children: p,
711
+ items: x,
714
712
  renderItem: L,
715
713
  addFavoriteTooltip: C,
716
714
  removeFavoriteCancelLabel: M,
@@ -718,7 +716,7 @@ const at = ({
718
716
  removeFavoriteHeader: Se,
719
717
  removeFavoriteLabel: Ne,
720
718
  removeFavoriteTooltip: Le
721
- } = ae, De = w(ae, [
719
+ } = ae, Fe = w(ae, [
722
720
  "expandable",
723
721
  "routing",
724
722
  "paramMappers",
@@ -743,30 +741,30 @@ const at = ({
743
741
  "removeFavoriteLabel",
744
742
  "removeFavoriteTooltip"
745
743
  ]);
746
- const V = qe(), F = Ee(), I = Ge(v), { guide: Ie = "guide", page: Ae = "index" } = e, {
747
- guide: Te = ({ id: p }) => j({ guide: p }),
744
+ const K = qe(), I = we(), T = Ge(x), { guide: Te = "guide", page: De = "index" } = e, {
745
+ guide: Ae = ({ id: g }) => j({ guide: g }),
748
746
  page: ne = () => j()
749
- } = a, [Ce, Me] = bt();
750
- et(Fe, () => F.current);
751
- const q = (p) => {
752
- const { id: b, title: x, tags: D, published: P, modified: A, publishedBy: B, modifiedBy: G } = p;
747
+ } = a, [Ce, Me] = ut();
748
+ tt(Ie, () => I.current);
749
+ const q = (g) => {
750
+ const { id: b, title: v, tags: F, published: P, modified: D, publishedBy: B, modifiedBy: G } = g;
753
751
  return /* @__PURE__ */ n.createElement(
754
752
  "li",
755
753
  {
756
754
  key: b,
757
755
  "data-guide": b,
758
- "has-metadata": (!!(l != null && l.showPublished) && !!P || !!(l != null && l.showModified) && !!A).toString()
756
+ "has-metadata": (!!(l != null && l.showPublished) && !!P || !!(l != null && l.showModified) && !!D).toString()
759
757
  },
760
758
  /* @__PURE__ */ n.createElement(
761
759
  Q,
762
760
  {
763
761
  className: "humany-guide-link",
764
- title: x,
765
- "aria-label": x,
766
- routeName: Ie,
767
- onClick: (We) => f(We, p),
768
- params: Te(p),
769
- text: x
762
+ title: v,
763
+ "aria-label": v,
764
+ routeName: Te,
765
+ onClick: (We) => f(We, g),
766
+ params: Ae(g),
767
+ text: v
770
768
  },
771
769
  /* @__PURE__ */ n.createElement(
772
770
  N,
@@ -780,9 +778,9 @@ const at = ({
780
778
  )
781
779
  ),
782
780
  c && /* @__PURE__ */ n.createElement(
783
- gt,
781
+ mt,
784
782
  {
785
- guideTitle: x,
783
+ guideTitle: v,
786
784
  addFavoriteTooltip: C,
787
785
  removeFavoriteCancelLabel: M,
788
786
  removeFavoriteConfirmLabel: ze,
@@ -794,46 +792,46 @@ const at = ({
794
792
  id: b
795
793
  }
796
794
  ),
797
- o && /* @__PURE__ */ n.createElement(kt, { tags: D }),
795
+ o && /* @__PURE__ */ n.createElement(gt, { tags: F }),
798
796
  /* @__PURE__ */ n.createElement(
799
- Dt,
800
- k(y({}, l), {
797
+ xt,
798
+ E(y({}, l), {
801
799
  indent: t ? void 0 : r,
802
- modified: A,
800
+ modified: D,
803
801
  published: P,
804
802
  publishedBy: B,
805
803
  modifiedBy: G
806
804
  })
807
805
  )
808
806
  );
809
- }, Pe = z(
810
- (p, b, x) => L ? L(p, b, x, q) : q(p),
807
+ }, Pe = k(
808
+ (g, b, v) => L ? L(g, b, v, q) : q(g),
811
809
  [L, q]
812
- ), Be = z(
813
- (p) => {
814
- m && (p.preventDefault(), u("page", ne()));
810
+ ), Be = k(
811
+ (g) => {
812
+ m && (g.preventDefault(), u("page", ne()));
815
813
  },
816
814
  [u, m]
817
815
  );
818
- K(() => {
819
- if (V && I && I.length < v.length && F.current) {
820
- const p = F.current.querySelectorAll(".humany-guide-list > ul > li"), b = p[I.length];
821
- if (p.length === v.length && I.length) {
822
- const x = p[I.length];
823
- if (x) {
824
- const D = x.querySelector(
816
+ V(() => {
817
+ if (K && T && T.length < x.length && I.current) {
818
+ const g = I.current.querySelectorAll(".humany-guide-list > ul > li"), b = g[T.length];
819
+ if (g.length === x.length && T.length) {
820
+ const v = g[T.length];
821
+ if (v) {
822
+ const F = v.querySelector(
825
823
  ".humany-guide-link"
826
824
  );
827
- D && D.focus();
825
+ F && F.focus();
828
826
  }
829
827
  } else
830
- b && new MutationObserver((D, P) => {
831
- D.forEach((A) => {
832
- if (A.addedNodes) {
828
+ b && new MutationObserver((F, P) => {
829
+ F.forEach((D) => {
830
+ if (D.addedNodes) {
833
831
  const B = Array.from(
834
- A.addedNodes
832
+ D.addedNodes
835
833
  ).find((G) => G.tagName === "A");
836
- B && tt(F.current, document.activeElement) && (V && B.focus(), P.disconnect());
834
+ B && Ze(I.current, document.activeElement) && (K && B.focus(), P.disconnect());
837
835
  }
838
836
  });
839
837
  }).observe(b, {
@@ -847,20 +845,20 @@ const at = ({
847
845
  }
848
846
  });
849
847
  const Re = !!Object.keys(l).filter(
850
- (p) => typeof l[p] != "undefined"
848
+ (g) => typeof l[g] != "undefined"
851
849
  ).length;
852
850
  return /* @__PURE__ */ n.createElement(
853
- St,
854
- k(y({
855
- className: S(E, "humany-guide-list"),
856
- "data-item-count": v.length,
857
- items: v,
851
+ yt,
852
+ E(y({
853
+ className: z(S, "humany-guide-list"),
854
+ "data-item-count": x.length,
855
+ items: x,
858
856
  renderItem: Pe,
859
- isTabbing: V,
857
+ isTabbing: K,
860
858
  expandable: t ? "true" : "false",
861
859
  "grid-items": o || c || Re ? "true" : "false"
862
- }, xe(De)), {
863
- ref: F
860
+ }, ve(Fe)), {
861
+ ref: I
864
862
  }),
865
863
  h ? /* @__PURE__ */ n.createElement(
866
864
  Q,
@@ -868,7 +866,7 @@ const at = ({
868
866
  text: h,
869
867
  title: h,
870
868
  "aria-label": h,
871
- routeName: Ae,
869
+ routeName: De,
872
870
  role: s,
873
871
  params: ne(),
874
872
  onClick: Be
@@ -881,10 +879,10 @@ const at = ({
881
879
  }
882
880
  )
883
881
  ) : null,
884
- g
882
+ p
885
883
  );
886
884
  }
887
- ), St = d(O)`
885
+ ), yt = d(O)`
888
886
  ${Y}
889
887
  padding: ${(t) => {
890
888
  var e;
@@ -1035,8 +1033,8 @@ const at = ({
1035
1033
  text-decoration: underline;
1036
1034
  }
1037
1035
  }
1038
- `, Nt = d(Z)`
1039
- ${pe}
1036
+ `, $t = d(Z)`
1037
+ ${ge}
1040
1038
  display: flex;
1041
1039
  margin: 0 0 0 auto;
1042
1040
  grid-area: tags;
@@ -1051,7 +1049,7 @@ const at = ({
1051
1049
  align-items: center;
1052
1050
  justify-content: space-between;
1053
1051
  }
1054
- `, Lt = d(N)`
1052
+ `, vt = d(N)`
1055
1053
  display: block;
1056
1054
  color: ${(t) => {
1057
1055
  var e;
@@ -1068,7 +1066,7 @@ const at = ({
1068
1066
  font-size: ${t.size}px;
1069
1067
  `;
1070
1068
  }}
1071
- `, Dt = d(Et)`
1069
+ `, xt = d(ht)`
1072
1070
  grid-area: metadata;
1073
1071
  text-overflow: ellipsis;
1074
1072
  overflow: hidden;
@@ -1080,11 +1078,11 @@ const at = ({
1080
1078
  var e;
1081
1079
  return typeof t.indent == "number" && `text-indent: calc(${(e = t.theme.sizes) == null ? void 0 : e.small} * 2 + ${t.indent}px);`;
1082
1080
  }}
1083
- `, Ft = he`
1081
+ `, bt = Ee`
1084
1082
  100% {
1085
1083
  transform: rotate(360deg);
1086
1084
  }
1087
- `, It = he`
1085
+ `, wt = Ee`
1088
1086
  0% {
1089
1087
  stroke-dasharray: 1, 200;
1090
1088
  stroke-dashoffset: 0;
@@ -1097,8 +1095,8 @@ const at = ({
1097
1095
  stroke-dasharray: 89, 200;
1098
1096
  stroke-dashoffset: -124px;
1099
1097
  }
1100
- `, At = d.svg`
1101
- animation: ${Ft} 2s linear infinite;
1098
+ `, Et = d.svg`
1099
+ animation: ${bt} 2s linear infinite;
1102
1100
  height: 100%;
1103
1101
  transform-origin: center center;
1104
1102
  width: 100%;
@@ -1109,7 +1107,7 @@ const at = ({
1109
1107
  right: 0;
1110
1108
  margin: auto;
1111
1109
  transition: 200ms ease-out opacity;
1112
- `, Tt = d.div`
1110
+ `, kt = d.div`
1113
1111
  position: absolute;
1114
1112
  top: 0;
1115
1113
  bottom: 0;
@@ -1128,7 +1126,7 @@ const at = ({
1128
1126
  .humany-spinner-svg {
1129
1127
  opacity: ${(t) => t["data-loading"] ? "1" : "0"};
1130
1128
  }
1131
- `, Ct = d.div`
1129
+ `, zt = d.div`
1132
1130
  position: relative;
1133
1131
  margin: 0 auto;
1134
1132
  width: 100px;
@@ -1137,18 +1135,18 @@ const at = ({
1137
1135
  display: block;
1138
1136
  padding-top: 100%;
1139
1137
  }
1140
- `, Mt = d.circle`
1138
+ `, St = d.circle`
1141
1139
  stroke-dasharray: 1, 200;
1142
1140
  stroke-dashoffset: 0;
1143
- animation: ${It} 1.5s ease-in-out infinite;
1141
+ animation: ${wt} 1.5s ease-in-out infinite;
1144
1142
  stroke-linecap: round;
1145
1143
  stroke: ${(t) => {
1146
1144
  var e;
1147
1145
  return (e = t.theme.colors) == null ? void 0 : e.primary;
1148
1146
  }};
1149
1147
  stroke-width: 2px;
1150
- `, Pt = ({ loading: t = !1 }) => /* @__PURE__ */ n.createElement(Tt, { className: "humany-loader", "data-loading": t }, /* @__PURE__ */ n.createElement(Ct, { className: "humany-spinner" }, /* @__PURE__ */ n.createElement(At, { className: "humany-spinner-svg", viewBox: "25 25 50 50" }, /* @__PURE__ */ n.createElement(
1151
- Mt,
1148
+ `, Nt = ({ loading: t = !1 }) => /* @__PURE__ */ n.createElement(kt, { className: "humany-loader", "data-loading": t }, /* @__PURE__ */ n.createElement(zt, { className: "humany-spinner" }, /* @__PURE__ */ n.createElement(Et, { className: "humany-spinner-svg", viewBox: "25 25 50 50" }, /* @__PURE__ */ n.createElement(
1149
+ St,
1152
1150
  {
1153
1151
  cx: "50",
1154
1152
  cy: "50",
@@ -1157,7 +1155,7 @@ const at = ({
1157
1155
  "stroke-width": "2",
1158
1156
  "stroke-miterlimit": "10"
1159
1157
  }
1160
- )))), Bt = Pt, Rt = (i) => {
1158
+ )))), ea = (i) => {
1161
1159
  var o = i, {
1162
1160
  className: t,
1163
1161
  showHeader: e,
@@ -1169,61 +1167,61 @@ const at = ({
1169
1167
  "notificationList",
1170
1168
  "loading"
1171
1169
  ]);
1172
- const [c, m] = T(null), {
1170
+ const [c, m] = A(null), {
1173
1171
  id: f,
1174
1172
  title: u,
1175
1173
  symbol: l,
1176
1174
  notifications: h = [],
1177
- defaultHeaderOptions: E = { visible: !0 }
1175
+ defaultHeaderOptions: S = { visible: !0 }
1178
1176
  } = a || {};
1179
1177
  return !h.length && !r ? null : /* @__PURE__ */ n.createElement(
1180
- Ht,
1181
- k(y({}, s), {
1178
+ Ft,
1179
+ E(y({}, s), {
1182
1180
  "data-loading": r,
1183
- "data-show-header": typeof e == "boolean" ? e : E.visible,
1184
- className: S(t, "humany-notification-list"),
1181
+ "data-show-header": typeof e == "boolean" ? e : S.visible,
1182
+ className: z(t, "humany-notification-list"),
1185
1183
  "data-notification-category": f,
1186
1184
  header: u,
1187
1185
  symbol: l,
1188
1186
  items: h,
1189
- renderItem: ({ id: g, title: v, body: L, modified: C, expandable: M }) => /* @__PURE__ */ n.createElement(
1190
- jt,
1187
+ renderItem: ({ id: p, title: x, body: L, modified: C, expandable: M }) => /* @__PURE__ */ n.createElement(
1188
+ It,
1191
1189
  {
1192
- key: g,
1193
- "data-notification": g,
1194
- "data-expanded": M ? c === g : !0
1190
+ key: p,
1191
+ "data-notification": p,
1192
+ "data-expanded": M ? c === p : !0
1195
1193
  },
1196
1194
  M ? /* @__PURE__ */ n.createElement(n.Fragment, null, /* @__PURE__ */ n.createElement(
1197
- Wt,
1195
+ Lt,
1198
1196
  {
1199
- title: v,
1200
- "aria-label": v,
1201
- "aria-expanded": c === g,
1202
- onClick: () => m(c === g ? null : g)
1197
+ title: x,
1198
+ "aria-label": x,
1199
+ "aria-expanded": c === p,
1200
+ onClick: () => m(c === p ? null : p)
1203
1201
  },
1204
- /* @__PURE__ */ n.createElement("span", null, v),
1202
+ /* @__PURE__ */ n.createElement("span", null, x),
1205
1203
  /* @__PURE__ */ n.createElement(
1206
- Ot,
1204
+ Tt,
1207
1205
  {
1208
1206
  size: 11,
1209
1207
  symbol: {
1210
1208
  type: "Svg",
1211
- content: `caret-${c === g ? "up" : "down"}`
1209
+ content: `caret-${c === p ? "up" : "down"}`
1212
1210
  }
1213
1211
  }
1214
1212
  )
1215
- ), /* @__PURE__ */ n.createElement(fe, { html: L }), C && /* @__PURE__ */ n.createElement(
1216
- Yt,
1213
+ ), /* @__PURE__ */ n.createElement(ue, { html: L }), C && /* @__PURE__ */ n.createElement(
1214
+ Dt,
1217
1215
  {
1218
1216
  format: be.YYYY_MM_DD,
1219
1217
  timestamp: C
1220
1218
  }
1221
- )) : /* @__PURE__ */ n.createElement(fe, { html: L })
1219
+ )) : /* @__PURE__ */ n.createElement(ue, { html: L })
1222
1220
  )
1223
1221
  }),
1224
- /* @__PURE__ */ n.createElement(Bt, { loading: r })
1222
+ /* @__PURE__ */ n.createElement(Nt, { loading: r })
1225
1223
  );
1226
- }, Wt = d(te)`
1224
+ }, Lt = d(te)`
1227
1225
  display: flex;
1228
1226
  justify-content: space-between;
1229
1227
  align-items: center;
@@ -1260,8 +1258,8 @@ const at = ({
1260
1258
  text-decoration: underline;
1261
1259
  }
1262
1260
  }
1263
- `, Ht = d(O)`
1264
- ${ut}
1261
+ `, Ft = d(O)`
1262
+ ${lt}
1265
1263
  ${Y}
1266
1264
  overflow: hidden;
1267
1265
  justify-content: flex-start;
@@ -1285,14 +1283,14 @@ const at = ({
1285
1283
  text-decoration: underline;
1286
1284
  }
1287
1285
  }
1288
- `, fe = d(Ue)`
1286
+ `, ue = d(Ue)`
1289
1287
  ${Je}
1290
1288
  font-weight: 300;
1291
1289
 
1292
1290
  p {
1293
1291
  white-space: normal;
1294
1292
  }
1295
- `, jt = d.li`
1293
+ `, It = d.li`
1296
1294
  .humany-paragraph {
1297
1295
  display: none;
1298
1296
  &:not(:only-child) {
@@ -1319,7 +1317,7 @@ const at = ({
1319
1317
  return (e = t.theme.colors) == null ? void 0 : e.accent;
1320
1318
  }};
1321
1319
  }
1322
- `, Ot = d(N)`
1320
+ `, Tt = d(N)`
1323
1321
  margin: 0 0 0 ${(t) => {
1324
1322
  var e;
1325
1323
  return (e = t.theme.sizes) == null ? void 0 : e.small;
@@ -1330,19 +1328,19 @@ const at = ({
1330
1328
  return (e = t.theme.colors) == null ? void 0 : e.primary;
1331
1329
  }};
1332
1330
  }
1333
- `, Yt = d(we)`
1331
+ `, Dt = d(xe)`
1334
1332
  font-size: ${(t) => {
1335
1333
  var e;
1336
1334
  return (e = t.theme.fonts) == null ? void 0 : e.small;
1337
1335
  }};
1338
1336
  font-weight: 300;
1339
- `, fa = Rt, _t = (t) => new RegExp("^#", "i").test(t), Kt = (t) => (r) => {
1337
+ `, At = (t) => new RegExp("^#", "i").test(t), Ct = (t) => (r) => {
1340
1338
  var s = r, { children: e } = s, a = w(s, ["children"]);
1341
1339
  const {
1342
1340
  implementation: i,
1343
1341
  name: o
1344
1342
  } = t.get("$widget"), { href: c = "" } = a;
1345
- if (_t(c))
1343
+ if (At(c))
1346
1344
  return /* @__PURE__ */ n.createElement(Qe, { smooth: !0, to: c }, e);
1347
1345
  const m = i.bindings.map((l) => l.replace(/\./g, "\\.")).join("|"), u = new RegExp(`^((http[s]?:)?//)?(${m})/([^\\s]+)`).exec(c);
1348
1346
  if (u && u.length >= 4) {
@@ -1351,7 +1349,7 @@ const at = ({
1351
1349
  return /* @__PURE__ */ n.createElement(Xe, { widgetName: l }, e);
1352
1350
  }
1353
1351
  return /* @__PURE__ */ n.createElement("a", y({}, a), e);
1354
- }, Vt = Kt, qt = (t, e = []) => ({
1352
+ }, ta = (t, e = []) => ({
1355
1353
  transform: {
1356
1354
  a: (a) => {
1357
1355
  const c = a, { children: r } = c, i = w(c, ["children"])["data-target"];
@@ -1360,32 +1358,32 @@ const at = ({
1360
1358
  if (m)
1361
1359
  return /* @__PURE__ */ n.createElement(ke, y({}, m), r);
1362
1360
  }
1363
- return Vt(t)(a);
1361
+ return Ct(t)(a);
1364
1362
  }
1365
1363
  }
1366
- }), ha = qt;
1364
+ });
1367
1365
  export {
1368
- da as AccordionListItem,
1366
+ Xt as AccordionListItem,
1369
1367
  ke as DialogLink,
1370
- ta as DialogList,
1371
- aa as DrawerList,
1372
- na as DropdownActions,
1373
- ra as DropdownList,
1374
- gt as FavoriteButton,
1375
- ia as Feedback,
1376
- ua as GuideList,
1377
- Bt as Loader,
1378
- Tt as LoaderWrapper,
1379
- Et as Metadata,
1380
- fa as NotificationList,
1381
- oa as SmallCaret,
1382
- sa as StyledHeaderText,
1383
- ft as StyledListButton,
1384
- ha as guideRenderInstructions,
1385
- ut as loadingOpacity,
1386
- la as useArrowKeys,
1387
- ca as useDebounce,
1388
- bt as useFavorites,
1389
- ma as useHover
1368
+ Ot as DialogList,
1369
+ Yt as DrawerList,
1370
+ _t as DropdownActions,
1371
+ Vt as DropdownList,
1372
+ mt as FavoriteButton,
1373
+ Gt as Feedback,
1374
+ Zt as GuideList,
1375
+ Nt as Loader,
1376
+ kt as LoaderWrapper,
1377
+ ht as Metadata,
1378
+ ea as NotificationList,
1379
+ Kt as SmallCaret,
1380
+ qt as StyledHeaderText,
1381
+ ct as StyledListButton,
1382
+ ta as guideRenderInstructions,
1383
+ lt as loadingOpacity,
1384
+ Ut as useArrowKeys,
1385
+ Jt as useDebounce,
1386
+ ut as useFavorites,
1387
+ Qt as useHover
1390
1388
  };
1391
1389
  //# sourceMappingURL=index.js.map