ode-explorer 1.3.2-dev.202401241302 → 1.3.2-develop-pedago.202401251156

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.
@@ -2,7 +2,7 @@ import { jsx as i, jsxs as y } from "react/jsx-runtime";
2
2
  import { Card as d, useOdeClient as C, useScrollToTop as T } from "@edifice-ui/react";
3
3
  import { useSpring as I, animated as a } from "@react-spring/web";
4
4
  import { Files as N } from "@edifice-ui/icons";
5
- import { h as x, i as j, u as A } from "./index2.js";
5
+ import { j, k as x, u as k } from "./index2.js";
6
6
  import "react";
7
7
  import "react-i18next";
8
8
  import "edifice-ts-client";
@@ -27,15 +27,15 @@ const E = ({
27
27
  var m, u;
28
28
  const {
29
29
  currentApp: n
30
- } = C(), l = x(), o = j(), {
30
+ } = C(), l = j(), o = x(), {
31
31
  setSelectedFolders: t,
32
32
  setFolderIds: c,
33
33
  openFolder: p
34
- } = A();
35
- function h(e) {
34
+ } = k();
35
+ function F(e) {
36
36
  o.includes(e.id) ? (c(o.filter((r) => r !== e.id)), t(l.filter((r) => r.id !== e.id))) : (c([...o, e.id]), t([...l, e]));
37
37
  }
38
- const F = I({
38
+ const h = I({
39
39
  from: {
40
40
  opacity: 0
41
41
  },
@@ -50,13 +50,13 @@ const E = ({
50
50
  } = e;
51
51
  return /* @__PURE__ */ i(a.li, { className: "g-col-4 z-1", style: {
52
52
  position: "relative",
53
- ...F
53
+ ...h
54
54
  }, children: /* @__PURE__ */ i(g, { name: S, app: n, isSelected: o.includes(e.id), onClick: () => {
55
55
  f(), p({
56
56
  folder: e,
57
57
  folderId: e.id
58
58
  });
59
- }, onSelect: () => h(e) }) }, r);
59
+ }, onSelect: () => F(e) }) }, r);
60
60
  }) }) : null;
61
61
  };
