@nivaro/react 0.2.54 → 0.2.56

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 (151) hide show
  1. package/dist/full.css +1 -1
  2. package/dist/hooks/useSessionRecorder.js +99 -98
  3. package/dist/index.d.ts +367 -2
  4. package/dist/index.js +645 -616
  5. package/dist/layout-editor.d.ts +4 -0
  6. package/dist/shared/components/BackgroundRunOffer.js +117 -0
  7. package/dist/shared/components/BroadcastView.js +214 -213
  8. package/dist/shared/components/CollectionBrowserView.js +2592 -2695
  9. package/dist/shared/components/ItemEditForm.js +4066 -3832
  10. package/dist/shared/components/JobsTray.js +100 -55
  11. package/dist/shared/components/MyWorkView.js +91 -89
  12. package/dist/shared/components/NotificationBell.js +80 -79
  13. package/dist/shared/components/ProfileView.js +568 -520
  14. package/dist/shared/components/RecordCompare.js +254 -0
  15. package/dist/shared/components/RecordReadView.js +599 -552
  16. package/dist/shared/components/ReportView.js +578 -543
  17. package/dist/shared/components/RowPresence.js +91 -0
  18. package/dist/shared/components/WidgetSlot.js +474 -458
  19. package/dist/shared/components/ai/AiAnalyticsView.js +16 -6
  20. package/dist/shared/components/ai/AskPanel.js +139 -119
  21. package/dist/shared/components/ai/FirstWeekCard.js +126 -0
  22. package/dist/shared/components/bulk/BulkFieldUpdate.js +289 -0
  23. package/dist/shared/components/bulk/bulk-field-options.js +45 -0
  24. package/dist/shared/components/charts/CumulativeFlowChart.js +176 -0
  25. package/dist/shared/components/chat/ChannelArchive.js +326 -0
  26. package/dist/shared/components/chat/ChannelExtras.js +141 -121
  27. package/dist/shared/components/chat/ChatAnalyticsView.js +112 -110
  28. package/dist/shared/components/chat/ChatPanel.js +1695 -1733
  29. package/dist/shared/components/chat/Composer.js +357 -303
  30. package/dist/shared/components/chat/MessageActions.js +92 -0
  31. package/dist/shared/components/chat/MessageFormat.js +290 -264
  32. package/dist/shared/components/chat/OutboxBubbles.js +146 -0
  33. package/dist/shared/components/chat/RequestIdCard.js +135 -0
  34. package/dist/shared/components/chat/RoomHeaderMenu.js +202 -0
  35. package/dist/shared/components/chat/RoomParts.js +213 -274
  36. package/dist/shared/components/chat/ScreenClip.js +184 -0
  37. package/dist/shared/components/chat/chat-core.js +402 -483
  38. package/dist/shared/components/chat/chat-drafts.js +59 -0
  39. package/dist/shared/components/chat/chat-emoji.js +348 -0
  40. package/dist/shared/components/chat/chat-local-time.js +41 -0
  41. package/dist/shared/components/chat/chat-outbox.js +303 -0
  42. package/dist/shared/components/chat/chat-window.js +163 -0
  43. package/dist/shared/components/chat/huddle/HuddleControls.js +143 -0
  44. package/dist/shared/components/chat/huddle/HuddleStage.js +164 -0
  45. package/dist/shared/components/chat/huddle/huddle-store.js +342 -0
  46. package/dist/shared/components/chat/huddle/useHuddle.js +58 -0
  47. package/dist/shared/components/help-videos/api.js +76 -73
  48. package/dist/shared/components/item-edit/CatalogPickerField.js +113 -112
  49. package/dist/shared/components/item-edit/ChangeReasonDialog.js +13 -13
  50. package/dist/shared/components/item-edit/FieldAffordances.js +2 -2
  51. package/dist/shared/components/item-edit/FieldRenderer.js +248 -245
  52. package/dist/shared/components/item-edit/FieldRow.js +292 -279
  53. package/dist/shared/components/item-edit/GroupSection.js +698 -574
  54. package/dist/shared/components/item-edit/InlineTableField.js +3 -1
  55. package/dist/shared/components/item-edit/RelationCombobox.js +186 -176
  56. package/dist/shared/components/item-edit/entry/EntryStrip.js +54 -0
  57. package/dist/shared/components/item-edit/entry/entry-keys.js +27 -0
  58. package/dist/shared/components/item-edit/entry/useEntryKeyboard.js +70 -0
  59. package/dist/shared/components/item-edit/entry/useEntryMode.js +59 -0
  60. package/dist/shared/components/item-edit/form-structure-ui.js +105 -0
  61. package/dist/shared/components/item-edit/lazy-sections.js +36 -0
  62. package/dist/shared/components/item-edit/lock-why.js +39 -32
  63. package/dist/shared/components/item-edit/picker-miss.js +26 -0
  64. package/dist/shared/components/item-edit/placement-behaviour.js +196 -0
  65. package/dist/shared/components/item-edit/useFormUsageBeacon.js +51 -45
  66. package/dist/shared/components/layout-editor/AddPanel.js +134 -117
  67. package/dist/shared/components/layout-editor/ChangeNote.js +25 -24
  68. package/dist/shared/components/layout-editor/CollabParts.js +80 -75
  69. package/dist/shared/components/layout-editor/DesignNode.js +126 -120
  70. package/dist/shared/components/layout-editor/EditorCanvas.js +30 -27
  71. package/dist/shared/components/layout-editor/EditorTopBar.js +203 -192
  72. package/dist/shared/components/layout-editor/HistoryPanel.js +120 -104
  73. package/dist/shared/components/layout-editor/LayoutEditor.js +768 -671
  74. package/dist/shared/components/layout-editor/RestorePiece.js +143 -0
  75. package/dist/shared/components/layout-editor/StagedChip.js +22 -0
  76. package/dist/shared/components/layout-editor/StructureMenu.js +237 -186
  77. package/dist/shared/components/layout-editor/collab/FormFollowShare.js +149 -103
  78. package/dist/shared/components/layout-editor/collab/collab-api.js +29 -26
  79. package/dist/shared/components/layout-editor/dnd/LayoutDndProvider.js +81 -80
  80. package/dist/shared/components/layout-editor/dnd/node.js +69 -57
  81. package/dist/shared/components/layout-editor/draft-recovery.js +113 -43
  82. package/dist/shared/components/layout-editor/entry/PlacementPresets.js +149 -0
  83. package/dist/shared/components/layout-editor/entry/entry-editor-context.js +10 -0
  84. package/dist/shared/components/layout-editor/entry/presets.js +71 -0
  85. package/dist/shared/components/layout-editor/entry/tab-order.js +110 -0
  86. package/dist/shared/components/layout-editor/entry/theme-preview.js +37 -0
  87. package/dist/shared/components/layout-editor/grid-guides.js +142 -0
  88. package/dist/shared/components/layout-editor/inspector/BehaviourSettings.js +402 -0
  89. package/dist/shared/components/layout-editor/inspector/BulkInspector.js +61 -57
  90. package/dist/shared/components/layout-editor/inspector/GroupInspector.js +247 -151
  91. package/dist/shared/components/layout-editor/inspector/Inspector.js +176 -155
  92. package/dist/shared/components/layout-editor/inspector/LookTab.js +167 -116
  93. package/dist/shared/components/layout-editor/inspector/PickerMisses.js +129 -0
  94. package/dist/shared/components/layout-editor/inspector/PickerTab.js +84 -82
  95. package/dist/shared/components/layout-editor/inspector/RulesTab.js +66 -62
  96. package/dist/shared/components/layout-editor/inspector/kit.js +69 -68
  97. package/dist/shared/components/layout-editor/outputs/OutputsButton.js +254 -0
  98. package/dist/shared/components/layout-editor/outputs/help-sheet.js +154 -0
  99. package/dist/shared/components/layout-editor/outputs/output-api.js +61 -0
  100. package/dist/shared/components/layout-editor/overview/describe-conditions.js +6 -0
  101. package/dist/shared/components/layout-editor/overview/purpose.js +15 -13
  102. package/dist/shared/components/layout-editor/parity-keys.json.js +1 -1
  103. package/dist/shared/components/layout-editor/restore-piece.js +192 -0
  104. package/dist/shared/components/layout-editor/section-structure.js +241 -0
  105. package/dist/shared/components/layout-editor/settings/EntrySection.js +296 -0
  106. package/dist/shared/components/layout-editor/settings/FormSettings.js +41 -39
  107. package/dist/shared/components/layout-editor/settings/ResolveSettings.js +255 -0
  108. package/dist/shared/components/layout-editor/settings/ToolsSection.js +147 -111
  109. package/dist/shared/components/layout-editor/settings/WhoSection.js +29 -26
  110. package/dist/shared/components/layout-editor/settings/settings-registry.js +114 -17
  111. package/dist/shared/components/layout-editor/staged-api.js +64 -0
  112. package/dist/shared/components/layout-editor/structure-ops.js +81 -77
  113. package/dist/shared/components/layout-editor/testing/TestingPanels.js +65 -60
  114. package/dist/shared/components/layout-editor/testing/testing-model.js +198 -185
  115. package/dist/shared/components/layout-editor/toolbar-kit.js +11 -11
  116. package/dist/shared/components/layout-editor/usage/AbTestSection.js +355 -0
  117. package/dist/shared/components/layout-editor/usage/UsagePanel.js +144 -70
  118. package/dist/shared/components/layout-editor/usage/ab-api.js +86 -0
  119. package/dist/shared/components/layout-editor/usage/suggest-collapse.js +32 -0
  120. package/dist/shared/components/layout-editor/useLayoutDraft.js +25 -24
  121. package/dist/shared/components/notifications/NotificationAnalyticsView.js +148 -77
  122. package/dist/shared/components/panels/ErpFailureBanner.js +18 -17
  123. package/dist/shared/components/panels/ExternalRequestsChip.js +63 -62
  124. package/dist/shared/components/pipeline/PipelineEditorView.js +106 -104
  125. package/dist/shared/components/profile/AgentsPanel.js +479 -0
  126. package/dist/shared/components/queue/QueueWorklist.js +1026 -1040
  127. package/dist/shared/components/support/SupportAnalytics.js +171 -0
  128. package/dist/shared/components/support/SupportView.js +75 -73
  129. package/dist/shared/lib/background-runs.js +150 -0
  130. package/dist/shared/lib/delivery-ack.js +9 -0
  131. package/dist/shared/lib/entry-badge-style.js +13 -0
  132. package/dist/shared/lib/entry-config.js +71 -0
  133. package/dist/shared/lib/form-sections.js +64 -0
  134. package/dist/shared/lib/form-structure.js +99 -0
  135. package/dist/shared/lib/form-usage-beacon.js +101 -52
  136. package/dist/shared/lib/jobs-tray.js +25 -23
  137. package/dist/shared/lib/keyset-pager.js +37 -0
  138. package/dist/shared/lib/layout-ops.js +84 -82
  139. package/dist/shared/lib/layout-resolve.js +113 -0
  140. package/dist/shared/lib/placement-behaviour.js +144 -0
  141. package/dist/shared/lib/prefetch.js +149 -0
  142. package/dist/shared/lib/presence-hooks.js +199 -0
  143. package/dist/shared/lib/record-outbox.js +82 -81
  144. package/dist/shared/lib/replay-socket.js +93 -0
  145. package/dist/shared/lib/request-gate.js +51 -50
  146. package/dist/shared/lib/room-gaps.js +96 -0
  147. package/dist/shared/lib/search-log.js +27 -0
  148. package/dist/shared/lib/socket-realtime.js +101 -80
  149. package/dist/shared/lib/stale-chunk.js +60 -0
  150. package/dist/shared/lib/worker-socket.js +200 -0
  151. package/package.json +1 -1
