@burdenoff/microfe-files 2026.1115.1 → 2026.1115.2

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 (34) hide show
  1. package/dist/files/components/CopyDialog.d.ts +6 -0
  2. package/dist/files/components/CopyDialog.js +112 -101
  3. package/dist/files/components/CopyDialog.js.map +1 -1
  4. package/dist/files/components/FileBrowser.js +175 -165
  5. package/dist/files/components/FileBrowser.js.map +1 -1
  6. package/dist/files/components/FileInfoPanel.d.ts +7 -1
  7. package/dist/files/components/FileInfoPanel.js +225 -184
  8. package/dist/files/components/FileInfoPanel.js.map +1 -1
  9. package/dist/files/components/SearchBar.d.ts +7 -1
  10. package/dist/files/components/SearchBar.js +166 -159
  11. package/dist/files/components/SearchBar.js.map +1 -1
  12. package/dist/files/components/ShareAccessParts.d.ts +9 -1
  13. package/dist/files/components/ShareAccessParts.js +31 -23
  14. package/dist/files/components/ShareAccessParts.js.map +1 -1
  15. package/dist/files/components/ShareDialog.d.ts +5 -4
  16. package/dist/files/components/ShareDialog.js +31 -27
  17. package/dist/files/components/ShareDialog.js.map +1 -1
  18. package/dist/files/pages/BrowserPage.js +274 -271
  19. package/dist/files/pages/BrowserPage.js.map +1 -1
  20. package/dist/files/pages/ShareAccessPage.js +52 -51
  21. package/dist/files/pages/ShareAccessPage.js.map +1 -1
  22. package/dist/files/utils/fileKind.d.ts +16 -0
  23. package/dist/files/utils/fileKind.js +120 -0
  24. package/dist/files/utils/fileKind.js.map +1 -0
  25. package/dist/files/utils/infoTechnicalDetails.d.ts +12 -0
  26. package/dist/files/utils/infoTechnicalDetails.js +16 -0
  27. package/dist/files/utils/infoTechnicalDetails.js.map +1 -0
  28. package/dist/files/utils/shareAccess.d.ts +6 -0
  29. package/dist/files/utils/shareAccess.js +6 -1
  30. package/dist/files/utils/shareAccess.js.map +1 -1
  31. package/dist/translations/en.d.ts +29 -0
  32. package/dist/translations/en.js +32 -1
  33. package/dist/translations/en.js.map +1 -1
  34. package/package.json +2 -2
@@ -1,228 +1,269 @@
1
1
  import { tWithFallback as e } from "../utils/i18n.js";
2
- import { FileVisibilityControl as t } from "./FileVisibilityControl.js";
3
- import { Suspense as n, lazy as r, useEffect as i, useEffectEvent as a, useState as o } from "react";
4
- import { Calendar as s, Clock as c, FileText as l, HardDrive as u, Link as d, User as f, X as p } from "lucide-react";
5
- import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
6
- import { useI18n as _ } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
7
- import { GlassCard as v, ShowMore as y } from "@burdenoff/fe-libs/ui";
2
+ import { fileKindLabel as t } from "../utils/fileKind.js";
3
+ import { buildInfoTechnicalDetails as n } from "../utils/infoTechnicalDetails.js";
4
+ import { FileVisibilityControl as r } from "./FileVisibilityControl.js";
5
+ import { Suspense as i, lazy as a, useEffect as o, useEffectEvent as s, useState as c } from "react";
6
+ import { Calendar as l, Clock as u, FileText as d, HardDrive as f, Link as p, User as m, X as h } from "lucide-react";
7
+ import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
8
+ import { useI18n as y } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
9
+ import { Button as b, GlassCard as x, ShowMore as S, ShowTechnicalDetails as C } from "@burdenoff/fe-libs/ui";
8
10
  // src/files/components/FileInfoPanel.tsx
