@vidispine/vdt-materialui 23.2.0 → 23.3.0-pre.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.
- package/dist/cjs/search/SavedSearch/SavedSearch.js +1 -1
- package/dist/cjs/search/SavedSearch/SavedSearchList.js +1 -1
- package/dist/cjs/search/SavedSearchFolder/FolderRow.js +1 -1
- package/dist/es/search/SavedSearch/SavedSearch.js +32 -30
- package/dist/es/search/SavedSearch/SavedSearchList.js +16 -14
- package/dist/es/search/SavedSearchFolder/FolderRow.js +85 -81
- package/package.json +12 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("react/jsx-runtime"),b=require("clsx"),m=require("@material-ui/core"),w=require("@vidispine/vdt-react"),D=require("./SavedSearchList.js"),R=require("./SaveSearchForm.js"),V=e=>({root:{padding:e.spacing(2)}});function _({classes:e,className:c,markerField:o,markerValue:n,itemSearchDocument:S,onSelect:d,onSaveSuccess:i=()=>{},onSaveError:u=()=>{},SearchListComponent:a=D.default,SearchListProps:l={},SearchFormComponent:r=R.default,SearchFormProps:h={},accessTranslate:v,extraMenuItems:f,isLoading:g=!1}){const{onDeleteSearch:q,onUpdateSearchMetadata:j,onGetSavedSearchSettings:x,onSaveSearch:P,searchProps:p}=w.useSavedSearch({markerField:o,markerValue:n,initialSearchState:{rowsPerPage:5}}),y=({collectionId:s})=>x({collectionId:s}).then(M=>d(M,s));return t.jsxs("div",{className:b(e.root,"VdtSavedSearch-root",c),children:[r&&t.jsx(r,{itemSearchDocument:S,onSuccess:i,onError:u,onSaveSearch:P,...h}),a&&t.jsx(a,{onSelect:y,onDelete:q,onUpdateSearchMetadata:j,searchProps:p,accessTranslate:v,extraMenuItems:f,isLoading:g,...l})]})}const E=m.withStyles(V,{name:"VdtSavedSearchList"})(_);exports.default=E;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("react/jsx-runtime"),s=require("@material-ui/core"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("react/jsx-runtime"),s=require("@material-ui/core"),j=require("../../collection/CollectionSearchPicker/index.js"),x=require("./SavedSearchRow.js"),f={};function g({searchProps:o,searchPlaceholderText:i="Find searches",onSelect:n,onDelete:d,onUpdateSearchMetadata:c,RowComponent:l=x.default,RowProps:u={},accessTranslate:S,extraMenuItems:h,isLoading:v,...P}){return r.jsx(j.default,{searchProps:o,searchPlaceholder:i,CollectionTableComponent:({collectionListType:t,onRefresh:a})=>r.jsx(s.List,{children:t&&t.collection&&t.collection.map(e=>r.jsx(l,{collectionType:e,onSelect:()=>n({collectionId:e.id}),onDelete:()=>Promise.resolve(d({collectionId:e.id}).then(a)),onUpdateSearchMetadata:m=>Promise.resolve(c({collectionId:e.id,metadataDocument:m}).then(a)),accessTranslate:S,extraMenuItems:h,isLoading:v,...u},e.id))}),PaginationProps:{rowsPerPageOptions:[5,10]},...P})}const q=s.withStyles(f,{name:"VdtSavedSearchList"})(g);exports.default=q;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const n=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const n=require("react/jsx-runtime"),b=require("react"),Y=require("clsx"),$=require("@material-ui/core"),Z=require("@vidispine/vdt-js"),g=require("@vidispine/vdt-react"),P=require("../SavedSearch/SavedSearchRow.js"),C=require("./AddFolderRow.js"),U={markerValue:"savedSearch",markerField:"eidr_referentType"},ee={indentationWidth:20,indentationDepthStart:1,defaultRowIndentationOffset:15,defalutNewRowIndentation:10},te=()=>({root:{display:"flex",width:"100%",flexWrap:"wrap"},indentationContainer:{display:"flex",width:"100%"}}),ne=a=>({root:{display:"flex",width:"100%"},indentation:{height:25,borderLeft:`1px solid ${a.palette.primary.main}`,borderBottom:`1px solid ${a.palette.primary.main}`,marginRight:5}});function ae({className:a,classes:t,children:c,indentationWidth:u,hideWrapper:x,folderDepth:o,indentationDepthStart:h,isAddRow:d,rowIndentation:l,addNewRowIndentation:I}){const w=d?!0:o>=h,i=d?I:l;return x?null:n.jsxs("div",{className:Y(a,t.root),children:[w&&n.jsx("div",{className:t.indentation,style:{marginLeft:i,minWidth:u}}),c]})}const de=g.compose($.withStyles(ne,{name:"VdtFolderRowContentWrapper"}))(ae);function k({classes:a,id:t,queryParams:c,markerProps:u=U,childFolders:x=[],metadata:o={},itemSearchDocument:h={},folderDepth:d=0,type:l="folder",hideSubFolderSharing:I,onSelect:w,onRemoveItem:i,indentationValues:q={},indentationProps:s=ee,FolderRowContentComponent:y=P.default,FolderRowContentProps:v={},AddRowComponent:F=C.default,AddRowProps:M={},FolderRowContentWrapperComponent:S=de,FolderRowContentWrapperProps:f={},isLoading:R,...z}){const[j,_]=b.useState(),[V,N]=b.useState({id:null,type:null}),{createFolder:A,saveSearch:D,deleteFolder:E,removeItem:G,subFolders:m=[]}=g.useGetSavedSearchFolders({childFolders:x,expand:j,queryParams:c,markerProps:u}),{onDeleteSearch:B,onUpdateSearchMetadata:p,onGetSavedSearchSettings:J}=g.useSavedSearch({...U}),T=({collectionId:e})=>J({collectionId:e}).then(X=>w(X,e)),O=Z.parseMetadataType(o,{joinValue:"_",flat:!0}),W=b.useMemo(()=>{const{__child_collection_size:e=0}=O;return m.length>0||!j&&e>0},[m.length,j,O]),{defalutNewRowIndentation:H,defaultRowIndentationOffset:K,indentationWidth:L}=s,r={rowIndentation:q.rowIndentation||0,addNewRowIndentation:q.addNewRowIndentation||H},Q={rowIndentation:r.addNewRowIndentation,addNewRowIndentation:r.addNewRowIndentation+L+K};return n.jsxs("div",{className:a.root,children:[{folder:n.jsx(S,{folderDepth:d,...r,...s,...f,children:n.jsx(y,{isFolderRow:!0,hideSubFolderSharing:I,type:l,collectionType:{id:t,metadata:o},disableDeletion:W,onDelete:()=>Promise.resolve(E(t)).then(()=>{i&&i(t)}),onUpdateSearchMetadata:e=>p({collectionId:t,metadataDocument:e}),onExpand:()=>_(e=>!e),onAddRow:N,isLoading:R,...v})}),query:n.jsx(S,{folderDepth:d,...r,...s,...f,children:n.jsx(y,{isFolderRow:!0,type:l,collectionType:{id:t,metadata:o},onSelect:()=>T({collectionId:t}),onDelete:()=>Promise.resolve(B({collectionId:t})).then(()=>{i&&i(t)}),onUpdateSearchMetadata:e=>p({collectionId:t,metadataDocument:e}),onAddRow:N,isLoading:R,...v})})}[l],n.jsx(S,{isAddRow:!0,folderDepth:d,...r,...s,hideWrapper:!V.id,...f,children:n.jsx(F,{id:t,setExpand:_,saveSearch:D,onAddRow:N,createFolder:A,itemSearchDocument:h,newField:V,...M})}),m.map(e=>n.jsx(k,{classes:a,id:e.id,queryParams:c,markerProps:u,childFolders:e.subFolders,metadata:e.metadata,itemSearchDocument:h,folderDepth:d+1,type:e.type,hideSubFolderSharing:!0,handleSelect:T,onSelect:w,onRemoveItem:()=>G(e.id),indentationProps:s,FolderRowContentComponent:y,FolderRowContentProps:v,AddRowComponent:F,AddRowProps:M,FolderRowContentWrapperComponent:S,FolderRowContentWrapperProps:f,indentationValues:Q,isLoading:R,props:z},e.id))]})}const ie=$.withStyles(te,{name:"VdtFolderRow"})(k);exports.default=ie;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { withStyles as
|
|
4
|
-
import { useSavedSearch as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
const
|
|
1
|
+
import { jsxs as D, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import V from "clsx";
|
|
3
|
+
import { withStyles as E } from "@material-ui/core";
|
|
4
|
+
import { useSavedSearch as G } from "@vidispine/vdt-react";
|
|
5
|
+
import L from "./SavedSearchList.js";
|
|
6
|
+
import M from "./SaveSearchForm.js";
|
|
7
|
+
const N = (e) => ({
|
|
8
8
|
root: {
|
|
9
9
|
padding: e.spacing(2)
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
function
|
|
12
|
+
function U({
|
|
13
13
|
classes: e,
|
|
14
14
|
className: S,
|
|
15
15
|
markerField: s,
|
|
@@ -20,46 +20,48 @@ function N({
|
|
|
20
20
|
},
|
|
21
21
|
onSaveError: h = () => {
|
|
22
22
|
},
|
|
23
|
-
SearchListComponent:
|
|
23
|
+
SearchListComponent: a = L,
|
|
24
24
|
SearchListProps: m = {},
|
|
25
|
-
SearchFormComponent:
|
|
25
|
+
SearchFormComponent: r = M,
|
|
26
26
|
SearchFormProps: l = {},
|
|
27
27
|
accessTranslate: v,
|
|
28
|
-
extraMenuItems:
|
|
28
|
+
extraMenuItems: f,
|
|
29
|
+
isLoading: p = !1
|
|
29
30
|
}) {
|
|
30
31
|
const {
|
|
31
|
-
onDeleteSearch:
|
|
32
|
-
onUpdateSearchMetadata:
|
|
33
|
-
onGetSavedSearchSettings:
|
|
34
|
-
onSaveSearch:
|
|
35
|
-
searchProps:
|
|
36
|
-
} =
|
|
37
|
-
return /* @__PURE__ */
|
|
38
|
-
|
|
39
|
-
|
|
32
|
+
onDeleteSearch: u,
|
|
33
|
+
onUpdateSearchMetadata: g,
|
|
34
|
+
onGetSavedSearchSettings: x,
|
|
35
|
+
onSaveSearch: P,
|
|
36
|
+
searchProps: j
|
|
37
|
+
} = G({ markerField: s, markerValue: c, initialSearchState: { rowsPerPage: 5 } }), w = ({ collectionId: t }) => x({ collectionId: t }).then((y) => d(y, t));
|
|
38
|
+
return /* @__PURE__ */ D("div", { className: V(e.root, "VdtSavedSearch-root", S), children: [
|
|
39
|
+
r && /* @__PURE__ */ o(
|
|
40
|
+
r,
|
|
40
41
|
{
|
|
41
42
|
itemSearchDocument: n,
|
|
42
43
|
onSuccess: i,
|
|
43
44
|
onError: h,
|
|
44
|
-
onSaveSearch:
|
|
45
|
+
onSaveSearch: P,
|
|
45
46
|
...l
|
|
46
47
|
}
|
|
47
48
|
),
|
|
48
|
-
|
|
49
|
-
|
|
49
|
+
a && /* @__PURE__ */ o(
|
|
50
|
+
a,
|
|
50
51
|
{
|
|
51
|
-
onSelect:
|
|
52
|
-
onDelete:
|
|
53
|
-
onUpdateSearchMetadata:
|
|
54
|
-
searchProps:
|
|
52
|
+
onSelect: w,
|
|
53
|
+
onDelete: u,
|
|
54
|
+
onUpdateSearchMetadata: g,
|
|
55
|
+
searchProps: j,
|
|
55
56
|
accessTranslate: v,
|
|
56
|
-
extraMenuItems:
|
|
57
|
+
extraMenuItems: f,
|
|
58
|
+
isLoading: p,
|
|
57
59
|
...m
|
|
58
60
|
}
|
|
59
61
|
)
|
|
60
62
|
] });
|
|
61
63
|
}
|
|
62
|
-
const
|
|
64
|
+
const B = E(N, { name: "VdtSavedSearchList" })(U);
|
|
63
65
|
export {
|
|
64
|
-
|
|
66
|
+
B as default
|
|
65
67
|
};
|
|
@@ -1,49 +1,51 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { withStyles as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
const
|
|
6
|
-
function
|
|
2
|
+
import { withStyles as f, List as p } from "@material-ui/core";
|
|
3
|
+
import u from "../../collection/CollectionSearchPicker/index.js";
|
|
4
|
+
import w from "./SavedSearchRow.js";
|
|
5
|
+
const C = {};
|
|
6
|
+
function I({
|
|
7
7
|
searchProps: a,
|
|
8
8
|
searchPlaceholderText: i = "Find searches",
|
|
9
9
|
onSelect: n,
|
|
10
10
|
onDelete: d,
|
|
11
11
|
onUpdateSearchMetadata: s,
|
|
12
|
-
RowComponent: m =
|
|
12
|
+
RowComponent: m = w,
|
|
13
13
|
RowProps: c = {},
|
|
14
14
|
accessTranslate: h,
|
|
15
15
|
extraMenuItems: l,
|
|
16
|
-
|
|
16
|
+
isLoading: S,
|
|
17
|
+
...P
|
|
17
18
|
}) {
|
|
18
19
|
return /* @__PURE__ */ t(
|
|
19
|
-
|
|
20
|
+
u,
|
|
20
21
|
{
|
|
21
22
|
searchProps: a,
|
|
22
23
|
searchPlaceholder: i,
|
|
23
|
-
CollectionTableComponent: ({ collectionListType: o, onRefresh: r }) => /* @__PURE__ */ t(
|
|
24
|
+
CollectionTableComponent: ({ collectionListType: o, onRefresh: r }) => /* @__PURE__ */ t(p, { children: o && o.collection && o.collection.map((e) => /* @__PURE__ */ t(
|
|
24
25
|
m,
|
|
25
26
|
{
|
|
26
27
|
collectionType: e,
|
|
27
28
|
onSelect: () => n({ collectionId: e.id }),
|
|
28
29
|
onDelete: () => Promise.resolve(d({ collectionId: e.id }).then(r)),
|
|
29
|
-
onUpdateSearchMetadata: (
|
|
30
|
+
onUpdateSearchMetadata: (v) => Promise.resolve(
|
|
30
31
|
s({
|
|
31
32
|
collectionId: e.id,
|
|
32
|
-
metadataDocument:
|
|
33
|
+
metadataDocument: v
|
|
33
34
|
}).then(r)
|
|
34
35
|
),
|
|
35
36
|
accessTranslate: h,
|
|
36
37
|
extraMenuItems: l,
|
|
38
|
+
isLoading: S,
|
|
37
39
|
...c
|
|
38
40
|
},
|
|
39
41
|
e.id
|
|
40
42
|
)) }),
|
|
41
43
|
PaginationProps: { rowsPerPageOptions: [5, 10] },
|
|
42
|
-
...
|
|
44
|
+
...P
|
|
43
45
|
}
|
|
44
46
|
);
|
|
45
47
|
}
|
|
46
|
-
const
|
|
48
|
+
const j = f(C, { name: "VdtSavedSearchList" })(I);
|
|
47
49
|
export {
|
|
48
|
-
|
|
50
|
+
j as default
|
|
49
51
|
};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { useState as
|
|
3
|
-
import
|
|
4
|
-
import { withStyles as
|
|
5
|
-
import { parseMetadataType as
|
|
6
|
-
import { compose as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
const
|
|
1
|
+
import { jsxs as k, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { useState as U, useMemo as Y } from "react";
|
|
3
|
+
import Z from "clsx";
|
|
4
|
+
import { withStyles as z } from "@material-ui/core";
|
|
5
|
+
import { parseMetadataType as P } from "@vidispine/vdt-js";
|
|
6
|
+
import { compose as C, useGetSavedSearchFolders as ee, useSavedSearch as te } from "@vidispine/vdt-react";
|
|
7
|
+
import ne from "../SavedSearch/SavedSearchRow.js";
|
|
8
|
+
import ae from "./AddFolderRow.js";
|
|
9
|
+
const $ = {
|
|
10
10
|
markerValue: "savedSearch",
|
|
11
11
|
markerField: "eidr_referentType"
|
|
12
|
-
},
|
|
12
|
+
}, de = {
|
|
13
13
|
indentationWidth: 20,
|
|
14
14
|
indentationDepthStart: 1,
|
|
15
15
|
defaultRowIndentationOffset: 15,
|
|
16
16
|
defalutNewRowIndentation: 10
|
|
17
|
-
},
|
|
17
|
+
}, oe = () => ({
|
|
18
18
|
root: {
|
|
19
19
|
display: "flex",
|
|
20
20
|
width: "100%",
|
|
@@ -24,7 +24,7 @@ const U = {
|
|
|
24
24
|
display: "flex",
|
|
25
25
|
width: "100%"
|
|
26
26
|
}
|
|
27
|
-
}),
|
|
27
|
+
}), ie = (a) => ({
|
|
28
28
|
root: {
|
|
29
29
|
display: "flex",
|
|
30
30
|
width: "100%"
|
|
@@ -36,10 +36,10 @@ const U = {
|
|
|
36
36
|
marginRight: 5
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
function
|
|
39
|
+
function le({
|
|
40
40
|
className: a,
|
|
41
41
|
classes: t,
|
|
42
|
-
children:
|
|
42
|
+
children: s,
|
|
43
43
|
indentationWidth: h,
|
|
44
44
|
hideWrapper: S,
|
|
45
45
|
folderDepth: i,
|
|
@@ -49,7 +49,7 @@ function ie({
|
|
|
49
49
|
addNewRowIndentation: I
|
|
50
50
|
}) {
|
|
51
51
|
const w = d ? !0 : i >= u, o = d ? I : l;
|
|
52
|
-
return S ? null : /* @__PURE__ */
|
|
52
|
+
return S ? null : /* @__PURE__ */ k("div", { className: Z(a, t.root), children: [
|
|
53
53
|
w && /* @__PURE__ */ n(
|
|
54
54
|
"div",
|
|
55
55
|
{
|
|
@@ -60,17 +60,17 @@ function ie({
|
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
62
|
),
|
|
63
|
-
|
|
63
|
+
s
|
|
64
64
|
] });
|
|
65
65
|
}
|
|
66
|
-
const
|
|
67
|
-
|
|
68
|
-
)(
|
|
69
|
-
function
|
|
66
|
+
const re = C(
|
|
67
|
+
z(ie, { name: "VdtFolderRowContentWrapper" })
|
|
68
|
+
)(le);
|
|
69
|
+
function A({
|
|
70
70
|
classes: a,
|
|
71
71
|
id: t,
|
|
72
|
-
queryParams:
|
|
73
|
-
markerProps: h =
|
|
72
|
+
queryParams: s,
|
|
73
|
+
markerProps: h = $,
|
|
74
74
|
childFolders: S = [],
|
|
75
75
|
metadata: i = {},
|
|
76
76
|
itemSearchDocument: u = {},
|
|
@@ -79,46 +79,47 @@ function z({
|
|
|
79
79
|
hideSubFolderSharing: I,
|
|
80
80
|
onSelect: w,
|
|
81
81
|
onRemoveItem: o,
|
|
82
|
-
indentationValues:
|
|
83
|
-
indentationProps: r =
|
|
84
|
-
FolderRowContentComponent: y =
|
|
82
|
+
indentationValues: F = {},
|
|
83
|
+
indentationProps: r = de,
|
|
84
|
+
FolderRowContentComponent: y = ne,
|
|
85
85
|
FolderRowContentProps: p = {},
|
|
86
|
-
AddRowComponent:
|
|
87
|
-
AddRowProps:
|
|
88
|
-
FolderRowContentWrapperComponent: f =
|
|
86
|
+
AddRowComponent: b = ae,
|
|
87
|
+
AddRowProps: g = {},
|
|
88
|
+
FolderRowContentWrapperComponent: f = re,
|
|
89
89
|
FolderRowContentWrapperProps: m = {},
|
|
90
|
-
|
|
90
|
+
isLoading: x,
|
|
91
|
+
...D
|
|
91
92
|
}) {
|
|
92
|
-
const [
|
|
93
|
-
createFolder:
|
|
94
|
-
saveSearch:
|
|
95
|
-
deleteFolder:
|
|
96
|
-
removeItem:
|
|
97
|
-
subFolders:
|
|
98
|
-
} =
|
|
93
|
+
const [R, M] = U(), [V, N] = U({ id: null, type: null }), {
|
|
94
|
+
createFolder: E,
|
|
95
|
+
saveSearch: G,
|
|
96
|
+
deleteFolder: O,
|
|
97
|
+
removeItem: B,
|
|
98
|
+
subFolders: v = []
|
|
99
|
+
} = ee({
|
|
99
100
|
childFolders: S,
|
|
100
|
-
expand:
|
|
101
|
-
queryParams:
|
|
101
|
+
expand: R,
|
|
102
|
+
queryParams: s,
|
|
102
103
|
markerProps: h
|
|
103
|
-
}), { onDeleteSearch:
|
|
104
|
-
|
|
105
|
-
}),
|
|
106
|
-
const { __child_collection_size: e = 0 } =
|
|
107
|
-
return
|
|
108
|
-
}, [
|
|
109
|
-
rowIndentation:
|
|
110
|
-
addNewRowIndentation:
|
|
111
|
-
},
|
|
112
|
-
rowIndentation:
|
|
113
|
-
addNewRowIndentation:
|
|
104
|
+
}), { onDeleteSearch: W, onUpdateSearchMetadata: _, onGetSavedSearchSettings: q } = te({
|
|
105
|
+
...$
|
|
106
|
+
}), T = ({ collectionId: e }) => q({ collectionId: e }).then((X) => w(X, e)), j = P(i, { joinValue: "_", flat: !0 }), H = Y(() => {
|
|
107
|
+
const { __child_collection_size: e = 0 } = j;
|
|
108
|
+
return v.length > 0 || !R && e > 0;
|
|
109
|
+
}, [v.length, R, j]), { defalutNewRowIndentation: J, defaultRowIndentationOffset: K, indentationWidth: L } = r, c = {
|
|
110
|
+
rowIndentation: F.rowIndentation || 0,
|
|
111
|
+
addNewRowIndentation: F.addNewRowIndentation || J
|
|
112
|
+
}, Q = {
|
|
113
|
+
rowIndentation: c.addNewRowIndentation,
|
|
114
|
+
addNewRowIndentation: c.addNewRowIndentation + L + K
|
|
114
115
|
};
|
|
115
|
-
return /* @__PURE__ */
|
|
116
|
+
return /* @__PURE__ */ k("div", { className: a.root, children: [
|
|
116
117
|
{
|
|
117
118
|
folder: /* @__PURE__ */ n(
|
|
118
119
|
f,
|
|
119
120
|
{
|
|
120
121
|
folderDepth: d,
|
|
121
|
-
...
|
|
122
|
+
...c,
|
|
122
123
|
...r,
|
|
123
124
|
...m,
|
|
124
125
|
children: /* @__PURE__ */ n(
|
|
@@ -128,16 +129,17 @@ function z({
|
|
|
128
129
|
hideSubFolderSharing: I,
|
|
129
130
|
type: l,
|
|
130
131
|
collectionType: { id: t, metadata: i },
|
|
131
|
-
disableDeletion:
|
|
132
|
-
onDelete: () => Promise.resolve(
|
|
132
|
+
disableDeletion: H,
|
|
133
|
+
onDelete: () => Promise.resolve(O(t)).then(() => {
|
|
133
134
|
o && o(t);
|
|
134
135
|
}),
|
|
135
|
-
onUpdateSearchMetadata: (e) =>
|
|
136
|
+
onUpdateSearchMetadata: (e) => _({
|
|
136
137
|
collectionId: t,
|
|
137
138
|
metadataDocument: e
|
|
138
139
|
}),
|
|
139
|
-
onExpand: () =>
|
|
140
|
-
onAddRow:
|
|
140
|
+
onExpand: () => M((e) => !e),
|
|
141
|
+
onAddRow: N,
|
|
142
|
+
isLoading: x,
|
|
141
143
|
...p
|
|
142
144
|
}
|
|
143
145
|
)
|
|
@@ -147,7 +149,7 @@ function z({
|
|
|
147
149
|
f,
|
|
148
150
|
{
|
|
149
151
|
folderDepth: d,
|
|
150
|
-
...
|
|
152
|
+
...c,
|
|
151
153
|
...r,
|
|
152
154
|
...m,
|
|
153
155
|
children: /* @__PURE__ */ n(
|
|
@@ -156,15 +158,16 @@ function z({
|
|
|
156
158
|
isFolderRow: !0,
|
|
157
159
|
type: l,
|
|
158
160
|
collectionType: { id: t, metadata: i },
|
|
159
|
-
onSelect: () =>
|
|
160
|
-
onDelete: () => Promise.resolve(
|
|
161
|
+
onSelect: () => T({ collectionId: t }),
|
|
162
|
+
onDelete: () => Promise.resolve(W({ collectionId: t })).then(() => {
|
|
161
163
|
o && o(t);
|
|
162
164
|
}),
|
|
163
|
-
onUpdateSearchMetadata: (e) =>
|
|
165
|
+
onUpdateSearchMetadata: (e) => _({
|
|
164
166
|
collectionId: t,
|
|
165
167
|
metadataDocument: e
|
|
166
168
|
}),
|
|
167
|
-
onAddRow:
|
|
169
|
+
onAddRow: N,
|
|
170
|
+
isLoading: x,
|
|
168
171
|
...p
|
|
169
172
|
}
|
|
170
173
|
)
|
|
@@ -176,31 +179,31 @@ function z({
|
|
|
176
179
|
{
|
|
177
180
|
isAddRow: !0,
|
|
178
181
|
folderDepth: d,
|
|
179
|
-
...
|
|
182
|
+
...c,
|
|
180
183
|
...r,
|
|
181
|
-
hideWrapper: !
|
|
184
|
+
hideWrapper: !V.id,
|
|
182
185
|
...m,
|
|
183
186
|
children: /* @__PURE__ */ n(
|
|
184
|
-
|
|
187
|
+
b,
|
|
185
188
|
{
|
|
186
189
|
id: t,
|
|
187
|
-
setExpand:
|
|
188
|
-
saveSearch:
|
|
189
|
-
onAddRow:
|
|
190
|
-
createFolder:
|
|
190
|
+
setExpand: M,
|
|
191
|
+
saveSearch: G,
|
|
192
|
+
onAddRow: N,
|
|
193
|
+
createFolder: E,
|
|
191
194
|
itemSearchDocument: u,
|
|
192
|
-
newField:
|
|
193
|
-
...
|
|
195
|
+
newField: V,
|
|
196
|
+
...g
|
|
194
197
|
}
|
|
195
198
|
)
|
|
196
199
|
}
|
|
197
200
|
),
|
|
198
|
-
|
|
199
|
-
|
|
201
|
+
v.map((e) => /* @__PURE__ */ n(
|
|
202
|
+
A,
|
|
200
203
|
{
|
|
201
204
|
classes: a,
|
|
202
205
|
id: e.id,
|
|
203
|
-
queryParams:
|
|
206
|
+
queryParams: s,
|
|
204
207
|
markerProps: h,
|
|
205
208
|
childFolders: e.subFolders,
|
|
206
209
|
metadata: e.metadata,
|
|
@@ -208,24 +211,25 @@ function z({
|
|
|
208
211
|
folderDepth: d + 1,
|
|
209
212
|
type: e.type,
|
|
210
213
|
hideSubFolderSharing: !0,
|
|
211
|
-
handleSelect:
|
|
214
|
+
handleSelect: T,
|
|
212
215
|
onSelect: w,
|
|
213
|
-
onRemoveItem: () =>
|
|
216
|
+
onRemoveItem: () => B(e.id),
|
|
214
217
|
indentationProps: r,
|
|
215
218
|
FolderRowContentComponent: y,
|
|
216
219
|
FolderRowContentProps: p,
|
|
217
|
-
AddRowComponent:
|
|
218
|
-
AddRowProps:
|
|
220
|
+
AddRowComponent: b,
|
|
221
|
+
AddRowProps: g,
|
|
219
222
|
FolderRowContentWrapperComponent: f,
|
|
220
223
|
FolderRowContentWrapperProps: m,
|
|
221
|
-
indentationValues:
|
|
222
|
-
|
|
224
|
+
indentationValues: Q,
|
|
225
|
+
isLoading: x,
|
|
226
|
+
props: D
|
|
223
227
|
},
|
|
224
228
|
e.id
|
|
225
229
|
))
|
|
226
230
|
] });
|
|
227
231
|
}
|
|
228
|
-
const
|
|
232
|
+
const Ie = z(oe, { name: "VdtFolderRow" })(A);
|
|
229
233
|
export {
|
|
230
|
-
|
|
234
|
+
Ie as default
|
|
231
235
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vidispine/vdt-materialui",
|
|
3
|
-
"version": "23.
|
|
3
|
+
"version": "23.3.0-pre.2",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -35,11 +35,11 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@babel/runtime": "^7.21.0",
|
|
38
|
-
"@vidispine/proptypes": "23.
|
|
39
|
-
"@vidispine/vdt-api": "23.
|
|
40
|
-
"@vidispine/vdt-js": "23.
|
|
41
|
-
"@vidispine/vdt-react": "23.
|
|
42
|
-
"@vidispine/vdt-videojs-react": "23.
|
|
38
|
+
"@vidispine/proptypes": "23.3.0-pre.2",
|
|
39
|
+
"@vidispine/vdt-api": "23.3.0-pre.2",
|
|
40
|
+
"@vidispine/vdt-js": "23.3.0-pre.2",
|
|
41
|
+
"@vidispine/vdt-react": "23.3.0-pre.2",
|
|
42
|
+
"@vidispine/vdt-videojs-react": "23.3.0-pre.2",
|
|
43
43
|
"clsx": "^1.2.1",
|
|
44
44
|
"core-js": "^3.28.0",
|
|
45
45
|
"filesize": "^10.0.6",
|
|
@@ -71,11 +71,11 @@
|
|
|
71
71
|
},
|
|
72
72
|
"devDependencies": {
|
|
73
73
|
"@types/jest": "28.1.8",
|
|
74
|
-
"@vidispine/eslint-config-mdx": "23.
|
|
75
|
-
"@vidispine/eslint-config-react": "23.
|
|
76
|
-
"@vidispine/eslint-config-storybook": "23.
|
|
77
|
-
"@vidispine/prettier-config": "23.
|
|
78
|
-
"@vidispine/proptypes": "23.
|
|
74
|
+
"@vidispine/eslint-config-mdx": "23.3.0-pre.2",
|
|
75
|
+
"@vidispine/eslint-config-react": "23.3.0-pre.2",
|
|
76
|
+
"@vidispine/eslint-config-storybook": "23.3.0-pre.2",
|
|
77
|
+
"@vidispine/prettier-config": "23.3.0-pre.2",
|
|
78
|
+
"@vidispine/proptypes": "23.3.0-pre.2",
|
|
79
79
|
"@vitejs/plugin-react": "3.1.0",
|
|
80
80
|
"@wojtekmaj/enzyme-adapter-react-17": "0.8.0",
|
|
81
81
|
"axios": "0.21.4",
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
"moment-duration-format": "2.3.2",
|
|
93
93
|
"prettier": "2.8.4",
|
|
94
94
|
"prop-types": "15.8.1",
|
|
95
|
-
"vite": "4.3.
|
|
95
|
+
"vite": "4.3.9"
|
|
96
96
|
},
|
|
97
97
|
"scarfSettings": {
|
|
98
98
|
"enabled": false
|