@ynput/ayon-frontend-shared 0.6.6 → 0.6.8

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 (53) hide show
  1. package/dist/DetailsPanel.es.js +4 -4
  2. package/dist/ListTable.es.js +2 -2
  3. package/dist/NewEntity.es.js +49 -49
  4. package/dist/ProjectTreeTable.es.js +501 -496
  5. package/dist/Slicer.es.js +27 -27
  6. package/dist/Views.es.js +213 -206
  7. package/dist/api.es.js +362 -360
  8. package/dist/chunks/Actions.es.js +21 -21
  9. package/dist/chunks/CodeEditor.es.js +30 -0
  10. package/dist/chunks/ColumnDropIndicator.es.js +5 -5
  11. package/dist/chunks/ColumnDropIndicator.styled.es.js +24 -24
  12. package/dist/chunks/ColumnHeaderMenuUI.es.js +2 -2
  13. package/dist/chunks/DeleteEntitiesContextInstance.es.js +96 -96
  14. package/dist/chunks/EmptyPlaceholder.es.js +9 -9
  15. package/dist/chunks/EntityPath.es.js +3 -3
  16. package/dist/chunks/EntityTooltip.es.js +1 -1
  17. package/dist/chunks/EntityUpdatesContext.es.js +1 -1
  18. package/dist/chunks/Feed.es.js +1625 -1573
  19. package/dist/chunks/JsonViewer.es.js +1 -1
  20. package/dist/chunks/Menu.es.js +1 -1
  21. package/dist/chunks/MenuItem.es.js +25 -25
  22. package/dist/chunks/MetaWidget.es.js +1537 -1516
  23. package/dist/chunks/PlayableIcon.es.js +128 -128
  24. package/dist/chunks/ProjectContext.es.js +11 -11
  25. package/dist/chunks/ReviewablesSelector.es.js +553 -462
  26. package/dist/chunks/SimpleForm.es.js +7 -7
  27. package/dist/chunks/SimpleTable.es.js +110 -110
  28. package/dist/chunks/Slicer.es.js +80 -80
  29. package/dist/chunks/TableSettingsFallback.es.js +1 -1
  30. package/dist/chunks/ThumbnailSimple.es.js +17 -17
  31. package/dist/chunks/VideoPlayer.es.js +1 -1
  32. package/dist/chunks/Watchers.es.js +50 -50
  33. package/dist/chunks/afterStartup.es.js +13 -0
  34. package/dist/chunks/getBundleMode.es.js +1 -1
  35. package/dist/chunks/getUris.es.js +797 -827
  36. package/dist/chunks/searchTerms.es.js +353 -336
  37. package/dist/chunks/useAttributeEnums.es.js +16 -16
  38. package/dist/chunks/useHierarchySelection.es.js +2 -2
  39. package/dist/chunks/useLoadModule.es.js +24 -23
  40. package/dist/chunks/viewUpdateHelper.es.js +8 -8
  41. package/dist/components.es.js +205 -202
  42. package/dist/context.es.js +525 -496
  43. package/dist/hooks.es.js +190 -166
  44. package/dist/types/ContextMenu.d.ts +1 -0
  45. package/dist/types/ProjectTreeTable.d.ts +1 -0
  46. package/dist/types/Views.d.ts +11 -0
  47. package/dist/types/api.d.ts +823 -1427
  48. package/dist/types/components.d.ts +9 -1
  49. package/dist/types/context.d.ts +1 -0
  50. package/dist/types/hooks.d.ts +25 -1
  51. package/dist/types/util.d.ts +10 -0
  52. package/dist/util.es.js +45 -42
  53. package/package.json +2 -2
package/dist/Slicer.es.js CHANGED
@@ -1,18 +1,18 @@
1
1
  import { S as Ve, a as je, b as Ne, c as et, d as tt, e as st, f as nt, g as ot, r as rt, u as it, h as ct, i as lt, j as dt, k as at } from "./chunks/Slicer.es.js";
2
2
  import { jsx as Se } from "react/jsx-runtime";
3
- import { useState as A, useEffect as M, useRef as Y, useCallback as m, useMemo as L } from "react";
4
- import { a as z, o as U, s as ce, q as ye } from "./chunks/DeleteEntitiesContextInstance.es.js";
3
+ import { useState as A, useEffect as M, useRef as U, useCallback as m, useMemo as L } from "react";
4
+ import { a as X, r as q, w as ce, p as ye } from "./chunks/DeleteEntitiesContextInstance.es.js";
5
5
  import { S as he, c as pe, d as Ee } from "./chunks/MetaWidget.es.js";
6
6
  import { e as ft, u as St } from "./chunks/MetaWidget.es.js";
7
7
  import "@module-federation/enhanced/runtime";
8
- import { az as B, aq as Ie } from "./chunks/searchTerms.es.js";
8
+ import "react-toastify";
9
+ import "@ynput/ayon-react-components";
10
+ import { aA as B, ar as Ie } from "./chunks/searchTerms.es.js";
9
11
  import "./chunks/getUris.es.js";