9
- var b = r(() => import("./FileVersionPanel.js").then((e) => ({ default: e.FileVersionPanel })));
10
- function x({ item: r, type: x, onClose: S }) {
11
- let { t: C } = _(), w = x === "file", T = w ? r : null, E = w ? null : r, [D, O] = o(!1), k = a(() => {
12
- D ? O(!1) : S();
11
+ var w = a(() => import("./FileVersionPanel.js").then((e) => ({ default: e.FileVersionPanel })));
12
+ function T({ item: t, type: n, onClose: a, navigationV2: l = !1 }) {
13
+ let { t: f } = y(), p = n === "file", m = p ? t : null, [g, b] = c(!1), S = s(() => {
14
+ g ? b(!1) : a();
13
15
  });
14
- i(() => {
16
+ return o(() => {
15
17
  let e = (e) => {
16
- e.key === "Escape" && k();
18
+ e.key === "Escape" && S();
17
19
  };
18
20
  return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
19
- }, []);
20
- let A = (e) => new Date(e).toLocaleString("en-US", {
21
- year: "numeric",
22
- month: "long",
23
- day: "numeric",
24
- hour: "2-digit",
25
- minute: "2-digit"
26
- });
27
- return /* @__PURE__ */ g("div", {
21
+ }, []), /* @__PURE__ */ v("div", {
28
22
  className: "fixed inset-y-0 right-0 z-[9999] w-full max-w-full overflow-y-auto border-l border-border-seam bg-bg-surface shadow-2xl animate-in slide-in-from-right duration-200 sm:w-96 [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]",
29
23
  role: "dialog",
30
24
  "aria-modal": "false",
31
- "aria-label": w ? e(C, "files.info.fileInfo", "File information") : e(C, "files.info.folderInfo", "Folder information"),
25
+ "aria-label": p ? e(f, "files.info.fileInfo", "File information") : e(f, "files.info.folderInfo", "Folder information"),
32
26
  children: [
33
- /* @__PURE__ */ g("div", {
27
+ /* @__PURE__ */ v("div", {
34
28
  className: "sticky top-0 z-10 bg-bg-surface border-b border-border-seam px-6 py-4 flex items-center justify-between",
35
- children: [/* @__PURE__ */ h("h2", {
29
+ children: [/* @__PURE__ */ _("h2", {
36
30
  className: "text-lg font-semibold text-text-primary",
37
- children: w ? e(C, "files.info.fileInfo", "File Information") : e(C, "files.info.folderInfo", "Folder Information")
38
- }), /* @__PURE__ */ h("button", {
31
+ children: p ? e(f, "files.info.fileInfo", "File Information") : e(f, "files.info.folderInfo", "Folder Information")
32
+ }), /* @__PURE__ */ _("button", {
39
33
  type: "button",
40
- onClick: S,
34
+ onClick: a,
41
35
  className: "p-1.5 rounded-md border border-border-default text-text-secondary bg-bg-elevated hover:bg-action-ghost-bg-hover hover:text-text-primary transition-colors shadow-sm",
42
- "aria-label": e(C, "files.info.closePanel", "Close information panel"),
43
- children: /* @__PURE__ */ h(p, { className: "size-5" })
36
+ "aria-label": e(f, "files.info.closePanel", "Close information panel"),
37
+ children: /* @__PURE__ */ _(h, { className: "size-5" })
44
38
  })]
45
39
  }),
46
- /* @__PURE__ */ g("div", {
40
+ /* @__PURE__ */ v("div", {
47
41
  className: "p-6 space-y-6",
48
42
  children: [
49
- /* @__PURE__ */ h(v, {
43
+ /* @__PURE__ */ _(x, {
50
44
  treatment: "metric",
51
45
  className: "flex items-center justify-center py-8",
52
- children: w && T?.mimeType.startsWith("image/") && (T.downloadUrl || T.url) ? /* @__PURE__ */ h("img", {
53
- src: T.downloadUrl || T.url,
54
- alt: r.name,
46
+ children: p && m?.mimeType.startsWith("image/") && (m.downloadUrl || m.url) ? /* @__PURE__ */ _("img", {
47
+ src: m.downloadUrl || m.url,
48
+ alt: t.name,
55
49
  className: "max-w-full max-h-48 object-contain rounded"
56
- }) : /* @__PURE__ */ h(l, { className: "size-20 text-text-muted" })
50
+ }) : /* @__PURE__ */ _(d, { className: "size-20 text-text-muted" })
57
51
  }),
58
- /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h3", {
52
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("h3", {
59
53
  className: "text-xl font-semibold text-text-primary break-words",
60
- children: r.name
61
- }), r.description && /* @__PURE__ */ h("p", {
54
+ children: t.name
55
+ }), t.description && /* @__PURE__ */ _("p", {
62
56
  className: "mt-2 text-sm text-text-secondary",
63
- children: r.description
57
+ children: t.description
64
58
  })] }),
65
- T && /* @__PURE__ */ h(t, { file: T }, `${T.id}:${T.visibility}`),
66
- /* @__PURE__ */ g("div", {
67
- className: "space-y-4",
68
- children: [
69
- /* @__PURE__ */ g("div", {
70
- className: "flex items-start gap-3",
71
- children: [/* @__PURE__ */ h(l, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
72
- className: "text-sm font-medium text-text-primary",
73
- children: e(C, "files.info.type", "Type")
74
- }), /* @__PURE__ */ h("p", {
75
- className: "text-sm text-text-secondary",
76
- children: w ? T?.mimeType || e(C, "files.info.unknown", "Unknown") : e(C, "files.info.folder", "Folder")
77
- })] })]
78
- }),
79
- w && T && /* @__PURE__ */ g("div", {
80
- className: "flex items-start gap-3",
81
- children: [/* @__PURE__ */ h(u, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
82
- className: "text-sm font-medium text-text-primary",
83
- children: e(C, "files.info.size", "Size")
84
- }), /* @__PURE__ */ h("p", {
85
- className: "text-sm text-text-secondary",
86
- children: ((e) => e < 1024 ? `${e} B` : e < 1048576 ? `${(e / 1024).toFixed(2)} KB` : e < 1073741824 ? `${(e / 1024 / 1024).toFixed(2)} MB` : `${(e / 1024 / 1024 / 1024).toFixed(2)} GB`)(T.size)
87
- })] })]
88
- }),
89
- !w && E && /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ g("div", {
90
- className: "flex items-start gap-3",
91
- children: [/* @__PURE__ */ h(l, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
92
- className: "text-sm font-medium text-text-primary",
93
- children: e(C, "files.info.contents", "Contents")
94
- }), /* @__PURE__ */ g("p", {
95
- className: "text-sm text-text-secondary",
96
- children: [
97
- E.filesCount,
98
- " ",
99
- e(C, "files.info.files", "files"),
100
- ",",
101
- " ",
102
- E.subfoldersCount,
103
- " ",
104
- e(C, "files.info.folders", "folders")
105
- ]
106
- })] })]
107
- }), E.path && /* @__PURE__ */ g("div", {
108
- className: "flex items-start gap-3",
109
- children: [/* @__PURE__ */ h(d, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
110
- className: "text-sm font-medium text-text-primary",
111
- children: e(C, "files.info.path", "Path")
112
- }), /* @__PURE__ */ h("p", {
113
- className: "text-sm text-text-secondary break-all",
114
- children: E.path
115
- })] })]
116
- })] }),
117
- /* @__PURE__ */ g("div", {
118
- className: "flex items-start gap-3",
119
- children: [/* @__PURE__ */ h(s, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
120
- className: "text-sm font-medium text-text-primary",
121
- children: e(C, "files.info.created", "Created")
122
- }), /* @__PURE__ */ h("p", {
123
- className: "text-sm text-text-secondary",
124
- children: A(r.createdAt)
125
- })] })]
126
- }),
127
- r.updatedAt && /* @__PURE__ */ g("div", {
128
- className: "flex items-start gap-3",
129
- children: [/* @__PURE__ */ h(s, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
130
- className: "text-sm font-medium text-text-primary",
131
- children: e(C, "files.info.modified", "Modified")
132
- }), /* @__PURE__ */ h("p", {
133
- className: "text-sm text-text-secondary",
134
- children: A(r.updatedAt)
135
- })] })]
136
- }),
137
- /* @__PURE__ */ g("div", {
138
- className: "flex items-start gap-3",
139
- children: [/* @__PURE__ */ h(f, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("p", {
140
- className: "text-sm font-medium text-text-primary",
141
- children: e(C, "files.info.owner", "Owner")
142
- }), /* @__PURE__ */ h("p", {
143
- className: "text-sm text-text-secondary",
144
- children: r.createdBy?.name || r.createdById || e(C, "files.info.unknown", "Unknown")
145
- })] })]
146
- })
147
- ]
148
- }),
149
- /* @__PURE__ */ g("div", {
150
- className: "pt-6 border-t border-border-seam",
151
- children: [/* @__PURE__ */ h("h4", {
152
- className: "text-sm font-semibold text-text-primary mb-3",
153
- children: e(C, "files.info.properties", "Properties")
154
- }), /* @__PURE__ */ h(y, {
155
- collapsedHeight: 56,
156
- children: /* @__PURE__ */ g("dl", {
157
- className: "space-y-2",
158
- children: [
159
- /* @__PURE__ */ g("div", {
160
- className: "flex justify-between",
161
- children: [/* @__PURE__ */ h("dt", {
162
- className: "text-sm text-text-secondary",
163
- children: e(C, "files.info.status", "Status")
164
- }), /* @__PURE__ */ h("dd", {
165
- className: "text-sm font-medium text-text-primary",
166
- children: r.status
167
- })]
168
- }),
169
- !w && /* @__PURE__ */ g("div", {
170
- className: "flex justify-between",
171
- children: [/* @__PURE__ */ h("dt", {
172
- className: "text-sm text-text-secondary",
173
- children: e(C, "files.info.visibility", "Visibility")
174
- }), /* @__PURE__ */ h("dd", {
175
- className: "text-sm font-medium text-text-primary",
176
- children: r.visibility
177
- })]
178
- }),
179
- /* @__PURE__ */ g("div", {
180
- className: "flex justify-between",
181
- children: [/* @__PURE__ */ h("dt", {
182
- className: "text-sm text-text-secondary",
183
- children: e(C, "files.info.starred", "Starred")
184
- }), /* @__PURE__ */ h("dd", {
185
- className: "text-sm font-medium text-text-primary",
186
- children: r.starred ? e(C, "files.info.yes", "Yes") : e(C, "files.info.no", "No")
187
- })]
188
- })
189
- ]
190
- })
191
- })]
59
+ m && /* @__PURE__ */ _(r, { file: m }, `${m.id}:${m.visibility}`),
60
+ /* @__PURE__ */ _(O, {
61
+ item: t,
62
+ type: n,
63
+ navigationV2: l
192
64
  }),
193
- w && T && /* @__PURE__ */ h("div", {
194
- className: "pt-6 border-t border-border-seam",
195
- children: /* @__PURE__ */ g("button", {
196
- type: "button",
197
- onClick: () => O(!0),
198
- className: "w-full flex items-center justify-center gap-2 px-4 py-3 text-sm font-medium text-action-primary-text bg-action-primary-bg/10 hover:bg-action-primary-bg/20 rounded-lg transition-all duration-200",
199
- children: [/* @__PURE__ */ h(c, { className: "size-4" }), e(C, "files.info.viewVersionHistory", "View Version History")]
200
- })
65
+ l ? /* @__PURE__ */ _(E, {
66
+ item: t,
67
+ type: n,
68
+ onShowVersionHistory: () => b(!0)
69
+ }) : /* @__PURE__ */ _(D, {
70
+ item: t,
71
+ isFile: p,
72
+ onShowVersionHistory: () => b(!0)
201
73
  })
202
74
  ]
203
75
  }),
204
- w && T && D && /* @__PURE__ */ h(n, {
205
- fallback: /* @__PURE__ */ h("div", {
76
+ p && m && g && /* @__PURE__ */ _(i, {
77
+ fallback: /* @__PURE__ */ _("div", {
206
78
  className: "fixed inset-0 z-50 bg-bg-overlay flex items-center justify-center",
207
- children: /* @__PURE__ */ h("div", {
79
+ children: /* @__PURE__ */ _("div", {
208
80
  className: "bg-bg-surface rounded-lg p-8 animate-in fade-in zoom-in duration-200",
209
- children: /* @__PURE__ */ g("div", {
81
+ children: /* @__PURE__ */ v("div", {
210
82
  className: "flex items-center gap-3",
211
- children: [/* @__PURE__ */ h(c, { className: "size-6 text-action-primary-bg animate-spin" }), /* @__PURE__ */ h("span", {
83
+ children: [/* @__PURE__ */ _(u, { className: "size-6 text-action-primary-bg animate-spin" }), /* @__PURE__ */ _("span", {
212
84
  className: "text-text-primary",
213
- children: e(C, "files.info.loadingVersionHistory", "Loading version history...")
85
+ children: e(f, "files.info.loadingVersionHistory", "Loading version history...")
214
86
  })]
215
87
  })
216
88
  })
217
89
  }),
218
- children: /* @__PURE__ */ h(b, {
219
- file: T,
220
- onClose: () => O(!1)
90
+ children: /* @__PURE__ */ _(w, {
91
+ file: m,
92
+ onClose: () => b(!1)
221
93
  })
222
94
  })
223
95
  ]
224
96
  });
225
97
  }
226
- export { x as FileInfoPanel };
98
+ function E({ item: t, type: r, onShowVersionHistory: i }) {
99
+ let { t: a } = y();
100
+ return /* @__PURE__ */ v("div", {
101
+ className: "pt-6 border-t border-border-seam space-y-2",
102
+ children: [/* @__PURE__ */ _(C, {
103
+ copyable: !0,
104
+ children: n(a, t, r)
105
+ }), r === "file" && /* @__PURE__ */ v(b, {
106
+ type: "button",
107
+ variant: "link",
108
+ size: "sm",
109
+ onClick: i,
110
+ className: "min-h-11 px-1",
111
+ children: [/* @__PURE__ */ _(u, {
112
+ className: "size-4",
113
+ "aria-hidden": "true"
114
+ }), e(a, "files.info.viewVersionHistory", "View Version History")]
115
+ })]
116
+ });
117
+ }
118
+ function D({ item: t, isFile: n, onShowVersionHistory: r }) {
119
+ let { t: i } = y();
120
+ return /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ v("div", {
121
+ className: "pt-6 border-t border-border-seam",
122
+ children: [/* @__PURE__ */ _("h4", {
123
+ className: "text-sm font-semibold text-text-primary mb-3",
124
+ children: e(i, "files.info.properties", "Properties")
125
+ }), /* @__PURE__ */ _(S, {
126
+ collapsedHeight: 56,
127
+ children: /* @__PURE__ */ v("dl", {
128
+ className: "space-y-2",
129
+ children: [
130
+ /* @__PURE__ */ v("div", {
131
+ className: "flex justify-between",
132
+ children: [/* @__PURE__ */ _("dt", {
133
+ className: "text-sm text-text-secondary",
134
+ children: e(i, "files.info.status", "Status")
135
+ }), /* @__PURE__ */ _("dd", {
136
+ className: "text-sm font-medium text-text-primary",
137
+ children: t.status
138
+ })]
139
+ }),
140
+ !n && /* @__PURE__ */ v("div", {
141
+ className: "flex justify-between",
142
+ children: [/* @__PURE__ */ _("dt", {
143
+ className: "text-sm text-text-secondary",
144
+ children: e(i, "files.info.visibility", "Visibility")
145
+ }), /* @__PURE__ */ _("dd", {
146
+ className: "text-sm font-medium text-text-primary",
147
+ children: t.visibility
148
+ })]
149
+ }),
150
+ /* @__PURE__ */ v("div", {
151
+ className: "flex justify-between",
152
+ children: [/* @__PURE__ */ _("dt", {
153
+ className: "text-sm text-text-secondary",
154
+ children: e(i, "files.info.starred", "Starred")
155
+ }), /* @__PURE__ */ _("dd", {
156
+ className: "text-sm font-medium text-text-primary",
157
+ children: t.starred ? e(i, "files.info.yes", "Yes") : e(i, "files.info.no", "No")
158
+ })]
159
+ })
160
+ ]
161
+ })
162
+ })]
163
+ }), n && /* @__PURE__ */ _("div", {
164
+ className: "pt-6 border-t border-border-seam",
165
+ children: /* @__PURE__ */ v("button", {
166
+ type: "button",
167
+ onClick: r,
168
+ className: "w-full flex items-center justify-center gap-2 px-4 py-3 text-sm font-medium text-action-primary-text bg-action-primary-bg/10 hover:bg-action-primary-bg/20 rounded-lg transition-colors duration-200",
169
+ children: [/* @__PURE__ */ _(u, { className: "size-4" }), e(i, "files.info.viewVersionHistory", "View Version History")]
170
+ })
171
+ })] });
172
+ }
173
+ function O({ item: n, type: r, navigationV2: i }) {
174
+ let { t: a } = y(), o = r === "file", s = o ? n : null, c = o ? null : n, u = e(a, "files.info.unknown", "Unknown"), h = e(a, "files.info.folder", "Folder");
175
+ s && (h = i ? t(a, s.mimeType, s.extension) : s.mimeType || u);
176
+ let b = (e) => new Date(e).toLocaleString("en-US", {
177
+ year: "numeric",
178
+ month: "long",
179
+ day: "numeric",
180
+ hour: "2-digit",
181
+ minute: "2-digit"
182
+ });
183
+ return /* @__PURE__ */ v("div", {
184
+ className: "space-y-4",
185
+ children: [
186
+ /* @__PURE__ */ v("div", {
187
+ className: "flex items-start gap-3",
188
+ children: [/* @__PURE__ */ _(d, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
189
+ className: "text-sm font-medium text-text-primary",
190
+ children: e(a, "files.info.type", "Type")
191
+ }), /* @__PURE__ */ _("p", {
192
+ className: "text-sm text-text-secondary",
193
+ children: h
194
+ })] })]
195
+ }),
196
+ o && s && /* @__PURE__ */ v("div", {
197
+ className: "flex items-start gap-3",
198
+ children: [/* @__PURE__ */ _(f, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
199
+ className: "text-sm font-medium text-text-primary",
200
+ children: e(a, "files.info.size", "Size")
201
+ }), /* @__PURE__ */ _("p", {
202
+ className: "text-sm text-text-secondary",
203
+ children: ((e) => e < 1024 ? `${e} B` : e < 1048576 ? `${(e / 1024).toFixed(2)} KB` : e < 1073741824 ? `${(e / 1024 / 1024).toFixed(2)} MB` : `${(e / 1024 / 1024 / 1024).toFixed(2)} GB`)(s.size)
204
+ })] })]
205
+ }),
206
+ !o && c && /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ v("div", {
207
+ className: "flex items-start gap-3",
208
+ children: [/* @__PURE__ */ _(d, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
209
+ className: "text-sm font-medium text-text-primary",
210
+ children: e(a, "files.info.contents", "Contents")
211
+ }), /* @__PURE__ */ v("p", {
212
+ className: "text-sm text-text-secondary",
213
+ children: [
214
+ c.filesCount,
215
+ " ",
216
+ e(a, "files.info.files", "files"),
217
+ ",",
218
+ " ",
219
+ c.subfoldersCount,
220
+ " ",
221
+ e(a, "files.info.folders", "folders")
222
+ ]
223
+ })] })]
224
+ }), c.path && !i && /* @__PURE__ */ v("div", {
225
+ className: "flex items-start gap-3",
226
+ children: [/* @__PURE__ */ _(p, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
227
+ className: "text-sm font-medium text-text-primary",
228
+ children: e(a, "files.info.path", "Path")
229
+ }), /* @__PURE__ */ _("p", {
230
+ className: "text-sm text-text-secondary break-all",
231
+ children: c.path
232
+ })] })]
233
+ })] }),
234
+ /* @__PURE__ */ v("div", {
235
+ className: "flex items-start gap-3",
236
+ children: [/* @__PURE__ */ _(l, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
237
+ className: "text-sm font-medium text-text-primary",
238
+ children: e(a, "files.info.created", "Created")
239
+ }), /* @__PURE__ */ _("p", {
240
+ className: "text-sm text-text-secondary",
241
+ children: b(n.createdAt)
242
+ })] })]
243
+ }),
244
+ n.updatedAt && /* @__PURE__ */ v("div", {
245
+ className: "flex items-start gap-3",
246
+ children: [/* @__PURE__ */ _(l, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
247
+ className: "text-sm font-medium text-text-primary",
248
+ children: e(a, "files.info.modified", "Modified")
249
+ }), /* @__PURE__ */ _("p", {
250
+ className: "text-sm text-text-secondary",
251
+ children: b(n.updatedAt)
252
+ })] })]
253
+ }),
254
+ /* @__PURE__ */ v("div", {
255
+ className: "flex items-start gap-3",
256
+ children: [/* @__PURE__ */ _(m, { className: "size-5 text-text-muted mt-0.5" }), /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("p", {
257
+ className: "text-sm font-medium text-text-primary",
258
+ children: e(a, "files.info.owner", "Owner")
259
+ }), /* @__PURE__ */ _("p", {
260
+ className: "text-sm text-text-secondary",
261
+ children: n.createdBy?.name || n.createdById || e(a, "files.info.unknown", "Unknown")
262
+ })] })]
263
+ })
264
+ ]
265
+ });
266
+ }
267
+ export { T as FileInfoPanel };
227
268
 
