@box/metadata-view 0.42.0 → 0.42.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 (78) hide show
  1. package/dist/chunks/{table-row.js → index.js} +1 -1
  2. package/dist/esm/index.js +52 -5
  3. package/dist/esm/lib/components/action-bar/action-bar.js +5 -6
  4. package/dist/esm/lib/components/error-state/error-state.js +6 -6
  5. package/dist/esm/lib/components/error-state/index.js +4 -0
  6. package/dist/esm/lib/components/filter-row/all-filters-chip.js +10 -10
  7. package/dist/esm/lib/components/filter-row/filter-row.js +19 -19
  8. package/dist/esm/lib/components/filter-row/form-filter-chip.js +2 -3
  9. package/dist/esm/lib/components/filter-row/index.js +8 -2
  10. package/dist/esm/lib/components/filter-sidepanel/{filter-sidepanel.js → filter-side-panel.js} +28 -28
  11. package/dist/esm/lib/components/filter-sidepanel/filter.js +5 -5
  12. package/dist/esm/lib/components/filter-sidepanel/index.js +6 -0
  13. package/dist/esm/lib/components/index.js +49 -0
  14. package/dist/esm/lib/components/metadata-grid/index.js +4 -1
  15. package/dist/esm/lib/components/metadata-grid/metadata-grid.js +15 -16
  16. package/dist/esm/lib/components/metadata-table/index.js +6 -2
  17. package/dist/esm/lib/components/metadata-table/metadata-table.js +19 -18
  18. package/dist/esm/lib/components/metadata-table/table-body/ghost-table-body.js +7 -7
  19. package/dist/esm/lib/components/metadata-table/table-body/{ghost-row/ghost-row.js → ghost-table-row/ghost-table-row.js} +5 -5
  20. package/dist/esm/lib/components/metadata-table/table-body/ghost-table-row/index.js +4 -0
  21. package/dist/esm/lib/components/metadata-table/table-body/inline-editing-cell/index.js +2 -2
  22. package/dist/esm/lib/components/metadata-table/table-body/inline-editing-cell/inline-editing-cell.js +1 -0
  23. package/dist/esm/lib/components/metadata-table/table-body/table-body-with-data.js +8 -8
  24. package/dist/esm/lib/components/metadata-table/table-body/table-row/index.js +4 -0
  25. package/dist/esm/lib/components/metadata-table/table-body/table-row/table-row.js +2 -2
  26. package/dist/esm/lib/components/metadata-table/table-renderer.js +14 -14
  27. package/dist/esm/lib/components/metadata-value/index.js +12 -0
  28. package/dist/esm/lib/components/pagination/index.js +8 -8
  29. package/dist/esm/lib/components/pagination/marker-based-pagination.js +1 -1
  30. package/dist/esm/lib/components/pagination/offset-based-pagination.js +1 -1
  31. package/dist/esm/lib/components/pagination/pagination-controls.js +1 -1
  32. package/dist/esm/lib/components/pagination/pagination.js +12 -12
  33. package/dist/esm/lib/components/switch-case/index.js +5 -0
  34. package/dist/esm/lib/index.js +54 -0
  35. package/dist/esm/lib/metadata-view.js +58 -40
  36. package/dist/types/index.d.ts +1 -2
  37. package/dist/types/lib/components/action-bar/action-bar.d.ts +1 -1
  38. package/dist/types/lib/components/action-bar/index.d.ts +2 -1
  39. package/dist/types/lib/components/error-state/error-state.d.ts +2 -3
  40. package/dist/types/lib/components/error-state/index.d.ts +1 -0
  41. package/dist/types/lib/components/filter-row/filter-row.d.ts +0 -1
  42. package/dist/types/lib/components/filter-row/form-filter-chip.d.ts +0 -1
  43. package/dist/types/lib/components/filter-row/index.d.ts +9 -1
  44. package/dist/types/lib/components/filter-sidepanel/filter-side-panel.d.ts +8 -0
  45. package/dist/types/lib/components/filter-sidepanel/filter.d.ts +2 -2
  46. package/dist/types/lib/components/filter-sidepanel/index.d.ts +3 -0
  47. package/dist/types/lib/components/index.d.ts +10 -0
  48. package/dist/types/lib/components/item-action-menu/index.d.ts +2 -1
  49. package/dist/types/lib/components/metadata-grid/index.d.ts +2 -0
  50. package/dist/types/lib/components/metadata-grid/metadata-grid.d.ts +0 -1
  51. package/dist/types/lib/components/metadata-table/index.d.ts +5 -2
  52. package/dist/types/lib/components/metadata-table/metadata-table.d.ts +2 -3
  53. package/dist/types/lib/components/metadata-table/table-body/ghost-table-body.d.ts +1 -2
  54. package/dist/types/lib/components/metadata-table/table-body/ghost-table-row/ghost-table-row.d.ts +5 -0
  55. package/dist/types/lib/components/metadata-table/table-body/ghost-table-row/index.d.ts +2 -0
  56. package/dist/types/lib/components/metadata-table/table-body/inline-editing-cell/index.d.ts +2 -1
  57. package/dist/types/lib/components/metadata-table/table-body/inline-editing-cell/inline-editing-cell.d.ts +1 -1
  58. package/dist/types/lib/components/metadata-table/table-body/table-body-with-data.d.ts +1 -1
  59. package/dist/types/lib/components/metadata-table/table-body/table-row/index.d.ts +2 -0
  60. package/dist/types/lib/components/metadata-table/table-body/table-row/table-row.d.ts +2 -3
  61. package/dist/types/lib/components/metadata-table/table-renderer.d.ts +2 -3
  62. package/dist/types/lib/components/metadata-value/index.d.ts +10 -0
  63. package/dist/types/lib/components/metadata-value/metadata-file-chip.d.ts +1 -2
  64. package/dist/types/lib/components/metadata-value/metadata-file-field.d.ts +1 -2
  65. package/dist/types/lib/components/metadata-value/metadata-location-field.d.ts +1 -1
  66. package/dist/types/lib/components/metadata-value/metadata-radio-field.d.ts +2 -3
  67. package/dist/types/lib/components/metadata-value/metadata-search-field.d.ts +1 -2
  68. package/dist/types/lib/components/pagination/index.d.ts +6 -6
  69. package/dist/types/lib/components/pagination/pagination-controls.d.ts +1 -2
  70. package/dist/types/lib/components/pagination/pagination.d.ts +1 -2
  71. package/dist/types/lib/components/sort-dropdown/index.d.ts +2 -1
  72. package/dist/types/lib/components/switch-case/index.d.ts +1 -0
  73. package/dist/types/lib/index.d.ts +3 -0
  74. package/dist/types/lib/metadata-view.d.ts +1 -3
  75. package/package.json +6 -6
  76. package/dist/types/lib/components/filter-sidepanel/filter-sidepanel.d.ts +0 -9
  77. package/dist/types/lib/components/metadata-table/table-body/ghost-row/ghost-row.d.ts +0 -6
  78. /package/dist/styles/{table-row.css → index.css} +0 -0