62
62
  export {
package/lib/MoveModal.js CHANGED
@@ -1,18 +1,18 @@
1
1
  import { jsxs as h, jsx as l } from "react/jsx-runtime";
2
- import { Modal as a, TreeView as T, Button as I } from "@edifice-ui/react";
2
+ import { Modal as a, TreeView as T, Button as v } from "@edifice-ui/react";
3
3
  import { createPortal as M } from "react-dom";
4
4
  import { useTranslation as y } from "react-i18next";
5
5
  import { useState as b } from "react";
6
6
  import { useQueryClient as F } from "@tanstack/react-query";
7
- import { s as x, h as S, g as w, u as g, t as B } from "./index2.js";
7
+ import { v as x, j as w, i as S, u as g, w as j } from "./index2.js";
8
8
  import "@edifice-ui/icons";
9
9
  import "edifice-ts-client";
10
10
  import "i18next";
11
11
  import "zustand";
12
- function C({
12
+ function B({
13
13
  onSuccess: n
14
14
  }) {
15
- const [d, t] = b(), r = x(), i = S(), m = w(), {
15
+ const [d, t] = b(), r = x(), i = w(), m = S(), {
16
16
  foldTreeItem: s,
17
17
  unfoldTreeItem: c
18
18
  } = g(), f = F();
@@ -25,7 +25,7 @@ function C({
25
25
  console.error(e);
26
26
  }
27
27
  }
28
- const v = (e) => {
28
+ const I = (e) => {
29
29
  var p;
30
30
  for (const o of i)
31
31
  if (e === o.id || e === o.parentId)
@@ -38,7 +38,7 @@ function C({
38
38
  return {
39
39
  disableSubmit: !d,
40
40
  handleTreeItemSelect: (e) => {
41
- v(e) ? t(e) : t(void 0);
41
+ I(e) ? t(e) : t(void 0);
42
42
  },
43
43
  handleTreeItemFold: s,
44
44
  handleTreeItemUnfold: async (e) => await c(e, f),
@@ -60,16 +60,16 @@ function z({
60
60
  handleTreeItemUnfold: s,
61
61
  onMove: c,
62
62
  disableSubmit: f
63
- } = C({
63
+ } = B({
64
64
  onSuccess: d
65
- }), u = B();
65
+ }), u = j();
66
66
  return /* @__PURE__ */ M(/* @__PURE__ */ h(a, { isOpen: n, onModalClose: t, id: "moveModal", children: [
67
67
  /* @__PURE__ */ l(a.Header, { onModalClose: t, children: r("explorer.move.title") }),
68
68
  /* @__PURE__ */ l(a.Subtitle, { children: r("explorer.move.subtitle") }),
69
69
  /* @__PURE__ */ l(a.Body, { children: /* @__PURE__ */ l(T, { data: u, onTreeItemSelect: m, onTreeItemFold: i, onTreeItemUnfold: s }) }),
70
70
  /* @__PURE__ */ h(a.Footer, { children: [
71
- /* @__PURE__ */ l(I, { color: "tertiary", onClick: t, type: "button", variant: "ghost", children: r("explorer.cancel") }),
72
- /* @__PURE__ */ l(I, { color: "primary", onClick: c, type: "button", variant: "filled", disabled: f, children: r("explorer.move") })
71
+ /* @__PURE__ */ l(v, { color: "tertiary", onClick: t, type: "button", variant: "ghost", children: r("explorer.cancel") }),
72
+ /* @__PURE__ */ l(v, { color: "primary", onClick: c, type: "button", variant: "filled", disabled: f, children: r("explorer.move") })
73
73
  ] })
74
74
  ] }), document.getElementById("portal"));
75
75
  }
@@ -7,7 +7,7 @@ import { useTranslation as A } from "react-i18next";
7
7
  import { Users as W, Globe as X } from "@edifice-ui/icons";
8
8
  import { OneProfile as Z } from "@edifice-ui/icons/nav";
9
9
  import b from "dayjs";
10
- import { n as ee, f as te, g as ne, u as oe, d as ae } from "./index2.js";
10
+ import { d as ee, h as te, i as ne, u as oe, e as ae } from "./index2.js";
11
11
  import "edifice-ts-client";
12
12
  import "i18next";
13
13
  import "zustand";
@@ -34,7 +34,7 @@ const P = ({
34
34
  } = A();
35
35
  return /* @__PURE__ */ s(j, { app: a, isSelected: n, isSelectable: d, onClick: o, onSelect: e, children: (h) => /* @__PURE__ */ g(J, { children: [
36
36
  /* @__PURE__ */ g(j.Body, { children: [
37
- /* @__PURE__ */ s("div", { className: "card-image medium", children: t != null && t.thumbnail ? /* @__PURE__ */ s(C, { alt: "", src: t == null ? void 0 : t.thumbnail, objectFit: "cover", className: "h-full" }) : /* @__PURE__ */ s(B, { app: a, iconFit: "ratio", size: "80", variant: "rounded" }) }),
37
+ /* @__PURE__ */ s("div", { className: "card-image medium", children: t != null && t.thumbnail ? /* @__PURE__ */ s(C, { alt: "", src: t == null ? void 0 : t.thumbnail, objectFit: "cover", className: "h-full w-100" }) : /* @__PURE__ */ s(B, { app: a, iconFit: "ratio", size: "80", variant: "rounded" }) }),
38
38
  /* @__PURE__ */ g("div", { className: "text-truncate", children: [
39
39
  /* @__PURE__ */ s(j.Title, { children: t == null ? void 0 : t.name }),
40
40
  /* @__PURE__ */ s(j.Text, { children: /* @__PURE__ */ s("em", { children: i }) })