228
269
  //# sourceMappingURL=FileInfoPanel.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileInfoPanel.js","names":["_Fragment","LinkIcon","FileVersionPanel","lazy","m","FileInfoPanel","useI18n","isFile","type","file","item","folder","showVersionHistory","setShowVersionHistory","useState","onEscape","useEffectEvent","onClose","handleEscape","event","formatDate","date","tWithFallback","t","X","GlassCard","FileText","FileVisibilityControl","HardDrive","bytes","Fragment","Link","Calendar","User","ShowMore","Clock","Suspense"],"sources":["../../../src/files/components/FileInfoPanel.tsx"],"sourcesContent":["import { useEffect, useEffectEvent, useState, lazy, Suspense } from \"react\";\nimport {\n X,\n FileText,\n Calendar,\n User,\n HardDrive,\n Link as LinkIcon,\n Clock,\n} from \"lucide-react\";\nimport { useI18n } from \"@burdenoff/fe-libs/shared/providers/shell/I18nProvider\";\nimport { GlassCard, ShowMore } from \"@burdenoff/fe-libs/ui\";\nimport type { FileItem, FolderItem } from \"../types\";\nimport { tWithFallback } from \"../utils/i18n\";\nimport { FileVisibilityControl } from \"./FileVisibilityControl\";\n\n// Lazy load FileVersionPanel to avoid loading heavy dependencies until needed\nconst FileVersionPanel = lazy(() =>\n import(\"./FileVersionPanel\").then((m) => ({ default: m.FileVersionPanel })),\n);\n\ninterface FileInfoPanelProps {\n item: FileItem | FolderItem;\n type: \"file\" | \"folder\";\n onClose: () => void;\n}\n\nexport function FileInfoPanel({ item, type, onClose }: FileInfoPanelProps) {\n const { t } = useI18n();\n const isFile = type === \"file\";\n const file = isFile ? (item as FileItem) : null;\n const folder = !isFile ? (item as FolderItem) : null;\n // TODO(BOFF-11841): in Navigation v2, move Path, Status, Visibility, the\n // Starred line, \"View Version History\" and the version panel under\n // <ShowTechnicalDetails>, and show a friendly file kind instead of the MIME\n // type on level 1. They stay where they are until fe-libs ships the piece.\n const [showVersionHistory, setShowVersionHistory] = useState(false);\n\n const onEscape = useEffectEvent(() => {\n if (showVersionHistory) {\n setShowVersionHistory(false);\n return;\n }\n onClose();\n });\n\n useEffect(() => {\n const handleEscape = (event: KeyboardEvent) => {\n if (event.key === \"Escape\") {\n onEscape();\n }\n };\n\n document.addEventListener(\"keydown\", handleEscape);\n return () => document.removeEventListener(\"keydown\", handleEscape);\n }, []);\n\n const formatDate = (date: string) => {\n return new Date(date).toLocaleString(\"en-US\", {\n year: \"numeric\",\n month: \"long\",\n day: \"numeric\",\n hour: \"2-digit\",\n minute: \"2-digit\",\n });\n };\n\n const formatSize = (bytes: number) => {\n if (bytes < 1024) return `${bytes} B`;\n if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(2)} KB`;\n if (bytes < 1024 * 1024 * 1024)\n return `${(bytes / 1024 / 1024).toFixed(2)} MB`;\n return `${(bytes / 1024 / 1024 / 1024).toFixed(2)} GB`;\n };\n\n return (\n <div\n className=\"fixed inset-y-0 right-0 z-[9999] w-full max-w-full overflow-y-auto border-l border-border-seam bg-bg-surface shadow-2xl animate-in slide-in-from-right duration-200 sm:w-96 [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]\"\n role=\"dialog\"\n aria-modal=\"false\"\n aria-label={\n isFile\n ? tWithFallback(t, \"files.info.fileInfo\", \"File information\")\n : tWithFallback(t, \"files.info.folderInfo\", \"Folder information\")\n }\n >\n {/* Header */}\n <div className=\"sticky top-0 z-10 bg-bg-surface border-b border-border-seam px-6 py-4 flex items-center justify-between\">\n <h2 className=\"text-lg font-semibold text-text-primary\">\n {isFile\n ? tWithFallback(t, \"files.info.fileInfo\", \"File Information\")\n : tWithFallback(t, \"files.info.folderInfo\", \"Folder Information\")}\n </h2>\n <button\n type=\"button\"\n onClick={onClose}\n className=\"p-1.5 rounded-md border border-border-default text-text-secondary bg-bg-elevated hover:bg-action-ghost-bg-hover hover:text-text-primary transition-colors shadow-sm\"\n aria-label={tWithFallback(\n t,\n \"files.info.closePanel\",\n \"Close information panel\",\n )}\n >\n <X className=\"size-5\" />\n </button>\n </div>\n\n {/* Content */}\n <div className=\"p-6 space-y-6\">\n {/* Preview/Icon */}\n <GlassCard\n treatment=\"metric\"\n className=\"flex items-center justify-center py-8\"\n >\n {isFile &&\n file?.mimeType.startsWith(\"image/\") &&\n (file.downloadUrl || file.url) ? (\n <img\n src={file.downloadUrl || file.url}\n alt={item.name}\n className=\"max-w-full max-h-48 object-contain rounded\"\n />\n ) : (\n <FileText className=\"size-20 text-text-muted\" />\n )}\n </GlassCard>\n\n {/* Name */}\n <div>\n <h3 className=\"text-xl font-semibold text-text-primary break-words\">\n {item.name}\n </h3>\n {item.description && (\n <p className=\"mt-2 text-sm text-text-secondary\">\n {item.description}\n </p>\n )}\n </div>\n\n {/* Details */}\n {file && (\n <FileVisibilityControl\n key={`${file.id}:${file.visibility}`}\n file={file}\n />\n )}\n <div className=\"space-y-4\">\n <div className=\"flex items-start gap-3\">\n <FileText className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.type\", \"Type\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {isFile\n ? file?.mimeType ||\n tWithFallback(t, \"files.info.unknown\", \"Unknown\")\n : tWithFallback(t, \"files.info.folder\", \"Folder\")}\n </p>\n </div>\n </div>\n\n {isFile && file && (\n <div className=\"flex items-start gap-3\">\n <HardDrive className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.size\", \"Size\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatSize(file.size)}\n </p>\n </div>\n </div>\n )}\n\n {!isFile && folder && (\n <>\n <div className=\"flex items-start gap-3\">\n <FileText className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.contents\", \"Contents\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {folder.filesCount}{\" \"}\n {tWithFallback(t, \"files.info.files\", \"files\")},{\" \"}\n {folder.subfoldersCount}{\" \"}\n {tWithFallback(t, \"files.info.folders\", \"folders\")}\n </p>\n </div>\n </div>\n\n {folder.path && (\n <div className=\"flex items-start gap-3\">\n <LinkIcon className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.path\", \"Path\")}\n </p>\n <p className=\"text-sm text-text-secondary break-all\">\n {folder.path}\n </p>\n </div>\n </div>\n )}\n </>\n )}\n\n <div className=\"flex items-start gap-3\">\n <Calendar className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.created\", \"Created\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatDate(item.createdAt)}\n </p>\n </div>\n </div>\n\n {item.updatedAt && (\n <div className=\"flex items-start gap-3\">\n <Calendar className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.modified\", \"Modified\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatDate(item.updatedAt)}\n </p>\n </div>\n </div>\n )}\n\n <div className=\"flex items-start gap-3\">\n <User className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.owner\", \"Owner\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {item.createdBy?.name ||\n item.createdById ||\n tWithFallback(t, \"files.info.unknown\", \"Unknown\")}\n </p>\n </div>\n </div>\n </div>\n\n {/* Additional Info — secondary properties tucked behind progressive\n disclosure to keep the rail focused on the essentials. */}\n <div className=\"pt-6 border-t border-border-seam\">\n <h4 className=\"text-sm font-semibold text-text-primary mb-3\">\n {tWithFallback(t, \"files.info.properties\", \"Properties\")}\n </h4>\n <ShowMore collapsedHeight={56}>\n <dl className=\"space-y-2\">\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.status\", \"Status\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.status}\n </dd>\n </div>\n {!isFile && (\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.visibility\", \"Visibility\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.visibility}\n </dd>\n </div>\n )}\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.starred\", \"Starred\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.starred\n ? tWithFallback(t, \"files.info.yes\", \"Yes\")\n : tWithFallback(t, \"files.info.no\", \"No\")}\n </dd>\n </div>\n </dl>\n </ShowMore>\n </div>\n\n {/* Version History Button (Files only) */}\n {isFile && file && (\n <div className=\"pt-6 border-t border-border-seam\">\n <button\n type=\"button\"\n onClick={() => setShowVersionHistory(true)}\n className=\"w-full flex items-center justify-center gap-2 px-4 py-3 text-sm font-medium text-action-primary-text bg-action-primary-bg/10 hover:bg-action-primary-bg/20 rounded-lg transition-all duration-200\"\n >\n <Clock className=\"size-4\" />\n {tWithFallback(\n t,\n \"files.info.viewVersionHistory\",\n \"View Version History\",\n )}\n </button>\n </div>\n )}\n </div>\n\n {/* Version History Modal */}\n {isFile && file && showVersionHistory && (\n <Suspense\n fallback={\n <div className=\"fixed inset-0 z-50 bg-bg-overlay flex items-center justify-center\">\n <div className=\"bg-bg-surface rounded-lg p-8 animate-in fade-in zoom-in duration-200\">\n <div className=\"flex items-center gap-3\">\n <Clock className=\"size-6 text-action-primary-bg animate-spin\" />\n <span className=\"text-text-primary\">\n {tWithFallback(\n t,\n \"files.info.loadingVersionHistory\",\n \"Loading version history...\",\n )}\n </span>\n </div>\n </div>\n </div>\n }\n >\n <FileVersionPanel\n file={file}\n onClose={() => setShowVersionHistory(false)}\n />\n </Suspense>\n )}\n </div>\n );\n}\n"],"mappings":";;;;;;;;AAiBA,IAAME,IAAmBC,QACvB,OAAO,wBAAqB,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,iBAAiB,EAAE,CAC5E;AAQA,SAAgBC,EAAc,EAAE,SAAM,SAAM,cAA+B;CACzE,IAAM,EAAE,SAAMC,EAAQ,GAChBC,IAASC,MAAS,QAClBC,IAAOF,IAAUG,IAAoB,MACrCC,IAAUJ,IAAgC,OAAtBG,GAKpB,CAACE,GAAoBC,KAAyBC,EAAS,EAAK,GAE5DC,IAAWC,QAAqB;EACpC,AAAIJ,IACFC,EAAsB,EAAK,IAG7BI,EAAQ;CACV,CAAC;CAED,QAAgB;EACd,IAAMC,KAAgB,MAAyB;GAC7C,AAAIC,EAAM,QAAQ,YAChBJ,EAAS;EAEb;EAGA,OADA,SAAS,iBAAiB,WAAWG,CAAY,SACpC,SAAS,oBAAoB,WAAWA,CAAY;CACnE,GAAG,CAAC,CAAC;CAEL,IAAME,KAAc,MACX,IAAI,KAAKC,CAAI,CAAC,CAAC,eAAe,SAAS;EAC5C,MAAM;EACN,OAAO;EACP,KAAK;EACL,MAAM;EACN,QAAQ;CACV,CAAC;CAWH,OACE,kBAAC,OAAD;EACE,WAAU;EACV,MAAK;EACL,cAAW;EACX,cACEd,IACIe,EAAcC,GAAG,uBAAuB,kBAAkB,IAC1DD,EAAcC,GAAG,yBAAyB,oBAAoB;EAPtE,UAAA;GAWE,kBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,kBAAC,MAAD;KAAI,WAAU;KACX,UAAAhB,IACGe,EAAcC,GAAG,uBAAuB,kBAAkB,IAC1DD,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;IAGP,UAAA,kBAACrB,GAAD;KACQ;KACN,eAAeW,EAAsB,EAAK;IAC3C,CAAA;GACO,CAAA;EAET;;AAET"}