@@ -1,9 +1,10 @@
1
1
  import { useQuery as u, useInfiniteQuery as b, useQueryClient as f } from "@tanstack/react-query";
2
2
  import { useRef as F } from "react";
3
3
  import { useNivaroClient as d } from "../../context.js";
4
- import { patch as y, get as r, del as p, post as i, put as h } from "../../lib/commands.js";
4
+ import { patch as y, get as r, del as p, post as i, put as c } from "../../lib/commands.js";
5
5
  import { useLiveEvent as m } from "../../lib/live.js";
6
- import { cardAccent as w } from "./cards.js";
6
+ import { useLiveRefetchInterval as w } from "../../lib/live-queries.js";
7
+ import { cardAccent as _ } from "./cards.js";
7
8
  const l = {
8
9
  all: ["help-videos"],
9
10
  one: (s) => ["help-videos", "one", s],
@@ -27,7 +28,7 @@ const l = {
27
28
  * never refetch it. `n` bumps on Reload. */
28
29
  draftEdits: (s, a) => ["help-video-draft", s, a]
29
30
  }, q = (s, a) => String(s ?? "").toLowerCase() === String(a ?? "").toLowerCase();
30
- function c(s, a) {
31
+ function v(s, a) {
31
32
  const e = f(), t = F(s);
32
33
  t.current = s, m(
33
34
  "help-video:changed",
@@ -42,26 +43,28 @@ function c(s, a) {
42
43
  }
43
44
  );
44
45
  }
45
- async function _(s, a) {
46
+ async function K(s, a) {
46
47
  return (await s.request(r(`/help-videos/${a}`))).data;
47
48
  }
48
- function x(s) {
49
+ function I(s) {
49
50
  const a = d();
50
- return c([l.one(s ?? "")], s), u({
51
+ v([l.one(s ?? "")], s);
52
+ const e = w(4e3);
53
+ return u({
51
54
  queryKey: l.one(s ?? ""),
52
55
  enabled: !!s,
53
- queryFn: () => _(a, s),
56
+ queryFn: () => K(a, s),
54
57
  // Poll while a render runs so the status chip and the stream switch over by themselves.
55
- refetchInterval: (e) => {
56
- var n, o;
57
- const t = (o = (n = e.state.data) == null ? void 0 : n.published) == null ? void 0 : o.render_status;
58
- return t === "queued" || t === "rendering" ? 4e3 : !1;
58
+ refetchInterval: (t) => {
59
+ var o, h;
60
+ const n = (h = (o = t.state.data) == null ? void 0 : o.published) == null ? void 0 : h.render_status;
61
+ return n === "queued" || n === "rendering" ? e : !1;
59
62
  }
60
63
  });
61
64
  }
62
- function U(s, a = !0) {
65
+ function M(s, a = !0) {
63
66
  const e = d();
64
- return c([["help-videos", "for"]]), u({
67
+ return v([["help-videos", "for"]]), u({
65
68
  queryKey: l.forCtx(s),
66
69
  enabled: a && !!(s.collection || s.page),
67
70
  staleTime: 6e4,
@@ -73,31 +76,31 @@ function U(s, a = !0) {
73
76
  )
74
77
  });
75
78
  }
76
- function M(s, a = !0) {
79
+ function O(s, a = !0) {
77
80
  const e = d();
78
- return c([["help-videos", "form"]]), u({
81
+ return v([["help-videos", "form"]]), u({
79
82
  queryKey: ["help-videos", "form", s ?? ""],
80
83
  enabled: a && !!s,
81
84
  staleTime: 6e4,
82
85
  queryFn: () => e.request(r("/help-videos/for-form", { collection: s })).then((t) => t.data)
83
86
  });
84
87
  }
85
- function K(s) {
88
+ function V(s) {
86
89
  const a = s[s.length - 1];
87
90
  return a != null && a.data.length && s.reduce((t, n) => t + n.data.length, 0) < a.total ? s.length + 1 : void 0;
88
91
  }
89
- function O(s) {
92
+ function z(s) {
90
93
  const a = d();
91
- return c([["help-videos", "library"]]), b({
94
+ return v([["help-videos", "library"]]), b({
92
95
  queryKey: l.library(s),
93
96
  initialPageParam: 1,
94
97
  queryFn: ({ pageParam: e }) => a.request(r("/help-videos", { ...s, page: e })),
95
- getNextPageParam: (e, t) => K(t),
98
+ getNextPageParam: (e, t) => V(t),
96
99
  placeholderData: (e) => e,
97
100
  select: (e) => {
98
101
  var t, n, o;
99
102
  return {
100
- data: e.pages.flatMap((v) => v.data),
103
+ data: e.pages.flatMap((h) => h.data),
101
104
  total: ((t = e.pages[e.pages.length - 1]) == null ? void 0 : t.total) ?? 0,
102
105
  categories: ((n = e.pages[0]) == null ? void 0 : n.categories) ?? [],
103
106
  can_author: ((o = e.pages[0]) == null ? void 0 : o.can_author) ?? !1
@@ -111,24 +114,24 @@ async function g(s) {
111
114
  );
112
115
  return { data: a.data ?? [], paths: a.paths ?? [] };
113
116
  }
114
- function z() {
117
+ function Q() {
115
118
  const s = d();
116
- return c([l.required]), u({
119
+ return v([l.required]), u({
117
120
  queryKey: l.required,
118
121
  staleTime: 6e4,
119
122
  queryFn: () => g(s)
120
123
  });
121
124
  }
122
- function I() {
125
+ function S() {
123
126
  const s = d();
124
- return c([l.required]), u({
127
+ return v([l.required]), u({
125
128
  queryKey: l.required,
126
129
  staleTime: 6e4,
127
130
  queryFn: () => g(s),
128
131
  select: (a) => a.data
129
132
  });
130
133
  }
131
- function Q(s = !0) {
134
+ function j(s = !0) {
132
135
  const a = d();
133
136
  return u({
134
137
  queryKey: l.myPaths,
@@ -137,7 +140,7 @@ function Q(s = !0) {
137
140
  queryFn: async () => (await a.request(r("/help-videos/paths/mine"))).data
138
141
  });
139
142
  }
140
- function S(s = !0) {
143
+ function D(s = !0) {
141
144
  const a = d();
142
145
  return u({
143
146
  queryKey: l.paths,
@@ -145,25 +148,25 @@ function S(s = !0) {
145
148
  queryFn: async () => (await a.request(r("/help-videos/paths"))).data
146
149
  });
147
150
  }
148
- function j(s) {
151
+ function E(s) {
149
152
  const a = s.request.bind(s);
150
153
  return {
151
154
  create: (e) => a(i("/help-videos/paths", e)).then((t) => t.data),
152
155
  update: (e, t) => a(y(`/help-videos/paths/${e}`, t)).then((n) => n.data),
153
156
  /** The ordered video list; unknown ids are dropped. */
154
- setItems: (e, t) => a(h(`/help-videos/paths/${e}/items`, { video_ids: t })).then(
157
+ setItems: (e, t) => a(c(`/help-videos/paths/${e}/items`, { video_ids: t })).then(
155
158
  (n) => n.data
156
159
  ),
157
160
  /** The roles; a published path tells the roles that became required. */
158
161
  setRoles: (e, t) => a(
159
- h(`/help-videos/paths/${e}/roles`, {
162
+ c(`/help-videos/paths/${e}/roles`, {
160
163
  roles: t
161
164
  })
162
165
  ).then((n) => n.data),
163
166
  remove: (e) => a(p(`/help-videos/paths/${e}`))
164
167
  };
165
168
  }
166
- function D(s) {
169
+ function N(s) {
167
170
  const a = d();
168
171
  return u({
169
172
  queryKey: l.walk(s ?? ""),
@@ -174,7 +177,7 @@ function D(s) {
174
177
  )).data
175
178
  });
176
179
  }
177
- function E(s) {
180
+ function B(s) {
178
181
  const a = d(), e = f();
179
182
  return m(
180
183
  "help-video:question",
@@ -192,7 +195,7 @@ function E(s) {
192
195
  queryFn: () => $(a).questions(s)
193
196
  });
194
197
  }
195
- function N(s, a = !0) {
198
+ function J(s, a = !0) {
196
199
  const e = d();
197
200
  return u({
198
201
  queryKey: l.next(s ?? ""),
@@ -201,7 +204,7 @@ function N(s, a = !0) {
201
204
  queryFn: () => $(e).next(s)
202
205
  });
203
206
  }
204
- function B(s) {
207
+ function W(s) {
205
208
  const a = d();
206
209
  return u({
207
210
  queryKey: l.clips(s ?? ""),
@@ -211,13 +214,13 @@ function B(s) {
211
214
  const e = await a.request(r(`/help-videos/${s}/clips`));
212
215
  return Array.isArray(e == null ? void 0 : e.data) ? e.data : [];
213
216
  },
214
- refetchInterval: (e) => V(e.state.data) ? 2500 : !1
217
+ refetchInterval: (e) => C(e.state.data) ? 2500 : !1
215
218
  });
216
219
  }
217
- function V(s) {
220
+ function C(s) {
218
221
  return Array.isArray(s) && s.some((a) => a.status === "queued" || a.status === "rendering");
219
222
  }
220
- function J() {
223
+ function G() {
221
224
  const s = d();
222
225
  return u({
223
226
  queryKey: l.pages,
@@ -243,8 +246,8 @@ function $(s) {
243
246
  ...n ? { draft: 1 } : {}
244
247
  })
245
248
  ).then((o) => o.data.url),
246
- setContexts: (e, t) => a(h(`/help-videos/${e}/contexts`, { contexts: t })),
247
- setRequirements: (e, t) => a(h(`/help-videos/${e}/requirements`, { role_ids: t })),
249
+ setContexts: (e, t) => a(c(`/help-videos/${e}/contexts`, { contexts: t })),
250
+ setRequirements: (e, t) => a(c(`/help-videos/${e}/requirements`, { role_ids: t })),
248
251
  archive: (e) => a(p(`/help-videos/${e}`)),
249
252
  /** Deletes the video, its versions, files, views and requirements for good. Administrators
250
253
  * only (403 ADMIN_ONLY otherwise); 404 when it is already gone. */
@@ -252,7 +255,7 @@ function $(s) {
252
255
  draft: (e) => a(r(`/help-videos/${e}/draft/edits`)).then((t) => t.data),
253
256
  /** 409 HELP_VIDEO_EDITS_CONFLICT (with `current_hash`) when `base_hash` is stale;
254
257
  * 422 HELP_VIDEO_EDITS_INVALID when the edits keep under a second. */
255
- saveDraft: (e, t, n) => a(h(`/help-videos/${e}/draft/edits`, { edits: t, base_hash: n })).then(
258
+ saveDraft: (e, t, n) => a(c(`/help-videos/${e}/draft/edits`, { edits: t, base_hash: n })).then(
256
259
  (o) => o.data
257
260
  ),
258
261
  publish: (e, t, n) => a(
@@ -275,7 +278,7 @@ function $(s) {
275
278
  analytics: (e) => a(r(`/help-videos/${e}/analytics`)).then((t) => t.data),
276
279
  /** "Was this helpful?" — one vote per person per video, changeable. 403
277
280
  * HELP_VIDEO_MASQUERADE while viewing as someone else. */
278
- rate: (e, t) => a(h(`/help-videos/${e}/rating`, { helpful: t })).then(
281
+ rate: (e, t) => a(c(`/help-videos/${e}/rating`, { helpful: t })).then(
279
282
  (n) => n.data
280
283
  ),
281
284
  /** This person's questions on the video (authors: everyone's, with who
@@ -406,13 +409,13 @@ function $(s) {
406
409
  authorRoles: () => a(r("/settings")).then(
407
410
  (e) => {
408
411
  var t;
409
- return C((t = e.data) == null ? void 0 : t.help_video_author_roles);
412
+ return P((t = e.data) == null ? void 0 : t.help_video_author_roles);
410
413
  }
411
414
  ),
412
415
  setAuthorRoles: (e) => a(y("/settings", { help_video_author_roles: e }))
413
416
  };
414
417
  }
415
- async function W(s, a, e) {
418
+ async function X(s, a, e) {
416
419
  const t = new FormData();
417
420
  t.append("file", e, e.name);
418
421
  const n = await fetch(`${s.apiBase}/help-videos/${encodeURIComponent(a)}/music`, {
@@ -422,15 +425,15 @@ async function W(s, a, e) {
422
425
  body: t
423
426
  }), o = await n.json().catch(() => ({}));
424
427
  if (!n.ok || !o.data) {
425
- const v = o.message || o.error;
426
- throw Object.assign(new Error(v || "The music could not be uploaded"), {
428
+ const h = o.message || o.error;
429
+ throw Object.assign(new Error(h || "The music could not be uploaded"), {
427
430
  status: n.status,
428
431
  code: o.code
429
432
  });
430
433
  }
431
434
  return o.data;
432
435
  }
433
- function G(s) {
436
+ function Y(s) {
434
437
  var e, t;
435
438
  if (!s || typeof s != "object") return null;
436
439
  const a = s;
@@ -440,7 +443,7 @@ function G(s) {
440
443
  ...typeof ((t = a.response) == null ? void 0 : t.current_hash) == "string" ? { current_hash: a.response.current_hash } : {}
441
444
  };
442
445
  }
443
- function C(s) {
446
+ function P(s) {
444
447
  return (() => {
445
448
  if (Array.isArray(s)) return s;
446
449
  if (typeof s != "string" || !s.trim()) return [];
@@ -452,16 +455,16 @@ function C(s) {
452
455
  }
453
456
  })().filter((e) => typeof e == "string" && e.length > 0);
454
457
  }
455
- function P(s, a) {
458
+ function L(s, a) {
456
459
  var t;
457
460
  const e = s ? s.card_logo_url ?? s.logo_url : null;
458
461
  return {
459
462
  name: ((t = s == null ? void 0 : s.name) == null ? void 0 : t.trim()) || null,
460
- color: w(s == null ? void 0 : s.color),
463
+ color: _(s == null ? void 0 : s.color),
461
464
  logo: e ? `${a}${e}` : null
462
465
  };
463
466
  }
464
- function X(s, a) {
467
+ function Z(s, a) {
465
468
  var n;
466
469
  const e = d(), t = u({
467
470
  queryKey: ["help-video-card-brand"],
@@ -469,32 +472,32 @@ function X(s, a) {
469
472
  staleTime: 5 * 6e4,
470
473
  queryFn: () => e.request(r("/auth/branding"))
471
474
  });
472
- return P((n = t.data) == null ? void 0 : n.data, a);
475
+ return L((n = t.data) == null ? void 0 : n.data, a);
473
476
  }
474
477
  export {
475
- P as cardBrandFrom,
476
- V as clipsInFlight,
477
- _ as fetchHelpVideo,
478
+ L as cardBrandFrom,
479
+ C as clipsInFlight,
480
+ K as fetchHelpVideo,
478
481
  $ as helpVideoApi,
479
- G as helpVideoError,
482
+ Y as helpVideoError,
480
483
  l as helpVideoKeys,
481
- j as learningPathApi,
482
- K as nextLibraryPage,
483
- C as parseRoleIdList,
484
- W as uploadMusicFile,
485
- X as useCardBrand,
486
- x as useHelpVideo,
487
- B as useHelpVideoClips,
488
- O as useHelpVideoLibrary,
489
- c as useHelpVideoLive,
490
- N as useHelpVideoNext,
491
- J as useHelpVideoPages,
492
- E as useHelpVideoQuestions,
493
- D as useHelpVideoWalk,
494
- U as useHelpVideosFor,
495
- M as useHelpVideosForForm,
496
- S as useLearningPaths,
497
- Q as useMyLearningPaths,
498
- z as useRequiredList,
499
- I as useRequiredVideos
484
+ E as learningPathApi,
485
+ V as nextLibraryPage,
486
+ P as parseRoleIdList,
487
+ X as uploadMusicFile,
488
+ Z as useCardBrand,
489
+ I as useHelpVideo,
490
+ W as useHelpVideoClips,
491
+ z as useHelpVideoLibrary,
492
+ v as useHelpVideoLive,
493
+ J as useHelpVideoNext,
494
+ G as useHelpVideoPages,
495
+ B as useHelpVideoQuestions,
496
+ N as useHelpVideoWalk,
497
+ M as useHelpVideosFor,
498
+ O as useHelpVideosForForm,
499
+ D as useLearningPaths,
500
+ j as useMyLearningPaths,
501
+ Q as useRequiredList,
502
+ S as useRequiredVideos
500
503
  };