10
12
  import "primereact/confirmdialog";
11
13
  import "lodash";
12
- import "react-toastify";
13
14
  import "uuid";
14
15
  import { u as le } from "./chunks/useLoadModule.es.js";
15
- import "@ynput/ayon-react-components";
16
16
  import "./chunks/ContextMenuContextInstance.es.js";
17
17
  import "clsx";
18
18
  import "react-dom";
@@ -28,7 +28,7 @@ const me = () => {
28
28
  formatAttribute: () => [],
29
29
  formatProductTypes: () => [],
30
30
  formatAuthors: () => []
31
- }), { powerLicense: e } = z(), [s, { isLoading: c }] = le({
31
+ }), { powerLicense: e } = X(), [s, { isLoading: c }] = le({
32
32
  addon: "powerpack",
33
33
  remote: "slicer",
34
34
  module: "useExtraSlices",
@@ -60,10 +60,10 @@ const me = () => {
60
60
  window.removeEventListener("session-storage", t), window.removeEventListener("storage", t);
61
61
  };
62
62
  }, []);
63
- const S = Y(/* @__PURE__ */ new Map()), d = m((t, a) => {
63
+ const S = U(/* @__PURE__ */ new Map()), d = m((t, a) => {
64
64
  const u = typeof window > "u" ? null : sessionStorage.getItem(t), I = S.current.get(t);
65
65
  if (I && I.raw === u) return I.value;
66
- const _ = U(t, a);
66
+ const _ = q(t, a);
67
67
  return S.current.set(t, { raw: u, value: _ }), _;
68
68
  }, []), o = n[0], y = m(
69
69
  (t) => c.rowSelection !== void 0 && t === o ? c.rowSelection : d(de(s, e, t), {}),
@@ -109,7 +109,7 @@ const me = () => {
109
109
  getPanelExpanded: w,
110
110
  setPanelExpanded: i
111
111
  };
112
- }, ue = ["overview", "products"], Ue = ({
112
+ }, ue = ["overview", "products"], qe = ({
113
113
  children: n,
114
114
  page: e,
115
115
  projectName: s,
@@ -123,7 +123,7 @@ const me = () => {
123
123
  const [y, h] = ye(
124
124
  `slicer-pinned-slice-${e}`,
125
125
  null
126
- ), { powerLicense: w } = z(), i = c, P = i?.sliceTypes, E = i?.sliceType, T = P?.length ? E && E !== P[0] ? [E, ...P.slice(1)] : P : [E ?? "hierarchy"], x = ue.includes(e) && !o.sliceType && !P?.length && T[0] !== "hierarchy" && y?.sliceType === "hierarchy" && Object.values(y.rowSelection || {}).some(Boolean), t = L(
126
+ ), { powerLicense: w } = X(), i = c, P = i?.sliceTypes, E = i?.sliceType, T = P?.length ? E && E !== P[0] ? [E, ...P.slice(1)] : P : [E ?? "hierarchy"], x = ue.includes(e) && !o.sliceType && !P?.length && T[0] !== "hierarchy" && y?.sliceType === "hierarchy" && Object.values(y.rowSelection || {}).some(Boolean), t = L(
127
127
  () => [
128
128
  ...new Set(
129
129
  o.sliceType ? [o.sliceType] : x ? [...T, "hierarchy"] : T
@@ -140,7 +140,7 @@ const me = () => {
140
140
  setExpanded: H,
141
141
  getPanelSelection: W,
142
142
  setPanelSelection: C,
143
- getPanelExpanded: X,
143
+ getPanelExpanded: z,
144
144
  setPanelExpanded: b
145
145
  } = Pe({
146
146
  sliceTypes: t,
@@ -174,24 +174,24 @@ const me = () => {
174
174
  k(t, g);
175
175
  },
176
176
  [u, k, t]
177
- ), F = `${s}-${e}`, Z = Y(/* @__PURE__ */ new Set());
177
+ ), F = `${s}-${e}`, Z = U(/* @__PURE__ */ new Set());
178
178
  M(() => {
179
179
  !x || l || Z.current.has(F) || (Z.current.add(F), Object.keys(W("hierarchy")).length || (C("hierarchy", y.rowSelection), b("hierarchy", y.expanded)), k(t));
180
180
  }, [x, l, F]);
181
- const V = Y(/* @__PURE__ */ new Set());
181
+ const V = U(/* @__PURE__ */ new Set());
182
182
  M(() => {
183
183
  if (V.current.has(F) || l || o.sliceType || o.rowSelection || o.setRowSelection || P?.length)
184
184
  return;
185
185
  V.current.add(F);
186
186
  const r = `slicer-selection-${s}-${e}`, g = `slicer-expanded-${s}-${e}`, p = T[0];
187
187
  if (p !== "hierarchy") {
188
- const R = U(r, null);
188
+ const R = q(r, null);
189
189
  if (R && Object.keys(R).length) {
190
190
  C(
191
191
  p,
192
192
  (ie) => Object.keys(ie).length ? ie : R
193
193
  );
194
- const v = U(g, null);
194
+ const v = q(g, null);
195
195
  v && b(p, v);
196
196
  }
197
197
  }
@@ -270,7 +270,7 @@ const me = () => {
270
270
  setPanelSliceType: te,
271
271
  getPanelSelection: W,
272
272
  setPanelSelection: C,
273
- getPanelExpanded: X,
273
+ getPanelExpanded: z,
274
274
  setPanelExpanded: b,
275
275
  collapsedPanels: u,
276
276
  togglePanelCollapsed: Q,
@@ -302,7 +302,7 @@ const me = () => {
302
302
  te,
303
303
  W,
304
304
  C,
305
- X,
305
+ z,
306
306
  b,
307
307
  O,
308
308
  J,
@@ -316,7 +316,7 @@ const me = () => {
316
316
  ]
317
317
  );
318
318
  return /* @__PURE__ */ Se(pe.Provider, { value: fe, children: n });
319
- }, ze = ({
319
+ }, Xe = ({
320
320
  sliceFilter: n,
321
321
  persistedHierarchySelection: e,
322
322
  filters: s,
@@ -381,7 +381,7 @@ const me = () => {
381
381
  taskIds: [],
382
382
  versionIds: [],
383
383
  productIds: []
384
- }, q = {
384
+ }, Y = {
385
385
  taskFolderIds: {},
386
386
  versionFolderIds: {},
387
387
  productFolderIds: {}
@@ -404,17 +404,17 @@ const me = () => {
404
404
  versionIds: [...e.version],
405
405
  productIds: [...e.product]
406
406
  };
407
- }, Xe = ({
407
+ }, ze = ({
408
408
  slices: n,
409
409
  projectName: e
410
410
  }) => {
411
- const s = ge(), [c, l] = A($), [f, S] = A($), [d, o] = A(q), [y, h] = A(""), w = n.find((E) => E.sliceType === "entityList")?.rowSelection, i = L(
411
+ const s = ge(), [c, l] = A($), [f, S] = A($), [d, o] = A(Y), [y, h] = A(""), w = n.find((E) => E.sliceType === "entityList")?.rowSelection, i = L(
412
412
  () => Object.keys(w ?? {}).filter((E) => w?.[E] && !E.startsWith("folder-")).sort(),
413
413
  [w]
414
414
  ), P = i.length && e ? `${e}|${i}` : "";
415
415
  return M(() => {
416
416
  if (!P) {
417
- l($), S($), o(q), h("");
417
+ l($), S($), o(Y), h("");
418
418
  return;
419
419
  }
420
420
  let E = !1;
@@ -435,7 +435,7 @@ const me = () => {
435
435
  );
436
436
  E || (l(u), o(a));
437
437
  } catch (x) {
438
- console.error("Error fetching entity list IDs:", x), E || (l($), S($), o(q));
438
+ console.error("Error fetching entity list IDs:", x), E || (l($), S($), o(Y));
439
439
  } finally {
440
440
  E || h(P);
441
441
  }
@@ -473,7 +473,7 @@ const me = () => {
473
473
  slices: n,
474
474
  attribFields: e
475
475
  }) => n.filter((s) => s.sliceType !== "hierarchy" && s.sliceType !== "entityList").map((s) => ve({ slice: s, attribFields: e })).filter((s) => !!s), Je = (n) => {
476
- const { slices: e, getPanelSelection: s } = Ee(), { powerLicense: c, isLoading: l } = z(), f = L(() => {
476
+ const { slices: e, getPanelSelection: s } = Ee(), { powerLicense: c, isLoading: l } = X(), f = L(() => {
477
477
  const d = e.map((o) => ({
478
478
  sliceType: o.sliceType,
479
479
  rowSelection: s(o.id)
@@ -497,7 +497,7 @@ export {
497
497
  et as SLICER_SPLITTER_STATE_KEY,
498
498
  tt as Slicer,
499
499
  pe as SlicerContext,
500
- Ue as SlicerProvider,
500
+ qe as SlicerProvider,
501
501
  st as buildListFolderRowId,
502
502
  nt as clampDraggedHeights,
503
503
  ve as createFilterFromSlicer,
@@ -505,11 +505,11 @@ export {
505
505
  ot as defaultSliceOptions,
506
506
  rt as resolvePanelLayout,
507
507
  it as useEntityListsSlice,
508
- ze as useFiltersWithHierarchy,
508
+ Xe as useFiltersWithHierarchy,
509
509
  ct as useHierarchyContextMenuItems,
510
510
  ht as useHierarchySelection,
511
511
  St as useOptionalSlicerContext,
512
- Xe as useSelectedEntityIds,
512
+ ze as useSelectedEntityIds,
513
513
  Ee as useSlicerContext,
514
514
  lt as useSlicerCounts,
515
515
  dt as useSlicerPanelHeights,