@@ -2,18 +2,19 @@ import { useRef as v } from "react";
2
2
  import { useIntl as M } from "react-intl";
3
3
  import { Text as E, ListCheckbox as S, TableHeader as k, Column as B } from "@box/blueprint-web";
4
4
  import { useInfiniteScrollTableItems as O } from "./hooks/useInfiniteScrollTableItems.js";
5
- import T from "./table-renderer.js";
5
+ import { TableRenderer as T } from "./table-renderer.js";
6
6
  import { I as P } from "../../../../chunks/types.js";
7
7
  import { THUMBNAIL_WIDTHS as U } from "../constants.js";
8
- import { s } from "../../../../chunks/table-row.js";
8
+ import { s } from "../../../../chunks/index.js";
9
9
  import j from "./messages.js";
10
10
  import { jsx as e } from "react/jsx-runtime";
11
- const F = 40, Q = ({
11
+ import "./table-body/inline-editing-cell/inline-editing-cell.js";
12
+ const F = 40, z = ({
12
13
  columns: o,
13
- isLoading: l = !1,
14
+ isLoading: i = !1,
14
15
  iconColumnVariant: n,
15
- isSelectAllEnabled: d,
16
- items: m,
16
+ isSelectAllEnabled: m,
17
+ items: d,
17
18
  itemActionMenuProps: I,
18
19
  isInfiniteScrollEnabled: R = !1,
19
20
  hasNextPage: x = !1,
@@ -30,9 +31,9 @@ const F = 40, Q = ({
30
31
  virtualItemsToDisplay: p,
31
32
  getTableHeight: y
32
33
  } = O({
33
- items: m,
34
+ items: d,
34
35
  hasNextPage: x,
35
- isLoading: l,
36
+ isLoading: i,
36
37
  parentRef: f,
37
38
  onGetNextPage: W,
38
39
  placeholderRowsCount: g
@@ -52,21 +53,21 @@ const F = 40, Q = ({
52
53
  const {
53
54
  id: H,
54
55
  headerRenderer: b,
55
- textValue: i,
56
+ textValue: l,
56
57
  ..._
57
58
  } = t;
58
59
  return {
59
- children: b ? b(i, t) : /* @__PURE__ */ e(E, {
60
+ children: b ? b(l, t) : /* @__PURE__ */ e(E, {
60
61
  as: "span",
61
- children: i
62
+ children: l
62
63
  }),
63
64
  isRowHeader: H === "name",
64
65
  id: H,
65
- textValue: i,
66
+ textValue: l,
66
67
  ..._
67
68
  };
68
69
  });
69
- a.push(...N), d && a.push({
70
+ a.push(...N), m && a.push({
70
71
  id: "actions",
71
72
  className: s.tableHeaderActions,
72
73
  children: /* @__PURE__ */ e("div", {
@@ -74,7 +75,7 @@ const F = 40, Q = ({
74
75
  children: /* @__PURE__ */ e(S, {
75
76
  "aria-label": c(j.selectAll),
76
77
  className: s.selectAllCheckbox,
77
- isDisabled: l
78
+ isDisabled: i
78
79
  })
79
80
  }),
80
81
  isRowHeader: !1,
@@ -91,10 +92,10 @@ const F = 40, Q = ({
91
92
  columns: o,
92
93
  formatMessage: c,
93
94
  iconColumnVariant: n,
94
- isLoading: l,
95
- isSelectAllEnabled: d,
95
+ isLoading: i,
96
+ isSelectAllEnabled: m,
96
97
  itemActionMenuProps: I,
97
- items: m,
98
+ items: d,
98
99
  onInlineEditChange: C,
99
100
  tableHeader: D,
100
101
  tableProps: w,
@@ -127,5 +128,5 @@ const F = 40, Q = ({
127
128
  });
128
129
  };
129
130
  export {
130
- Q as default
131
+ z as MetadataTable
131
132
  };
@@ -1,20 +1,20 @@
1
- import { TableBody as a } from "@box/blueprint-web";
2
- import l from "./ghost-row/ghost-row.js";
1
+ import { TableBody as l } from "@box/blueprint-web";
3
2
  import { jsx as r } from "react/jsx-runtime";
4
- const s = 20, n = ({
3
+ import { GhostTableRow as s } from "./ghost-table-row/ghost-table-row.js";
4
+ const y = 20, T = ({
5
5
  columnLength: e,
6
- rowLength: t = s
7
- }) => /* @__PURE__ */ r(a, {
6
+ rowLength: t = y
7
+ }) => /* @__PURE__ */ r(l, {
8
8
  items: Array.from({
9
9
  length: t
10
10
  }, (o, m) => ({
11
11
  key: m
12
12
  })),
13
- children: (o) => /* @__PURE__ */ r(l, {
13
+ children: (o) => /* @__PURE__ */ r(s, {
14
14
  columnLength: e,
15
15
  rowKey: o.key
16
16
  })
17
17
  });
18
18
  export {
19
- n as default
19
+ T as GhostTableBody
20
20
  };
@@ -1,20 +1,20 @@
1
1
  import { Row as h, Cell as i, Ghost as l } from "@box/blueprint-web";
2
- import { Size5 as a } from "@box/blueprint-web-assets/tokens/tokens";
2
+ import { Size5 as m } from "@box/blueprint-web-assets/tokens/tokens";
3
3
  import { jsx as r } from "react/jsx-runtime";
4
- const c = ({
4
+ const f = ({
5
5
  columnLength: o,
6
6
  rowKey: t = "ghost-row"
7
7
  }) => /* @__PURE__ */ r(h, {
8
8
  children: Array.from({
9
9
  length: o
10
- }, (m, e) => /* @__PURE__ */ r(i, {
10
+ }, (n, e) => /* @__PURE__ */ r(i, {
11
11
  children: /* @__PURE__ */ r(l, {
12
- height: a,
12
+ height: m,
13
13
  variant: "rectangle",
14
14
  width: "100%"
15
15
  })
16
16
  }, e))
17
17
  }, t);
18
18
  export {
19
- c as default
19
+ f as GhostTableRow
20
20
  };
@@ -0,0 +1,4 @@
1
+ import { GhostTableRow as r } from "./ghost-table-row.js";
2
+ export {
3
+ r as GhostTableRow
4
+ };
@@ -1,4 +1,4 @@
1
- import { default as o } from "./inline-editing-cell.js";
1
+ import { InlineEditingCell as l } from "./inline-editing-cell.js";
2
2
  export {
3
- o as default
3
+ l as InlineEditingCell
4
4
  };
@@ -51,5 +51,6 @@ import '../../../../../../styles/inline-editing-cell.css';const j = "_inlineEdit
51
51
  });
52
52
  };
53
53
  export {
54
+ R as InlineEditingCell,
54
55
  R as default
55
56
  };
@@ -5,11 +5,11 @@ import T from "lodash/get";
5
5
  import i from "react";
6
6
  import { I as h } from "../../../../../chunks/types.js";
7
7
  import { THUMBNAIL_LIST_VIEW_HEIGHTS as x } from "../../constants.js";
8
- import R from "./ghost-row/ghost-row.js";
9
- import { s as f, T as g } from "../../../../../chunks/table-row.js";
8
+ import { s as f, T as R } from "../../../../../chunks/index.js";
10
9
  import { jsx as r, jsxs as u } from "react/jsx-runtime";
11
- import w from "./inline-editing-cell/inline-editing-cell.js";
12
- import { ItemActionMenu as B } from "../../item-action-menu/item-action-menu.js";
10
+ import { InlineEditingCell as g } from "./inline-editing-cell/inline-editing-cell.js";
11
+ import { ItemActionMenu as w } from "../../item-action-menu/item-action-menu.js";
12
+ import { GhostTableRow as B } from "./ghost-table-row/ghost-table-row.js";
13
13
  const _ = /* @__PURE__ */ i.memo(({
14
14
  item: t,
15
15
  column: e,
@@ -86,7 +86,7 @@ const _ = /* @__PURE__ */ i.memo(({
86
86
  }) : d ? /* @__PURE__ */ r(k, {
87
87
  column: e,
88
88
  item: t
89
- }) : p && (c === "multiSelect" || c === "enum") ? /* @__PURE__ */ r(w, {
89
+ }) : p && (c === "multiSelect" || c === "enum") ? /* @__PURE__ */ r(g, {
90
90
  column: e,
91
91
  item: t,
92
92
  onInlineEditChange: n
@@ -112,7 +112,7 @@ const _ = /* @__PURE__ */ i.memo(({
112
112
  item: t,
113
113
  itemActionMenuProps: e
114
114
  }) => /* @__PURE__ */ r(S, {
115
- children: (l) => e ? /* @__PURE__ */ r(B, {
115
+ children: (l) => e ? /* @__PURE__ */ r(w, {
116
116
  ...e,
117
117
  item: t,
118
118
  onOpenChange: l
@@ -130,10 +130,10 @@ const _ = /* @__PURE__ */ i.memo(({
130
130
  }) => {
131
131
  const E = e === h.COLUMN;
132
132
  if (a) {
133
- const o = (s) => /* @__PURE__ */ r(R, {
133
+ const o = (s) => /* @__PURE__ */ r(B, {
134
134
  columnLength: p || 0,
135
135
  rowKey: `ghost-${s}`
136
- }), m = (s) => /* @__PURE__ */ r(g, {
136
+ }), m = (s) => /* @__PURE__ */ r(R, {
137
137
  columns: t,
138
138
  iconColumnVariant: e,
139
139
  isSelectAllEnabled: l,
@@ -0,0 +1,4 @@
1
+ import { T as e } from "../../../../../../chunks/index.js";
2
+ export {
3
+ e as TableRow
4
+ };
@@ -4,9 +4,9 @@ import "@box/item-icon";
4
4
  import "clsx";
5
5
  import "../../../../../../chunks/types.js";
6
6
  import "../../../constants.js";
7
- import { T as l } from "../../../../../../chunks/table-row.js";
7
+ import { T as f } from "../../../../../../chunks/index.js";
8
8
  import "react/jsx-runtime";
9
9
  import "../../../item-action-menu/item-action-menu.js";
10
10
  export {
11
- l as default
11
+ f as TableRow
12
12
  };
@@ -1,6 +1,6 @@
1
1
  import { Table as T } from "@box/blueprint-web";
2
2
  import { I as d } from "../../../../chunks/types.js";
3
- import x from "./table-body/ghost-table-body.js";
3
+ import { GhostTableBody as x } from "./table-body/ghost-table-body.js";
4
4
  import B from "./table-body/table-body-with-data.js";
5
5
  import j from "./messages.js";
6
6
  import { jsxs as y, jsx as i } from "react/jsx-runtime";
@@ -12,24 +12,24 @@ const O = ({
12
12
  itemActionMenuProps: c,
13
13
  items: f,
14
14
  isLoading: l,
15
- formatMessage: u,
16
- tableProps: a,
15
+ formatMessage: h,
16
+ tableProps: p,
17
17
  virtualItems: o,
18
- style: h,
19
- columnCount: p,
20
- zoomLevel: C,
21
- onInlineEditChange: g
18
+ style: u,
19
+ columnCount: C,
20
+ zoomLevel: g,
21
+ onInlineEditChange: a
22
22
  }) => {
23
- const m = p || (() => {
23
+ const m = C || (() => {
24
24
  let e = t.length;
25
25
  return n === d.COLUMN && (e += 1), r && (e += 1), e;
26
26
  })(), b = l && !(o != null && o.length);
27
27
  return /* @__PURE__ */ y(T, {
28
- "aria-label": u(j.listView),
28
+ "aria-label": h(j.listView),
29
29
  selectionBehavior: "toggle",
30
30
  selectionMode: "multiple",
31
- style: h,
32
- ...a,
31
+ style: u,
32
+ ...p,
33
33
  children: [s, b ? /* @__PURE__ */ i(x, {
34
34
  columnLength: m
35
35
  }) : /* @__PURE__ */ i(B, {
@@ -40,12 +40,12 @@ const O = ({
40
40
  isSelectAllEnabled: r,
41
41
  itemActionMenuProps: c,
42
42
  items: f,
43
- onInlineEditChange: g,
43
+ onInlineEditChange: a,
44
44
  virtualItems: o,
45
- zoomLevel: C
45
+ zoomLevel: g
46
46
  })]
47
47
  });
48
48
  };
49
49
  export {
50
- O as default
50
+ O as TableRenderer
51
51
  };
@@ -0,0 +1,12 @@
1
+ import { MetadataFileChip as t } from "./metadata-file-chip.js";
2
+ import { MetadataFileField as r } from "./metadata-file-field.js";
3
+ import { MetadataLocationField as i } from "./metadata-location-field.js";
4
+ import { MetadataRadioField as p } from "./metadata-radio-field.js";
5
+ import { MetadataSearchField as f } from "./metadata-search-field.js";
6
+ export {
7
+ t as MetadataFileChip,
8
+ r as MetadataFileField,
9
+ i as MetadataLocationField,
10
+ p as MetadataRadioField,
11
+ f as MetadataSearchField
12
+ };
@@ -1,10 +1,10 @@
1
- import { default as t } from "./pagination.js";
2
- import { default as e } from "./pagination-controls.js";
3
- import { OffsetBasedPagination as f } from "./offset-based-pagination.js";
4
- import { MarkerBasedPagination as s } from "./marker-based-pagination.js";
1
+ import { Pagination as r } from "./pagination.js";
2
+ import { MarkerBasedPagination as n } from "./marker-based-pagination.js";
3
+ import { OffsetBasedPagination as i } from "./offset-based-pagination.js";
4
+ import { PaginationControls as g } from "./pagination-controls.js";
5
5
  export {
6
- s as MarkerBasedPagination,
7
- f as OffsetBasedPagination,
8
- t as Pagination,
9
- e as PaginationControls
6
+ n as MarkerBasedPagination,
7
+ i as OffsetBasedPagination,
8
+ r as Pagination,
9
+ g as PaginationControls
10
10
  };
@@ -1,4 +1,4 @@
1
- import i from "./pagination-controls.js";
1
+ import { PaginationControls as i } from "./pagination-controls.js";
2
2
  import { jsx as a } from "react/jsx-runtime";
3
3
  const c = ({
4
4
  hasNextMarker: t,
@@ -1,4 +1,4 @@
1
- import h from "./pagination-controls.js";
1
+ import { PaginationControls as h } from "./pagination-controls.js";
2
2
  import { getOffsetForPage as c } from "./utils.js";
3
3
  import { jsx as P } from "react/jsx-runtime";
4
4
  const x = ({
@@ -49,5 +49,5 @@ import '../../../../styles/pagination-controls.css';const h = "_pagination_1ozaq
49
49
  });
50
50
  };
51
51
  export {
52
- E as default
52
+ E as PaginationControls
53
53
  };
@@ -1,36 +1,36 @@
1
1
  import { MarkerBasedPagination as g } from "./marker-based-pagination.js";
2
2
  import { OffsetBasedPagination as p } from "./offset-based-pagination.js";
3
- import { jsx as r } from "react/jsx-runtime";
3
+ import { jsx as a } from "react/jsx-runtime";
4
4
  import "./pagination-controls.js";
5
- const u = ({
5
+ const c = ({
6
6
  type: e,
7
- ...a
7
+ ...r
8
8
  }) => {
9
9
  if (e === "marker") {
10
10
  const {
11
11
  hasNextMarker: s,
12
12
  hasPrevMarker: f,
13
13
  onMarkerBasedPageChange: m
14
- } = a;
15
- return /* @__PURE__ */ r(g, {
14
+ } = r;
15
+ return /* @__PURE__ */ a(g, {
16
16
  hasNextMarker: s,
17
17
  hasPrevMarker: f,
18
18
  onMarkerBasedPageChange: m
19
19
  });
20
20
  }
21
21
  const {
22
- offset: t,
23
- onOffsetChange: o,
22
+ offset: o,
23
+ onOffsetChange: t,
24
24
  pageSize: n,
25
25
  totalCount: i
26
- } = a;
27
- return /* @__PURE__ */ r(p, {
28
- offset: t,
29
- onOffsetChange: o,
26
+ } = r;
27
+ return /* @__PURE__ */ a(p, {
28
+ offset: o,
29
+ onOffsetChange: t,
30
30
  pageSize: n,
31
31
  totalCount: i
32
32
  });
33
33
  };
34
34
  export {
35
- u as default
35
+ c as Pagination
36
36
  };
@@ -0,0 +1,5 @@
1
+ import { Case as o, SwitchCase as r } from "./switch-case.js";
2
+ export {
3
+ o as Case,
4
+ r as SwitchCase
5
+ };
@@ -0,0 +1,54 @@
1
+ import { MetadataView as r } from "./metadata-view.js";
2
+ import { I as a, V as i } from "../../chunks/types.js";
3
+ import { ActionBar as m } from "./components/action-bar/action-bar.js";
4
+ import { FilterRow as x } from "./components/filter-row/filter-row.js";
5
+ import { F as n } from "../../chunks/form-filter-chip.js";
6
+ import { MetadataFilterChip as F } from "./components/filter-row/metadata-filter-chip.js";
7
+ import { SelectFilterChip as s } from "./components/filter-row/select-filter-chip.js";
8
+ import { Filter as c } from "./components/filter-sidepanel/filter.js";
9
+ import { FilterSidePanel as g } from "./components/filter-sidepanel/filter-side-panel.js";
10
+ import { ItemActionMenu as P } from "./components/item-action-menu/item-action-menu.js";
11
+ import { MetadataGrid as I } from "./components/metadata-grid/metadata-grid.js";
12
+ import { MetadataTable as B } from "./components/metadata-table/metadata-table.js";
13
+ import { InlineEditingCell as b } from "./components/metadata-table/table-body/inline-editing-cell/inline-editing-cell.js";
14
+ import { TableRenderer as A } from "./components/metadata-table/table-renderer.js";
15
+ import { MetadataFileChip as k } from "./components/metadata-value/metadata-file-chip.js";
16
+ import { MetadataFileField as E } from "./components/metadata-value/metadata-file-field.js";
17
+ import { MetadataLocationField as L } from "./components/metadata-value/metadata-location-field.js";
18
+ import { MetadataRadioField as j } from "./components/metadata-value/metadata-radio-field.js";
19
+ import { MetadataSearchField as v } from "./components/metadata-value/metadata-search-field.js";
20
+ import { Pagination as z } from "./components/pagination/pagination.js";
21
+ import { MarkerBasedPagination as J } from "./components/pagination/marker-based-pagination.js";
22
+ import { OffsetBasedPagination as N } from "./components/pagination/offset-based-pagination.js";
23
+ import { PaginationControls as U } from "./components/pagination/pagination-controls.js";
24
+ import { SortDropdown as X } from "./components/sort-dropdown/sort-dropdown.js";
25
+ import { Case as Z, SwitchCase as _ } from "./components/switch-case/switch-case.js";
26
+ export {
27
+ m as ActionBar,
28
+ Z as Case,
29
+ c as Filter,
30
+ x as FilterRow,
31
+ g as FilterSidePanel,
32
+ n as FormFilterChip,
33
+ a as IconColumnVariant,
34
+ b as InlineEditingCell,
35
+ P as ItemActionMenu,
36
+ J as MarkerBasedPagination,
37
+ k as MetadataFileChip,
38
+ E as MetadataFileField,
39
+ F as MetadataFilterChip,
40
+ I as MetadataGrid,
41
+ L as MetadataLocationField,
42
+ j as MetadataRadioField,
43
+ v as MetadataSearchField,
44
+ B as MetadataTable,
45
+ r as MetadataView,
46
+ N as OffsetBasedPagination,
47
+ z as Pagination,
48
+ U as PaginationControls,
49
+ s as SelectFilterChip,
50
+ X as SortDropdown,
51
+ _ as SwitchCase,
52
+ A as TableRenderer,
53
+ i as ViewMode
54
+ };
@@ -1,79 +1,97 @@
1
- import { TooltipProvider as T } from "@box/blueprint-web";
1
+ import { I as T, V as o } from "../../chunks/types.js";
2
+ import { ActionBar as _ } from "./components/action-bar/action-bar.js";
3
+ import "./components/filter-row/filter-row.js";
4
+ import "../../chunks/form-filter-chip.js";
5
+ import "./components/filter-row/metadata-filter-chip.js";
6
+ import "./components/filter-row/select-filter-chip.js";
7
+ import "./components/filter-sidepanel/filter.js";
8
+ import "./components/filter-sidepanel/filter-side-panel.js";
9
+ import "./components/item-action-menu/item-action-menu.js";
10
+ import { MetadataGrid as x } from "./components/metadata-grid/metadata-grid.js";
11
+ import { MetadataTable as E } from "./components/metadata-table/metadata-table.js";
12
+ import "./components/metadata-table/table-body/inline-editing-cell/inline-editing-cell.js";
13
+ import "./components/metadata-table/table-renderer.js";
14
+ import "./components/metadata-value/metadata-file-chip.js";
15
+ import "./components/metadata-value/metadata-file-field.js";
16
+ import "./components/metadata-value/metadata-location-field.js";
17
+ import "./components/metadata-value/metadata-radio-field.js";
18
+ import "./components/metadata-value/metadata-search-field.js";
19
+ import { Pagination as N } from "./components/pagination/pagination.js";
20
+ import "./components/pagination/marker-based-pagination.js";
21
+ import "./components/pagination/offset-based-pagination.js";
22
+ import "./components/pagination/pagination-controls.js";
23
+ import "./components/sort-dropdown/sort-dropdown.js";
24
+ import { SwitchCase as b, Case as a } from "./components/switch-case/switch-case.js";
25
+ import { TooltipProvider as g } from "@box/blueprint-web";
2
26
  import { useState as f } from "react";
3
- import _ from "./components/error-state/error-state.js";
4
- import x from "./components/pagination/pagination.js";
5
- import { MetadataGrid as E } from "./components/metadata-grid/metadata-grid.js";
6
- import { SwitchCase as N, Case as m } from "./components/switch-case/switch-case.js";
7
- import { I as b, V as o } from "../../chunks/types.js";
8
- import { jsx as t, jsxs as h, Fragment as g } from "react/jsx-runtime";
9
- import { ActionBar as k } from "./components/action-bar/action-bar.js";
10
- import D from "./components/empty-state/empty-state.js";
11
- import G from "./components/metadata-table/metadata-table.js";
27
+ import { jsx as t, jsxs as h, Fragment as k } from "react/jsx-runtime";
28
+ import { ErrorState as D } from "./components/error-state/error-state.js";
29
+ import G from "./components/empty-state/empty-state.js";
12
30
  import '../../styles/metadata-view.css';const j = "_container_nykl3_5", R = "_contentContainer_nykl3_14", M = {
13
31
  container: j,
14
32
  contentContainer: R
15
33
  };
16
- function W({
17
- actionBarProps: i,
34
+ function st({
35
+ actionBarProps: n,
18
36
  columns: c,
19
- tableProps: l,
37
+ tableProps: p,
20
38
  hasError: u,
21
39
  onRefresh: I,
22
40
  initialViewMode: S = o.LIST,
23
- paginationProps: d,
24
- isLoading: s,
41
+ paginationProps: l,
42
+ isLoading: d,
25
43
  ...r
26
44
  }) {
27
- const [e, p] = f(S), [a, V] = f(0), w = () => {
28
- e === o.LIST ? p(o.GRID) : p(o.LIST);
29
- }, v = !s && r.items.length === 0, y = i && i.sortDropdownProps && c.filter((n) => n.type !== "multiSelect" && n.type !== "enum").map((n) => n.textValue), {
45
+ const [e, s] = f(S), [m, V] = f(0), w = () => {
46
+ e === o.LIST ? s(o.GRID) : s(o.LIST);
47
+ }, v = !d && r.items.length === 0, y = n && n.sortDropdownProps && c.filter((i) => i.type !== "multiSelect" && i.type !== "enum").map((i) => i.textValue), {
30
48
  iconColumnVariant: C
31
- } = l || {}, L = C && C === b.COLUMN;
32
- return /* @__PURE__ */ t(T, {
49
+ } = p || {}, L = C && C === T.COLUMN;
50
+ return /* @__PURE__ */ t(g, {
33
51
  children: /* @__PURE__ */ t("div", {
34
52
  className: M.container,
35
- children: u ? /* @__PURE__ */ t(_, {
53
+ children: u ? /* @__PURE__ */ t(D, {
36
54
  onRefresh: I
37
- }) : /* @__PURE__ */ h(g, {
38
- children: [/* @__PURE__ */ t(k, {
39
- ...i,
55
+ }) : /* @__PURE__ */ h(k, {
56
+ children: [/* @__PURE__ */ t(_, {
57
+ ...n,
40
58
  isIconColumnEnabled: L,
41
59
  onViewModeClick: w,
42
60
  onZoomLevelChange: V,
43
61
  sortableColumnNames: y,
44
62
  viewMode: e,
45
- zoomLevel: a
63
+ zoomLevel: m
46
64
  }), /* @__PURE__ */ t("div", {
47
65
  className: M.contentContainer,
48
- children: /* @__PURE__ */ h(N, {
49
- children: [/* @__PURE__ */ t(m, {
66
+ children: /* @__PURE__ */ h(b, {
67
+ children: [/* @__PURE__ */ t(a, {
50
68
  condition: v,
51
- children: /* @__PURE__ */ t(D, {})
52
- }), /* @__PURE__ */ t(m, {
69
+ children: /* @__PURE__ */ t(G, {})
70
+ }), /* @__PURE__ */ t(a, {
53
71
  condition: e === o.LIST,
54
- children: /* @__PURE__ */ t(G, {
72
+ children: /* @__PURE__ */ t(E, {
55
73
  columns: c,
56
- isLoading: s,
57
- zoomLevel: a,
74
+ isLoading: d,
75
+ zoomLevel: m,
58
76
  ...r,
59
- ...l
77
+ ...p
60
78
  })
61
- }), /* @__PURE__ */ t(m, {
79
+ }), /* @__PURE__ */ t(a, {
62
80
  condition: e === o.GRID,
63
- children: /* @__PURE__ */ t(E, {
64
- zoomLevel: a,
81
+ children: /* @__PURE__ */ t(x, {
82
+ zoomLevel: m,
65
83
  ...r
66
84
  })
67
85
  })]
68
86
  })
69
- }), d && /* @__PURE__ */ t(x, {
70
- ...d
87
+ }), l && /* @__PURE__ */ t(N, {
88
+ ...l
71
89
  })]
72
90
  })
73
91
  })
74
92
  });
75
93
  }
76
94
  export {
77
- W as MetadataView,
78
- W as default
95
+ st as MetadataView,
96
+ st as default
79
97
  };
@@ -1,2 +1 @@
1
- export * from './lib/metadata-view';
2
- export * from './lib/types';
1
+ export * from './lib';
@@ -16,4 +16,4 @@ interface ActionBarInternalProps extends ActionBarProps {
16
16
  sortableColumnNames: string[];
17
17
  }
18
18
  export declare const ActionBar: ({ isIconColumnEnabled, isViewModeButtonDisabled, onViewModeClick, onZoomLevelChange, sortableColumnNames, sortDropdownProps, viewMode, zoomLevel, ...rest }: ActionBarInternalProps) => import("react/jsx-runtime").JSX.Element;
19
- export default ActionBar;
19
+ export {};
@@ -1 +1,2 @@
1
- export * from './action-bar';
1
+ export { ActionBar } from './action-bar';
2
+ export type { ActionBarProps } from './action-bar';
@@ -1,5 +1,4 @@
1
- interface ErrorStateProps {
1
+ export interface ErrorStateProps {
2
2
  onRefresh?: () => void;
3
3
  }
4
- declare const ErrorState: ({ onRefresh }: ErrorStateProps) => import("react/jsx-runtime").JSX.Element;
5
- export default ErrorState;
4
+ export declare const ErrorState: ({ onRefresh }: ErrorStateProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export { ErrorState } from './error-state';
@@ -8,4 +8,3 @@ export interface FilterRowProps {
8
8
  onFilterSubmit?: (fields: FilterValues) => void;
9
9
  }
10
10
  export declare const FilterRow: ({ predefinedFilterOptions, filterGroups: customFilterGroups, initialFilterValues: customFilterValues, isAllFiltersDisabled, onFilterSubmit, }: FilterRowProps) => import("react/jsx-runtime").JSX.Element;
11
- export default FilterRow;
@@ -6,4 +6,3 @@ export interface FormFilterChipProps {
6
6
  name: string;
7
7
  }
8
8
  export declare const FormFilterChip: ({ children, formRef, icon, id, name }: FormFilterChipProps) => import("react/jsx-runtime").JSX.Element;
9
- export default FormFilterChip;