1
+ {"version":3,"file":"FileInfoPanel.js","names":["_Fragment","LinkIcon","FileVersionPanel","lazy","m","FileInfoPanel","useI18n","isFile","type","file","item","showVersionHistory","setShowVersionHistory","useState","onEscape","useEffectEvent","onClose","useEffect","handleEscape","event","tWithFallback","t","X","GlassCard","FileText","FileVisibilityControl","InfoDetailRows","navigationV2","InfoTechnicalSection","InfoLegacyProperties","Suspense","Clock","ShowTechnicalDetails","buildInfoTechnicalDetails","Button","onShowVersionHistory","Fragment","ShowMore","folder","unknownLabel","fileTypeText","fileKindLabel","formatDate","date","HardDrive","bytes","Link","Calendar","User"],"sources":["../../../src/files/components/FileInfoPanel.tsx"],"sourcesContent":["import { useEffect, useEffectEvent, useState, lazy, Suspense } from \"react\";\nimport {\n X,\n FileText,\n Calendar,\n User,\n HardDrive,\n Link as LinkIcon,\n Clock,\n} from \"lucide-react\";\nimport { useI18n } from \"@burdenoff/fe-libs/shared/providers/shell/I18nProvider\";\nimport {\n Button,\n GlassCard,\n ShowMore,\n ShowTechnicalDetails,\n} from \"@burdenoff/fe-libs/ui\";\nimport type { FileItem, FolderItem } from \"../types\";\nimport { tWithFallback } from \"../utils/i18n\";\nimport { fileKindLabel } from \"../utils/fileKind\";\nimport { buildInfoTechnicalDetails } from \"../utils/infoTechnicalDetails\";\nimport { FileVisibilityControl } from \"./FileVisibilityControl\";\n\n// Lazy load FileVersionPanel to avoid loading heavy dependencies until needed\nconst FileVersionPanel = lazy(() =>\n import(\"./FileVersionPanel\").then((m) => ({ default: m.FileVersionPanel })),\n);\n\ninterface FileInfoPanelProps {\n item: FileItem | FolderItem;\n type: \"file\" | \"folder\";\n onClose: () => void;\n /**\n * Navigation v2 (BOFF-11865), FluidGrids only: a friendly file kind instead\n * of the MIME type, and Path, Status, Visibility, the Starred line and\n * version history moved under \"Show technical details\".\n */\n navigationV2?: boolean;\n}\n\nexport function FileInfoPanel({\n item,\n type,\n onClose,\n navigationV2 = false,\n}: FileInfoPanelProps) {\n const { t } = useI18n();\n const isFile = type === \"file\";\n const file = isFile ? (item as FileItem) : null;\n const [showVersionHistory, setShowVersionHistory] = useState(false);\n\n const onEscape = useEffectEvent(() => {\n if (showVersionHistory) {\n setShowVersionHistory(false);\n return;\n }\n onClose();\n });\n\n useEffect(() => {\n const handleEscape = (event: KeyboardEvent) => {\n if (event.key === \"Escape\") {\n onEscape();\n }\n };\n\n document.addEventListener(\"keydown\", handleEscape);\n return () => document.removeEventListener(\"keydown\", handleEscape);\n }, []);\n\n return (\n <div\n className=\"fixed inset-y-0 right-0 z-[9999] w-full max-w-full overflow-y-auto border-l border-border-seam bg-bg-surface shadow-2xl animate-in slide-in-from-right duration-200 sm:w-96 [&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]\"\n role=\"dialog\"\n aria-modal=\"false\"\n aria-label={\n isFile\n ? tWithFallback(t, \"files.info.fileInfo\", \"File information\")\n : tWithFallback(t, \"files.info.folderInfo\", \"Folder information\")\n }\n >\n {/* Header */}\n <div className=\"sticky top-0 z-10 bg-bg-surface border-b border-border-seam px-6 py-4 flex items-center justify-between\">\n <h2 className=\"text-lg font-semibold text-text-primary\">\n {isFile\n ? tWithFallback(t, \"files.info.fileInfo\", \"File Information\")\n : tWithFallback(t, \"files.info.folderInfo\", \"Folder Information\")}\n </h2>\n <button\n type=\"button\"\n onClick={onClose}\n className=\"p-1.5 rounded-md border border-border-default text-text-secondary bg-bg-elevated hover:bg-action-ghost-bg-hover hover:text-text-primary transition-colors shadow-sm\"\n aria-label={tWithFallback(\n t,\n \"files.info.closePanel\",\n \"Close information panel\",\n )}\n >\n <X className=\"size-5\" />\n </button>\n </div>\n\n {/* Content */}\n <div className=\"p-6 space-y-6\">\n {/* Preview/Icon */}\n <GlassCard\n treatment=\"metric\"\n className=\"flex items-center justify-center py-8\"\n >\n {isFile &&\n file?.mimeType.startsWith(\"image/\") &&\n (file.downloadUrl || file.url) ? (\n <img\n src={file.downloadUrl || file.url}\n alt={item.name}\n className=\"max-w-full max-h-48 object-contain rounded\"\n />\n ) : (\n <FileText className=\"size-20 text-text-muted\" />\n )}\n </GlassCard>\n\n {/* Name */}\n <div>\n <h3 className=\"text-xl font-semibold text-text-primary break-words\">\n {item.name}\n </h3>\n {item.description && (\n <p className=\"mt-2 text-sm text-text-secondary\">\n {item.description}\n </p>\n )}\n </div>\n\n {/* Details */}\n {file && (\n <FileVisibilityControl\n key={`${file.id}:${file.visibility}`}\n file={file}\n />\n )}\n <InfoDetailRows item={item} type={type} navigationV2={navigationV2} />\n\n {navigationV2 ? (\n <InfoTechnicalSection\n item={item}\n type={type}\n onShowVersionHistory={() => setShowVersionHistory(true)}\n />\n ) : (\n <InfoLegacyProperties\n item={item}\n isFile={isFile}\n onShowVersionHistory={() => setShowVersionHistory(true)}\n />\n )}\n </div>\n\n {/* Version History Modal */}\n {isFile && file && showVersionHistory && (\n <Suspense\n fallback={\n <div className=\"fixed inset-0 z-50 bg-bg-overlay flex items-center justify-center\">\n <div className=\"bg-bg-surface rounded-lg p-8 animate-in fade-in zoom-in duration-200\">\n <div className=\"flex items-center gap-3\">\n <Clock className=\"size-6 text-action-primary-bg animate-spin\" />\n <span className=\"text-text-primary\">\n {tWithFallback(\n t,\n \"files.info.loadingVersionHistory\",\n \"Loading version history...\",\n )}\n </span>\n </div>\n </div>\n </div>\n }\n >\n <FileVersionPanel\n file={file}\n onClose={() => setShowVersionHistory(false)}\n />\n </Suspense>\n )}\n </div>\n );\n}\n\n/**\n * Navigation v2: the raw properties under \"Show technical details\", with the\n * version history entry directly below. The shared piece holds text only, so\n * the entry to the version panel cannot sit inside it.\n */\nfunction InfoTechnicalSection({\n item,\n type,\n onShowVersionHistory,\n}: {\n item: FileItem | FolderItem;\n type: \"file\" | \"folder\";\n onShowVersionHistory: () => void;\n}) {\n const { t } = useI18n();\n return (\n <div className=\"pt-6 border-t border-border-seam space-y-2\">\n <ShowTechnicalDetails copyable>\n {buildInfoTechnicalDetails(t, item, type)}\n </ShowTechnicalDetails>\n {type === \"file\" && (\n <Button\n type=\"button\"\n variant=\"link\"\n size=\"sm\"\n onClick={onShowVersionHistory}\n className=\"min-h-11 px-1\"\n >\n <Clock className=\"size-4\" aria-hidden=\"true\" />\n {tWithFallback(\n t,\n \"files.info.viewVersionHistory\",\n \"View Version History\",\n )}\n </Button>\n )}\n </div>\n );\n}\n\n/** Every other app: the Properties block and the version history button. */\nfunction InfoLegacyProperties({\n item,\n isFile,\n onShowVersionHistory,\n}: {\n item: FileItem | FolderItem;\n isFile: boolean;\n onShowVersionHistory: () => void;\n}) {\n const { t } = useI18n();\n return (\n <>\n {/* Additional Info — secondary properties tucked behind progressive\n disclosure to keep the rail focused on the essentials. */}\n <div className=\"pt-6 border-t border-border-seam\">\n <h4 className=\"text-sm font-semibold text-text-primary mb-3\">\n {tWithFallback(t, \"files.info.properties\", \"Properties\")}\n </h4>\n <ShowMore collapsedHeight={56}>\n <dl className=\"space-y-2\">\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.status\", \"Status\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.status}\n </dd>\n </div>\n {!isFile && (\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.visibility\", \"Visibility\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.visibility}\n </dd>\n </div>\n )}\n <div className=\"flex justify-between\">\n <dt className=\"text-sm text-text-secondary\">\n {tWithFallback(t, \"files.info.starred\", \"Starred\")}\n </dt>\n <dd className=\"text-sm font-medium text-text-primary\">\n {item.starred\n ? tWithFallback(t, \"files.info.yes\", \"Yes\")\n : tWithFallback(t, \"files.info.no\", \"No\")}\n </dd>\n </div>\n </dl>\n </ShowMore>\n </div>\n\n {/* Version History Button (Files only) */}\n {isFile && (\n <div className=\"pt-6 border-t border-border-seam\">\n <button\n type=\"button\"\n onClick={onShowVersionHistory}\n className=\"w-full flex items-center justify-center gap-2 px-4 py-3 text-sm font-medium text-action-primary-text bg-action-primary-bg/10 hover:bg-action-primary-bg/20 rounded-lg transition-colors duration-200\"\n >\n <Clock className=\"size-4\" />\n {tWithFallback(\n t,\n \"files.info.viewVersionHistory\",\n \"View Version History\",\n )}\n </button>\n </div>\n )}\n </>\n );\n}\n\n/** Level 1: kind, size or contents, (path), created, modified and owner. */\nfunction InfoDetailRows({\n item,\n type,\n navigationV2,\n}: {\n item: FileItem | FolderItem;\n type: \"file\" | \"folder\";\n navigationV2: boolean;\n}) {\n const { t } = useI18n();\n const isFile = type === \"file\";\n const file = isFile ? (item as FileItem) : null;\n const folder = !isFile ? (item as FolderItem) : null;\n const unknownLabel = tWithFallback(t, \"files.info.unknown\", \"Unknown\");\n let fileTypeText = tWithFallback(t, \"files.info.folder\", \"Folder\");\n if (file) {\n fileTypeText = navigationV2\n ? fileKindLabel(t, file.mimeType, file.extension)\n : file.mimeType || unknownLabel;\n }\n\n const formatDate = (date: string) => {\n return new Date(date).toLocaleString(\"en-US\", {\n year: \"numeric\",\n month: \"long\",\n day: \"numeric\",\n hour: \"2-digit\",\n minute: \"2-digit\",\n });\n };\n\n const formatSize = (bytes: number) => {\n if (bytes < 1024) return `${bytes} B`;\n if (bytes < 1024 * 1024) return `${(bytes / 1024).toFixed(2)} KB`;\n if (bytes < 1024 * 1024 * 1024)\n return `${(bytes / 1024 / 1024).toFixed(2)} MB`;\n return `${(bytes / 1024 / 1024 / 1024).toFixed(2)} GB`;\n };\n\n return (\n <div className=\"space-y-4\">\n <div className=\"flex items-start gap-3\">\n <FileText className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.type\", \"Type\")}\n </p>\n <p className=\"text-sm text-text-secondary\">{fileTypeText}</p>\n </div>\n </div>\n\n {isFile && file && (\n <div className=\"flex items-start gap-3\">\n <HardDrive className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.size\", \"Size\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatSize(file.size)}\n </p>\n </div>\n </div>\n )}\n\n {!isFile && folder && (\n <>\n <div className=\"flex items-start gap-3\">\n <FileText className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.contents\", \"Contents\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {folder.filesCount}{\" \"}\n {tWithFallback(t, \"files.info.files\", \"files\")},{\" \"}\n {folder.subfoldersCount}{\" \"}\n {tWithFallback(t, \"files.info.folders\", \"folders\")}\n </p>\n </div>\n </div>\n\n {folder.path && !navigationV2 && (\n <div className=\"flex items-start gap-3\">\n <LinkIcon className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.path\", \"Path\")}\n </p>\n <p className=\"text-sm text-text-secondary break-all\">\n {folder.path}\n </p>\n </div>\n </div>\n )}\n </>\n )}\n\n <div className=\"flex items-start gap-3\">\n <Calendar className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.created\", \"Created\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatDate(item.createdAt)}\n </p>\n </div>\n </div>\n\n {item.updatedAt && (\n <div className=\"flex items-start gap-3\">\n <Calendar className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.modified\", \"Modified\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {formatDate(item.updatedAt)}\n </p>\n </div>\n </div>\n )}\n\n <div className=\"flex items-start gap-3\">\n <User className=\"size-5 text-text-muted mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium text-text-primary\">\n {tWithFallback(t, \"files.info.owner\", \"Owner\")}\n </p>\n <p className=\"text-sm text-text-secondary\">\n {item.createdBy?.name ||\n item.createdById ||\n tWithFallback(t, \"files.info.unknown\", \"Unknown\")}\n </p>\n </div>\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;AAwBA,IAAME,IAAmBC,QACvB,OAAO,wBAAqB,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,iBAAiB,EAAE,CAC5E;AAcA,SAAgBC,EAAc,EAC5B,SACA,SACA,YACA,kBAAe,MACM;CACrB,IAAM,EAAE,SAAMC,EAAQ,GAChBC,IAASC,MAAS,QAClBC,IAAOF,IAAUG,IAAoB,MACrC,CAACC,GAAoBC,KAAyBC,EAAS,EAAK,GAE5DC,IAAWC,QAAqB;EACpC,AAAIJ,IACFC,EAAsB,EAAK,IAG7BI,EAAQ;CACV,CAAC;CAaD,OAXAC,QAAgB;EACd,IAAMC,KAAgB,MAAyB;GAC7C,AAAIC,EAAM,QAAQ,YAChBL,EAAS;EAEb;EAGA,OADA,SAAS,iBAAiB,WAAWI,CAAY,SACpC,SAAS,oBAAoB,WAAWA,CAAY;CACnE,GAAG,CAAC,CAAC,GAGH,kBAAC,OAAD;EACE,WAAU;EACV,MAAK;EACL,cAAW;EACX,cACEX,IACIa,EAAcC,GAAG,uBAAuB,kBAAkB,IAC1DD,EAAcC,GAAG,yBAAyB,oBAAoB;EAPtE,UAAA;GAWE,kBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,kBAAC,MAAD;KAAI,WAAU;KACX,UAAAd,IACGa,EAAcC,GAAG,uBAAuB,kBAAkB,IAC1DD,EAAcC,GAAG,yBAAyB,oBAAoB;IAChE,CAAA,GACJ,kBAAC,UAAD;KACE,MAAK;KACL,SAASL;KACT,WAAU;KACV,cAAYI,EACVC,GACA,yBACA,yBACF;KAEA,UAAA,kBAACC,GAAD,EAAG,WAAU,SAAU,CAAA;IACjB,CAA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AAmB,MAAM;IAC1C,CAAA,GACH,kBAAC,KAAD;KAAG,WAAU;KACV,UAAAiB,EAAO;IACP,CAAA,CACA,EAAA,CAAA,CACF;GAEP,CAAA,CAAA,EAAA,CAAA;GAGJ,kBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,kBAACS,GAAD,EAAU,WAAU,gCAAiC,CAAA,GACrD,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,KAAD;KAAG,WAAU;KACV,UAAA3B,EAAcC,GAAG,sBAAsB,SAAS;IAChD,CAAA,GACH,kBAAC,KAAD;KAAG,WAAU;KACV,UAAAqB,EAAWhC,EAAK,SAAS;IACzB,CAAA,CACA,EAAA,CAAA,CACF;;GAEJA,EAAK,aACJ,kBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,kBAACqC,GAAD,EAAU,WAAU,gCAAiC,CAAA,GACrD,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,KAAD;KAAG,WAAU;KACV,UAAA3B,EAAcC,GAAG,uBAAuB,UAAU;IAClD,CAAA,GACH,kBAAC,KAAD;KAAG,WAAU;KACV,UAAAqB,EAAWhC,EAAK,SAAS;IACzB,CAAA,CACA,EAAA,CAAA,CACF;;GAGP,kBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,kBAACsC,GAAD,EAAM,WAAU,gCAAiC,CAAA,GACjD,kBAAC,OAAD,EAAA,UAAA,CACE,kBAAC,KAAD;KAAG,WAAU;KACV,UAAA5B,EAAcC,GAAG,oBAAoB,OAAO;IAC5C,CAAA,GACH,kBAAC,KAAD;KAAG,WAAU;KACV,UAAAX,EAAK,WAAW,QACfA,EAAK,eACLU,EAAcC,GAAG,sBAAsB,SAAS;IACjD,CAAA,CACA,EAAA,CAAA,CACF;;EACF;;AAET"}
@@ -7,6 +7,12 @@ interface SearchBarProps {
7
7
  placeholder?: string;
8
8
  initialQuery?: string;
9
9
  showFilters?: boolean;
10
+ /**
11
+ * Navigation v2 (BOFF-11865), FluidGrids only: File Type stays on the
12
+ * panel, Status and Visibility fold into a remembered "More filters", and
13
+ * "Starred only" is dropped (the Starred tab shows exactly that).
14
+ */
15
+ navigationV2?: boolean;
10
16
  }
11
- export declare function SearchBar({ onSearch, placeholder, initialQuery, showFilters, }: SearchBarProps): import('react').JSX.Element;
17
+ export declare function SearchBar({ onSearch, placeholder, initialQuery, showFilters, navigationV2, }: SearchBarProps): import('react').JSX.Element;
12
18
  export {};