sanity-plugin-media 6.1.5 → 6.1.6
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/index.js +192 -177
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -75,12 +75,12 @@ const AssetSourceDispatchContext = createContext(void 0), AssetBrowserDispatchPr
|
|
|
75
75
|
if (context === void 0) throw Error("useAssetSourceActions must be used within an AssetSourceDispatchProvider");
|
|
76
76
|
return context;
|
|
77
77
|
}, useRootPortalElement = () => {
|
|
78
|
-
let $ = c(3), [container] = useState(_temp$
|
|
78
|
+
let $ = c(3), [container] = useState(_temp$38), t0, t1;
|
|
79
79
|
return $[0] === container ? (t0 = $[1], t1 = $[2]) : (t0 = () => (container.classList.add("media-portal"), document.body.appendChild(container), () => {
|
|
80
80
|
document.body.removeChild(container);
|
|
81
81
|
}), t1 = [container], $[0] = container, $[1] = t0, $[2] = t1), useEffect(t0, t1), container;
|
|
82
82
|
};
|
|
83
|
-
function _temp$
|
|
83
|
+
function _temp$38() {
|
|
84
84
|
return document.createElement("div");
|
|
85
85
|
}
|
|
86
86
|
const useTypedSelector = useSelector, useVersionedClient = () => {
|
|
@@ -2110,7 +2110,7 @@ const ButtonAssetCopy = (t0) => {
|
|
|
2110
2110
|
}), $[2] = doc, $[3] = onClick, $[4] = schemaType, $[5] = t1) : t1 = $[5], t1;
|
|
2111
2111
|
}, Container$2 = /* @__PURE__ */ styled(Box).withConfig({
|
|
2112
2112
|
displayName: "Container",
|
|
2113
|
-
componentId: "sc-
|
|
2113
|
+
componentId: "sc-91y0jf-0"
|
|
2114
2114
|
})(({ theme }) => css`text{font-family:${theme.sanity.fonts.text.family} !important;font-size:8px !important;font-weight:500 !important;}`), FileIcon$1 = (props) => {
|
|
2115
2115
|
let $ = c(11), { extension, onClick, width } = props, t0;
|
|
2116
2116
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = { height: "100%" }, $[0] = t0) : t0 = $[0];
|
|
@@ -2256,10 +2256,10 @@ function getSchemeColor(scheme, colorKey) {
|
|
|
2256
2256
|
}
|
|
2257
2257
|
const Image$1 = styled.img.attrs({ crossOrigin: "anonymous" }).withConfig({
|
|
2258
2258
|
displayName: "Image",
|
|
2259
|
-
componentId: "sc-
|
|
2259
|
+
componentId: "sc-ms5kkw-0"
|
|
2260
2260
|
})`--checkerboard-color:${(props) => props.$scheme ? getSchemeColor(props.$scheme, "bg2") : "inherit"};display:block;width:100%;height:100%;object-fit:contain;${(props) => props.$showCheckerboard && css`background-image:linear-gradient(45deg,var(--checkerboard-color) 25%,transparent 25%),linear-gradient(-45deg,var(--checkerboard-color) 25%,transparent 25%),linear-gradient(45deg,transparent 75%,var(--checkerboard-color) 75%),linear-gradient(-45deg,transparent 75%,var(--checkerboard-color) 75%);background-size:20px 20px;background-position:0 0,0 10px,10px -10px,-10px 0;`}`, StyledErrorOutlineIcon = /* @__PURE__ */ styled(ErrorOutlineIcon).withConfig({
|
|
2261
2261
|
displayName: "StyledErrorOutlineIcon",
|
|
2262
|
-
componentId: "sc-
|
|
2262
|
+
componentId: "sc-3yqi4g-0"
|
|
2263
2263
|
})(({ theme }) => ({ color: theme.sanity.color.spot.red })), FormFieldInputLabel = (props) => {
|
|
2264
2264
|
let $ = c(14), { description, error, label, name } = props, t0;
|
|
2265
2265
|
$[0] !== label || $[1] !== name ? (t0 = /* @__PURE__ */ jsx(Text, {
|
|
@@ -2477,7 +2477,7 @@ const Image$1 = styled.img.attrs({ crossOrigin: "anonymous" }).withConfig({
|
|
|
2477
2477
|
MultiValueRemove,
|
|
2478
2478
|
Option: Option$1
|
|
2479
2479
|
}, FormFieldInputTags = (props) => {
|
|
2480
|
-
let $ = c(23), { control, description, disabled, error, label, name, onCreateTag, options, placeholder, value } = props, scheme = useColorSchemeValue(), creating = useTypedSelector(_temp$
|
|
2480
|
+
let $ = c(23), { control, description, disabled, error, label, name, onCreateTag, options, placeholder, value } = props, scheme = useColorSchemeValue(), creating = useTypedSelector(_temp$37), tagsFetching = useTypedSelector(_temp2$23), t0;
|
|
2481
2481
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = { zIndex: 2 }, $[0] = t0) : t0 = $[0];
|
|
2482
2482
|
let t1;
|
|
2483
2483
|
$[1] !== description || $[2] !== error || $[3] !== label || $[4] !== name ? (t1 = /* @__PURE__ */ jsx(FormFieldInputLabel, {
|
|
@@ -2497,7 +2497,7 @@ const Image$1 = styled.img.attrs({ crossOrigin: "anonymous" }).withConfig({
|
|
|
2497
2497
|
isLoading: creating,
|
|
2498
2498
|
isMulti: !0,
|
|
2499
2499
|
name,
|
|
2500
|
-
noOptionsMessage: _temp3$
|
|
2500
|
+
noOptionsMessage: _temp3$11,
|
|
2501
2501
|
onBlur,
|
|
2502
2502
|
onChange,
|
|
2503
2503
|
onCreateOption: onCreateTag,
|
|
@@ -2520,13 +2520,13 @@ const Image$1 = styled.img.attrs({ crossOrigin: "anonymous" }).withConfig({
|
|
|
2520
2520
|
children: [t1, t3]
|
|
2521
2521
|
}), $[20] = t1, $[21] = t3, $[22] = t4) : t4 = $[22], t4;
|
|
2522
2522
|
};
|
|
2523
|
-
function _temp$
|
|
2523
|
+
function _temp$37(state) {
|
|
2524
2524
|
return state.tags.creating;
|
|
2525
2525
|
}
|
|
2526
|
-
function _temp2$
|
|
2526
|
+
function _temp2$23(state_0) {
|
|
2527
2527
|
return state_0.tags.fetching;
|
|
2528
2528
|
}
|
|
2529
|
-
function _temp3$
|
|
2529
|
+
function _temp3$11() {
|
|
2530
2530
|
return "No tags";
|
|
2531
2531
|
}
|
|
2532
2532
|
const FormFieldInputText = (props) => {
|
|
@@ -2686,45 +2686,45 @@ function Details({ formUpdating, handleCreateTag, control, errors, register, all
|
|
|
2686
2686
|
onClick: () => setActiveLocaleTab(idx),
|
|
2687
2687
|
label: locale.title
|
|
2688
2688
|
}, locale.id))
|
|
2689
|
-
}), locales.map((
|
|
2690
|
-
id: `locale-panel-${
|
|
2691
|
-
"aria-labelledby": `locale-tab-${
|
|
2692
|
-
hidden: activeLocaleTab !==
|
|
2689
|
+
}), locales.map((locale, idx) => /* @__PURE__ */ jsx(TabPanel, {
|
|
2690
|
+
id: `locale-panel-${locale.id}`,
|
|
2691
|
+
"aria-labelledby": `locale-tab-${locale.id}`,
|
|
2692
|
+
hidden: activeLocaleTab !== idx,
|
|
2693
2693
|
children: /* @__PURE__ */ jsxs(Stack, {
|
|
2694
2694
|
gap: 3,
|
|
2695
2695
|
children: [
|
|
2696
2696
|
/* @__PURE__ */ jsx(FormFieldInputText, {
|
|
2697
|
-
...register(`title.${
|
|
2697
|
+
...register(`title.${locale.id}`),
|
|
2698
2698
|
disabled: formUpdating,
|
|
2699
|
-
error: (errors?.title)?.[
|
|
2699
|
+
error: (errors?.title)?.[locale.id]?.message,
|
|
2700
2700
|
label: "Title",
|
|
2701
|
-
name: `title.${
|
|
2701
|
+
name: `title.${locale.id}`
|
|
2702
2702
|
}),
|
|
2703
2703
|
/* @__PURE__ */ jsx(FormFieldInputText, {
|
|
2704
|
-
...register(`altText.${
|
|
2704
|
+
...register(`altText.${locale.id}`),
|
|
2705
2705
|
disabled: formUpdating,
|
|
2706
|
-
error: (errors?.altText)?.[
|
|
2706
|
+
error: (errors?.altText)?.[locale.id]?.message,
|
|
2707
2707
|
label: "Alt Text",
|
|
2708
|
-
name: `altText.${
|
|
2708
|
+
name: `altText.${locale.id}`
|
|
2709
2709
|
}),
|
|
2710
2710
|
/* @__PURE__ */ jsx(FormFieldInputTextarea, {
|
|
2711
|
-
...register(`description.${
|
|
2711
|
+
...register(`description.${locale.id}`),
|
|
2712
2712
|
disabled: formUpdating,
|
|
2713
|
-
error: (errors?.description)?.[
|
|
2713
|
+
error: (errors?.description)?.[locale.id]?.message,
|
|
2714
2714
|
label: "Description",
|
|
2715
|
-
name: `description.${
|
|
2715
|
+
name: `description.${locale.id}`,
|
|
2716
2716
|
rows: 5
|
|
2717
2717
|
}),
|
|
2718
2718
|
creditLine?.enabled && /* @__PURE__ */ jsx(FormFieldInputText, {
|
|
2719
|
-
...register(`creditLine.${
|
|
2720
|
-
error: (errors?.creditLine)?.[
|
|
2719
|
+
...register(`creditLine.${locale.id}`),
|
|
2720
|
+
error: (errors?.creditLine)?.[locale.id]?.message,
|
|
2721
2721
|
label: "Credit",
|
|
2722
|
-
name: `creditLine.${
|
|
2722
|
+
name: `creditLine.${locale.id}`,
|
|
2723
2723
|
disabled: formUpdating || creditLine?.excludeSources?.includes(currentAsset?.source?.name)
|
|
2724
2724
|
})
|
|
2725
2725
|
]
|
|
2726
2726
|
})
|
|
2727
|
-
},
|
|
2727
|
+
}, locale.id))]
|
|
2728
2728
|
})
|
|
2729
2729
|
}) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2730
2730
|
/* @__PURE__ */ jsx(FormFieldInputText, {
|
|
@@ -2802,7 +2802,7 @@ const DialogAssetEdit = (props) => {
|
|
|
2802
2802
|
title: makeLocaleObj(asset?.title)
|
|
2803
2803
|
};
|
|
2804
2804
|
}
|
|
2805
|
-
let flattenField = _temp2$
|
|
2805
|
+
let flattenField = _temp2$22;
|
|
2806
2806
|
return {
|
|
2807
2807
|
altText: flattenField(asset?.altText),
|
|
2808
2808
|
creditLine: flattenField(asset?.creditLine),
|
|
@@ -2868,7 +2868,7 @@ const DialogAssetEdit = (props) => {
|
|
|
2868
2868
|
t19 = !1;
|
|
2869
2869
|
break bb0;
|
|
2870
2870
|
}
|
|
2871
|
-
let isLocaleObj = _temp3$
|
|
2871
|
+
let isLocaleObj = _temp3$10, fields = [
|
|
2872
2872
|
currentAsset.title,
|
|
2873
2873
|
currentAsset.altText,
|
|
2874
2874
|
currentAsset.description,
|
|
@@ -3180,14 +3180,14 @@ const DialogAssetEdit = (props) => {
|
|
|
3180
3180
|
children: [t52, children]
|
|
3181
3181
|
}), $[144] = children, $[145] = footer, $[146] = handleClose, $[147] = id, $[148] = t52, $[149] = t53) : t53 = $[149], t53;
|
|
3182
3182
|
};
|
|
3183
|
-
function _temp$
|
|
3183
|
+
function _temp$36(v) {
|
|
3184
3184
|
return v;
|
|
3185
3185
|
}
|
|
3186
|
-
function _temp2$
|
|
3186
|
+
function _temp2$22(field_0, t0) {
|
|
3187
3187
|
let fallback_0 = t0 === void 0 ? "" : t0;
|
|
3188
|
-
return typeof field_0 == "string" ? field_0 : typeof field_0 == "object" && field_0 && Object.values(field_0).find(_temp$
|
|
3188
|
+
return typeof field_0 == "string" ? field_0 : typeof field_0 == "object" && field_0 && Object.values(field_0).find(_temp$36) || fallback_0;
|
|
3189
3189
|
}
|
|
3190
|
-
function _temp3$
|
|
3190
|
+
function _temp3$10(v_0) {
|
|
3191
3191
|
return typeof v_0 == "object" && !!v_0 && !Array.isArray(v_0);
|
|
3192
3192
|
}
|
|
3193
3193
|
function _temp4$5(l) {
|
|
@@ -3245,23 +3245,23 @@ const selectCombinedItems = createSelector([
|
|
|
3245
3245
|
}), t3 = [downHandler, upHandler], $[4] = downHandler, $[5] = t2, $[6] = t3), useEffect(t2, t3), keyPressed;
|
|
3246
3246
|
}, CardWrapper$2 = styled(Flex).withConfig({
|
|
3247
3247
|
displayName: "CardWrapper",
|
|
3248
|
-
componentId: "sc-
|
|
3248
|
+
componentId: "sc-paw993-0"
|
|
3249
3249
|
})`box-sizing:border-box;height:100%;overflow:hidden;position:relative;width:100%;`, CardContainer = /* @__PURE__ */ styled(Flex).withConfig({
|
|
3250
3250
|
displayName: "CardContainer",
|
|
3251
|
-
componentId: "sc-
|
|
3251
|
+
componentId: "sc-paw993-1"
|
|
3252
3252
|
})(({ $picked, theme, $updating }) => css`border:1px solid transparent;height:100%;pointer-events:${$updating ? "none" : "auto"};position:relative;transition:all 300ms;user-select:none;width:100%;border:${$picked ? `1px solid ${theme.sanity.color.spot.orange} !important` : "1px solid inherit"};${!$updating && css`@media (hover:hover) and (pointer:fine){&:hover{border:1px solid var(--card-border-color);}}`}`), ContextActionContainer$2 = /* @__PURE__ */ styled(Flex).withConfig({
|
|
3253
3253
|
displayName: "ContextActionContainer",
|
|
3254
|
-
componentId: "sc-
|
|
3254
|
+
componentId: "sc-paw993-2"
|
|
3255
3255
|
})(({ $scheme }) => css`cursor:pointer;height:${32}px;transition:all 300ms;@media (hover:hover) and (pointer:fine){&:hover{background:${getSchemeColor($scheme, "bg")};}}`), StyledWarningOutlineIcon = /* @__PURE__ */ styled(WarningFilledIcon).withConfig({
|
|
3256
3256
|
displayName: "StyledWarningOutlineIcon",
|
|
3257
|
-
componentId: "sc-
|
|
3257
|
+
componentId: "sc-paw993-3"
|
|
3258
3258
|
})(({ theme }) => ({ color: theme.sanity.color.spot.red })), CardAsset = (props) => {
|
|
3259
|
-
let $ = c(83), { id, selected, source } = props, scheme = useColorSchemeValue(), toast = useToast(), shiftPressed = useKeyPress("shift"), dispatch = useDispatch(), lastPicked = useTypedSelector(_temp$
|
|
3259
|
+
let $ = c(83), { id, selected, source } = props, scheme = useColorSchemeValue(), toast = useToast(), shiftPressed = useKeyPress("shift"), dispatch = useDispatch(), lastPicked = useTypedSelector(_temp$35), assetsPicked = useTypedSelector(selectAssetsPicked), t0;
|
|
3260
3260
|
$[0] === id ? t0 = $[1] : (t0 = (state_0) => selectAssetById(state_0, id), $[0] = id, $[1] = t0);
|
|
3261
3261
|
let item = useTypedSelector(t0), t1;
|
|
3262
3262
|
$[2] === source ? t1 = $[3] : (t1 = (state_1) => {
|
|
3263
3263
|
if (source !== "replace-asset") return;
|
|
3264
|
-
let dialog = state_1.dialog.items.find(_temp2$
|
|
3264
|
+
let dialog = state_1.dialog.items.find(_temp2$21);
|
|
3265
3265
|
return dialog?.type === "dialogAllAssets" ? dialog.assetId : void 0;
|
|
3266
3266
|
}, $[2] = source, $[3] = t1);
|
|
3267
3267
|
let dialogReplaceAssetId = useTypedSelector(t1), asset = item?.asset, error = item?.error, isOpaque = item?.asset?.metadata?.isOpaque, picked = item?.picked, updating = item?.updating, assetToReplaceId = dialogReplaceAssetId ?? (source === "replace-asset" && assetsPicked.length === 1 ? assetsPicked[0]?.asset._id : void 0), t2;
|
|
@@ -3467,21 +3467,21 @@ const selectCombinedItems = createSelector([
|
|
|
3467
3467
|
}), $[77] = item.updating, $[78] = picked, $[79] = t15, $[80] = t19, $[81] = t20, $[82] = t21) : t21 = $[82], t21;
|
|
3468
3468
|
};
|
|
3469
3469
|
var CardAsset_default = memo(CardAsset);
|
|
3470
|
-
function _temp$
|
|
3470
|
+
function _temp$35(state) {
|
|
3471
3471
|
return state.assets.lastPicked;
|
|
3472
3472
|
}
|
|
3473
|
-
function _temp2$
|
|
3473
|
+
function _temp2$21(d) {
|
|
3474
3474
|
return d.type === "dialogAllAssets";
|
|
3475
3475
|
}
|
|
3476
3476
|
const CardWrapper$1 = styled(Flex).withConfig({
|
|
3477
3477
|
displayName: "CardWrapper",
|
|
3478
|
-
componentId: "sc-
|
|
3478
|
+
componentId: "sc-52xpdk-0"
|
|
3479
3479
|
})`box-sizing:border-box;height:100%;overflow:hidden;position:relative;width:100%;`, FolderCard = styled(Card).withConfig({
|
|
3480
3480
|
displayName: "FolderCard",
|
|
3481
|
-
componentId: "sc-
|
|
3481
|
+
componentId: "sc-52xpdk-1"
|
|
3482
3482
|
})`cursor:pointer;height:100%;transition:border-color 200ms ease;width:100%;@media (hover:hover) and (pointer:fine){&:hover{border-color:var(--card-border-color);}}`, FolderGlyph = /* @__PURE__ */ styled(Box).withConfig({
|
|
3483
3483
|
displayName: "FolderGlyph",
|
|
3484
|
-
componentId: "sc-
|
|
3484
|
+
componentId: "sc-52xpdk-2"
|
|
3485
3485
|
})(({ theme }) => css`align-items:flex-end;background:linear-gradient( 180deg,${theme.sanity.color.spot.yellow} 0%,${theme.sanity.color.spot.yellow} 100% );border-radius:8px;display:flex;height:72px;position:relative;width:96px;&::before{background:${theme.sanity.color.spot.yellow};border-radius:8px 8px 0 0;content:'';height:18px;left:0;position:absolute;top:-8px;width:38px;}`), CardFolder = (t0) => {
|
|
3486
3486
|
let $ = c(22), { folderId, name, totalCount } = t0, dispatch = useDispatch(), scheme = useColorSchemeValue(), t1;
|
|
3487
3487
|
$[0] !== dispatch || $[1] !== folderId ? (t1 = () => dispatch(foldersActions.currentFolderSet({ folderId })), $[0] = dispatch, $[1] = folderId, $[2] = t1) : t1 = $[2];
|
|
@@ -3724,7 +3724,7 @@ const createThrottler = (concurrency = 4) => {
|
|
|
3724
3724
|
var uploads_default = uploadsSlice.reducer;
|
|
3725
3725
|
const CardWrapper = styled(Flex).withConfig({
|
|
3726
3726
|
displayName: "CardWrapper",
|
|
3727
|
-
componentId: "sc-
|
|
3727
|
+
componentId: "sc-2pwgvh-0"
|
|
3728
3728
|
})`box-sizing:border-box;height:100%;overflow:hidden;position:relative;width:100%;`, CardUpload = (props) => {
|
|
3729
3729
|
let $ = c(43), { id } = props, scheme = useColorSchemeValue(), dispatch = useDispatch(), t0;
|
|
3730
3730
|
$[0] === id ? t0 = $[1] : (t0 = (state) => selectUploadById(state, id), $[0] = id, $[1] = t0);
|
|
@@ -3887,7 +3887,7 @@ const CardWrapper = styled(Flex).withConfig({
|
|
|
3887
3887
|
return null;
|
|
3888
3888
|
}), StyledItemContainer = styled.div.withConfig({
|
|
3889
3889
|
displayName: "StyledItemContainer",
|
|
3890
|
-
componentId: "sc-
|
|
3890
|
+
componentId: "sc-2rsg9t-0"
|
|
3891
3891
|
})`height:${220}px;width:${240}px;`, ItemContainer = (props) => {
|
|
3892
3892
|
let $ = c(6), ref, rest;
|
|
3893
3893
|
if ($[0] !== props) {
|
|
@@ -3901,7 +3901,7 @@ const CardWrapper = styled(Flex).withConfig({
|
|
|
3901
3901
|
}), $[3] = ref, $[4] = rest, $[5] = t0) : t0 = $[5], t0;
|
|
3902
3902
|
}, StyledListContainer = styled.div.withConfig({
|
|
3903
3903
|
displayName: "StyledListContainer",
|
|
3904
|
-
componentId: "sc-
|
|
3904
|
+
componentId: "sc-2rsg9t-1"
|
|
3905
3905
|
})`display:grid;grid-template-columns:repeat(auto-fill,${240}px);grid-template-rows:repeat(auto-fill,${220}px);justify-content:center;margin:0 auto;`, ListContainer = (props) => {
|
|
3906
3906
|
let $ = c(6), ref, rest;
|
|
3907
3907
|
if ($[0] !== props) {
|
|
@@ -3914,8 +3914,8 @@ const CardWrapper = styled(Flex).withConfig({
|
|
|
3914
3914
|
...rest
|
|
3915
3915
|
}), $[3] = ref, $[4] = rest, $[5] = t0) : t0 = $[5], t0;
|
|
3916
3916
|
}, AssetGridVirtualized = (props) => {
|
|
3917
|
-
let $ = c(15), { items, onLoadMore, source } = props, selectedAssets = useTypedSelector(_temp$
|
|
3918
|
-
$[0] === selectedAssets ? t0 = $[1] : (t0 = selectedAssets && selectedAssets.map(_temp2$
|
|
3917
|
+
let $ = c(15), { items, onLoadMore, source } = props, selectedAssets = useTypedSelector(_temp$34), t0;
|
|
3918
|
+
$[0] === selectedAssets ? t0 = $[1] : (t0 = selectedAssets && selectedAssets.map(_temp2$20) || [], $[0] = selectedAssets, $[1] = t0);
|
|
3919
3919
|
let selectedIds = t0, totalCount = items?.length;
|
|
3920
3920
|
if (totalCount === 0) return null;
|
|
3921
3921
|
let t1;
|
|
@@ -3951,10 +3951,10 @@ const CardWrapper = styled(Flex).withConfig({
|
|
|
3951
3951
|
totalCount
|
|
3952
3952
|
}), $[10] = onLoadMore, $[11] = t1, $[12] = t3, $[13] = totalCount, $[14] = t5) : t5 = $[14], t5;
|
|
3953
3953
|
};
|
|
3954
|
-
function _temp$
|
|
3954
|
+
function _temp$34(state) {
|
|
3955
3955
|
return state.selected.assets;
|
|
3956
3956
|
}
|
|
3957
|
-
function _temp2$
|
|
3957
|
+
function _temp2$20(asset) {
|
|
3958
3958
|
return asset._id;
|
|
3959
3959
|
}
|
|
3960
3960
|
function omitFacetId(facet) {
|
|
@@ -3962,11 +3962,11 @@ function omitFacetId(facet) {
|
|
|
3962
3962
|
return withoutId;
|
|
3963
3963
|
}
|
|
3964
3964
|
const ReplaceAssetsOverview = () => {
|
|
3965
|
-
let $ = c(36), dispatch = useDispatch(), store = useStore(), combinedItems = useTypedSelector(selectCombinedItems), assetsById = useTypedSelector(_temp$
|
|
3965
|
+
let $ = c(36), dispatch = useDispatch(), store = useStore(), combinedItems = useTypedSelector(selectCombinedItems), assetsById = useTypedSelector(_temp$33), fetchCount = useTypedSelector(_temp2$19), fetching = useTypedSelector(_temp3$9), fetchingError = useTypedSelector(_temp4$4), pageSize = useTypedSelector(_temp5$3), searchQuery = useTypedSelector(_temp6$1), searchFacets = useTypedSelector(_temp7), currentFolderId = useTypedSelector(_temp8), currentFolderUnfiled = useTypedSelector(_temp9), assetToReplaceId = useTypedSelector(_temp11), savedBrowserStateRef = useRef(null), t0;
|
|
3966
3966
|
$[0] !== currentFolderId || $[1] !== currentFolderUnfiled || $[2] !== searchFacets || $[3] !== searchQuery.length ? (t0 = () => searchQuery.length > 0 || searchFacets.length > 0 || !!currentFolderId || currentFolderUnfiled, $[0] = currentFolderId, $[1] = currentFolderUnfiled, $[2] = searchFacets, $[3] = searchQuery.length, $[4] = t0) : t0 = $[4];
|
|
3967
3967
|
let [awaitingRefetch, setAwaitingRefetch] = useState(t0), t1, t2;
|
|
3968
3968
|
$[5] !== dispatch || $[6] !== store ? (t1 = () => {
|
|
3969
|
-
let { dialog: dialog_0, folders, search } = store.getState(), { query, facets } = search, dialogItem = dialog_0.items.find(
|
|
3969
|
+
let { dialog: dialog_0, folders, search } = store.getState(), { query, facets } = search, dialogItem = dialog_0.items.find(_temp12);
|
|
3970
3970
|
return savedBrowserStateRef.current = {
|
|
3971
3971
|
assetId: dialogItem?.type === "dialogAllAssets" ? dialogItem.assetId : void 0,
|
|
3972
3972
|
query,
|
|
@@ -4043,13 +4043,13 @@ const ReplaceAssetsOverview = () => {
|
|
|
4043
4043
|
})
|
|
4044
4044
|
}), $[32] = handleLoadMoreItems, $[33] = isEmpty, $[34] = reducedItems, $[35] = t9) : t9 = $[35], t9;
|
|
4045
4045
|
};
|
|
4046
|
-
function _temp$
|
|
4046
|
+
function _temp$33(state) {
|
|
4047
4047
|
return state.assets.byIds;
|
|
4048
4048
|
}
|
|
4049
|
-
function _temp2$
|
|
4049
|
+
function _temp2$19(state_0) {
|
|
4050
4050
|
return state_0.assets.fetchCount;
|
|
4051
4051
|
}
|
|
4052
|
-
function _temp3$
|
|
4052
|
+
function _temp3$9(state_1) {
|
|
4053
4053
|
return state_1.assets.fetching;
|
|
4054
4054
|
}
|
|
4055
4055
|
function _temp4$4(state_2) {
|
|
@@ -4070,14 +4070,14 @@ function _temp8(state_6) {
|
|
|
4070
4070
|
function _temp9(state_7) {
|
|
4071
4071
|
return state_7.folders.currentFolderUnfiled;
|
|
4072
4072
|
}
|
|
4073
|
-
function
|
|
4073
|
+
function _temp10(item) {
|
|
4074
4074
|
return item.type === "dialogAllAssets";
|
|
4075
4075
|
}
|
|
4076
|
-
function
|
|
4077
|
-
let dialog = state_8.dialog.items.find(
|
|
4076
|
+
function _temp11(state_8) {
|
|
4077
|
+
let dialog = state_8.dialog.items.find(_temp10);
|
|
4078
4078
|
return dialog?.type === "dialogAllAssets" ? dialog.assetId : void 0;
|
|
4079
4079
|
}
|
|
4080
|
-
function
|
|
4080
|
+
function _temp12(item_0) {
|
|
4081
4081
|
return item_0.type === "dialogAllAssets";
|
|
4082
4082
|
}
|
|
4083
4083
|
const DialogAllAssets = (props) => {
|
|
@@ -4172,7 +4172,7 @@ const DialogAllAssets = (props) => {
|
|
|
4172
4172
|
children: [t8, children]
|
|
4173
4173
|
}), $[25] = children, $[26] = handleClose, $[27] = t4, $[28] = t5, $[29] = t8, $[30] = t9) : t9 = $[30], t9;
|
|
4174
4174
|
}, DialogFolderCreate = (props) => {
|
|
4175
|
-
let $ = c(43), { children, dialog: t0 } = props, { parentFolderId, id } = t0, dispatch = useDispatch(), creating = useTypedSelector(_temp$
|
|
4175
|
+
let $ = c(43), { children, dialog: t0 } = props, { parentFolderId, id } = t0, dispatch = useDispatch(), creating = useTypedSelector(_temp$32), creatingError = useTypedSelector(_temp2$18), t1;
|
|
4176
4176
|
$[0] === parentFolderId ? t1 = $[1] : (t1 = (state_1) => selectFolderPathById(state_1, parentFolderId), $[0] = parentFolderId, $[1] = t1);
|
|
4177
4177
|
let parentPath = useTypedSelector(t1), t2;
|
|
4178
4178
|
$[2] === Symbol.for("react.memo_cache_sentinel") ? (t2 = { name: "" }, $[2] = t2) : t2 = $[2];
|
|
@@ -4261,10 +4261,10 @@ const DialogAllAssets = (props) => {
|
|
|
4261
4261
|
children: [t17, children]
|
|
4262
4262
|
}), $[37] = children, $[38] = handleClose, $[39] = id, $[40] = t10, $[41] = t17, $[42] = t18) : t18 = $[42], t18;
|
|
4263
4263
|
};
|
|
4264
|
-
function _temp$
|
|
4264
|
+
function _temp$32(state) {
|
|
4265
4265
|
return state.folders.creating;
|
|
4266
4266
|
}
|
|
4267
|
-
function _temp2$
|
|
4267
|
+
function _temp2$18(state_0) {
|
|
4268
4268
|
return state_0.folders.creatingError;
|
|
4269
4269
|
}
|
|
4270
4270
|
const getExpandedIdSet$1 = (folderId, byId) => {
|
|
@@ -4314,7 +4314,7 @@ const getExpandedIdSet$1 = (folderId, byId) => {
|
|
|
4314
4314
|
children: t1
|
|
4315
4315
|
}), $[9] = t1, $[10] = t2), t2;
|
|
4316
4316
|
}, DialogFolderMove = (t0) => {
|
|
4317
|
-
let $ = c(49), { children, dialog } = t0, dispatch = useDispatch(), folderTree = useTypedSelector(selectFolderTree), byId = useTypedSelector(_temp$
|
|
4317
|
+
let $ = c(49), { children, dialog } = t0, dispatch = useDispatch(), folderTree = useTypedSelector(selectFolderTree), byId = useTypedSelector(_temp$31), { assets, folderId, id } = dialog, [selectedId, setSelectedId] = useState(folderId || null), selectedFolder = selectedId ? byId[selectedId] : null, t1 = folderId || null, t2;
|
|
4318
4318
|
$[0] !== byId || $[1] !== t1 ? (t2 = getExpandedIdSet$1(t1, byId), $[0] = byId, $[1] = t1, $[2] = t2) : t2 = $[2];
|
|
4319
4319
|
let expandedIds = t2, t3;
|
|
4320
4320
|
$[3] !== dispatch || $[4] !== id ? (t3 = () => {
|
|
@@ -4427,11 +4427,11 @@ const getExpandedIdSet$1 = (folderId, byId) => {
|
|
|
4427
4427
|
children: [t20, children]
|
|
4428
4428
|
}), $[43] = children, $[44] = handleClose, $[45] = id, $[46] = t11, $[47] = t20, $[48] = t21) : t21 = $[48], t21;
|
|
4429
4429
|
};
|
|
4430
|
-
function _temp$
|
|
4430
|
+
function _temp$31(state) {
|
|
4431
4431
|
return state.folders.byId;
|
|
4432
4432
|
}
|
|
4433
4433
|
const DialogFolderRename = (t0) => {
|
|
4434
|
-
let $ = c(50), { children, dialog } = t0, { folderId, id } = dialog, dispatch = useDispatch(), renaming = useTypedSelector(_temp$
|
|
4434
|
+
let $ = c(50), { children, dialog } = t0, { folderId, id } = dialog, dispatch = useDispatch(), renaming = useTypedSelector(_temp$30), renameError = useTypedSelector(_temp2$17), t1;
|
|
4435
4435
|
$[0] === folderId ? t1 = $[1] : (t1 = (state_1) => state_1.folders.byId[folderId], $[0] = folderId, $[1] = t1);
|
|
4436
4436
|
let folder = useTypedSelector(t1), t2;
|
|
4437
4437
|
$[2] === folderId ? t2 = $[3] : (t2 = (state_2) => selectFolderPathById(state_2, folderId), $[2] = folderId, $[3] = t2);
|
|
@@ -4526,10 +4526,10 @@ const DialogFolderRename = (t0) => {
|
|
|
4526
4526
|
children: [t22, children]
|
|
4527
4527
|
}), $[44] = children, $[45] = handleClose, $[46] = id, $[47] = t14, $[48] = t22, $[49] = t23) : t23 = $[49], t23;
|
|
4528
4528
|
};
|
|
4529
|
-
function _temp$
|
|
4529
|
+
function _temp$30(state) {
|
|
4530
4530
|
return state.folders.renaming;
|
|
4531
4531
|
}
|
|
4532
|
-
function _temp2$
|
|
4532
|
+
function _temp2$17(state_0) {
|
|
4533
4533
|
return state_0.folders.renameError;
|
|
4534
4534
|
}
|
|
4535
4535
|
const getExpandedIdSet = (folderId, byId) => {
|
|
@@ -4658,7 +4658,7 @@ const getExpandedIdSet = (folderId, byId) => {
|
|
|
4658
4658
|
children: t5
|
|
4659
4659
|
}), $[15] = node.id, $[16] = selected, $[17] = t1, $[18] = t2, $[19] = t3, $[20] = t4, $[21] = t5, $[22] = t6) : t6 = $[22], t6;
|
|
4660
4660
|
}, FolderView = () => {
|
|
4661
|
-
let $ = c(63), dispatch = useDispatch(), currentFolderId = useTypedSelector(_temp$
|
|
4661
|
+
let $ = c(63), dispatch = useDispatch(), currentFolderId = useTypedSelector(_temp$29), byId = useTypedSelector(_temp2$16), canDeleteFolder = useTypedSelector(selectCanDeleteFolder), fetching = useTypedSelector(_temp3$8), folderTree = useTypedSelector(selectFolderTree), currentFolder = currentFolderId ? byId[currentFolderId] : null, t0;
|
|
4662
4662
|
$[0] !== byId || $[1] !== currentFolderId ? (t0 = getExpandedIdSet(currentFolderId, byId), $[0] = byId, $[1] = currentFolderId, $[2] = t0) : t0 = $[2];
|
|
4663
4663
|
let expandedIds = t0, t1;
|
|
4664
4664
|
$[3] === expandedIds ? t1 = $[4] : (t1 = Array.from(expandedIds).join("|") || "root", $[3] = expandedIds, $[4] = t1);
|
|
@@ -4786,13 +4786,13 @@ const getExpandedIdSet = (folderId, byId) => {
|
|
|
4786
4786
|
children: [t13, t21]
|
|
4787
4787
|
}), $[60] = t13, $[61] = t21, $[62] = t22) : t22 = $[62], t22;
|
|
4788
4788
|
};
|
|
4789
|
-
function _temp$
|
|
4789
|
+
function _temp$29(state) {
|
|
4790
4790
|
return state.folders.currentFolderId;
|
|
4791
4791
|
}
|
|
4792
|
-
function _temp2$
|
|
4792
|
+
function _temp2$16(state_0) {
|
|
4793
4793
|
return state_0.folders.byId;
|
|
4794
4794
|
}
|
|
4795
|
-
function _temp3$
|
|
4795
|
+
function _temp3$8(state_1) {
|
|
4796
4796
|
return state_1.folders.fetching;
|
|
4797
4797
|
}
|
|
4798
4798
|
const DialogFolders = (props) => {
|
|
@@ -4819,7 +4819,7 @@ const DialogFolders = (props) => {
|
|
|
4819
4819
|
}), $[3] = children, $[4] = handleClose, $[5] = id, $[6] = t3) : t3 = $[6], t3;
|
|
4820
4820
|
}, Container$1 = /* @__PURE__ */ styled(Box).withConfig({
|
|
4821
4821
|
displayName: "Container",
|
|
4822
|
-
componentId: "sc-
|
|
4822
|
+
componentId: "sc-ash7y6-0"
|
|
4823
4823
|
})(({ $scheme, theme }) => css`background:${getSchemeColor($scheme, "bg")};border-radius:${rem(theme.sanity.radius[2])};`), SearchFacet = (props) => {
|
|
4824
4824
|
let $ = c(22), { children, facet } = props, scheme = useColorSchemeValue(), dispatch = useDispatch(), t0;
|
|
4825
4825
|
$[0] !== dispatch || $[1] !== facet.id ? (t0 = () => {
|
|
@@ -5288,9 +5288,9 @@ const DialogFolders = (props) => {
|
|
|
5288
5288
|
Option,
|
|
5289
5289
|
SingleValue
|
|
5290
5290
|
}, SearchFacetTags = (t0) => {
|
|
5291
|
-
let $ = c(27), { facet } = t0, scheme = useColorSchemeValue(), dispatch = useDispatch(), { excludeTagSlugs } = useToolOptions(), tagsAll = useTypedSelector(_temp$
|
|
5291
|
+
let $ = c(27), { facet } = t0, scheme = useColorSchemeValue(), dispatch = useDispatch(), { excludeTagSlugs } = useToolOptions(), tagsAll = useTypedSelector(_temp$28), t1;
|
|
5292
5292
|
$[0] !== excludeTagSlugs || $[1] !== tagsAll ? (t1 = excludeTagSlugs.length > 0 ? tagsAll.filter((t) => !excludeTagSlugs.includes(t.tag.name.current)) : tagsAll, $[0] = excludeTagSlugs, $[1] = tagsAll, $[2] = t1) : t1 = $[2];
|
|
5293
|
-
let tags = t1, tagsFetching = useTypedSelector(_temp2$
|
|
5293
|
+
let tags = t1, tagsFetching = useTypedSelector(_temp2$15), t2;
|
|
5294
5294
|
$[3] === tags ? t2 = $[4] : (t2 = getTagSelectOptions(tags), $[3] = tags, $[4] = t2);
|
|
5295
5295
|
let allTagOptions = t2, popoverProps = usePortalPopoverProps(), t3;
|
|
5296
5296
|
$[5] !== dispatch || $[6] !== facet.id ? (t3 = (option) => {
|
|
@@ -5337,7 +5337,7 @@ const DialogFolders = (props) => {
|
|
|
5337
5337
|
isDisabled: tagsFetching,
|
|
5338
5338
|
isSearchable: !0,
|
|
5339
5339
|
name: "tags",
|
|
5340
|
-
noOptionsMessage: _temp3$
|
|
5340
|
+
noOptionsMessage: _temp3$7,
|
|
5341
5341
|
onChange: (value) => handleChange(value),
|
|
5342
5342
|
options: allTagOptions,
|
|
5343
5343
|
placeholder: tagsFetching ? "Loading..." : "Select...",
|
|
@@ -5351,21 +5351,21 @@ const DialogFolders = (props) => {
|
|
|
5351
5351
|
children: [t5, t6]
|
|
5352
5352
|
}), $[23] = facet, $[24] = t5, $[25] = t6, $[26] = t7) : t7 = $[26], t7;
|
|
5353
5353
|
};
|
|
5354
|
-
function _temp$
|
|
5354
|
+
function _temp$28(state) {
|
|
5355
5355
|
return selectTags(state);
|
|
5356
5356
|
}
|
|
5357
|
-
function _temp2$
|
|
5357
|
+
function _temp2$15(state_0) {
|
|
5358
5358
|
return state_0.tags.fetching;
|
|
5359
5359
|
}
|
|
5360
|
-
function _temp3$
|
|
5360
|
+
function _temp3$7() {
|
|
5361
5361
|
return "No tags";
|
|
5362
5362
|
}
|
|
5363
5363
|
const StackContainer = /* @__PURE__ */ styled(Flex).withConfig({
|
|
5364
5364
|
displayName: "StackContainer",
|
|
5365
|
-
componentId: "sc-
|
|
5365
|
+
componentId: "sc-2rtdyq-0"
|
|
5366
5366
|
})(({ theme }) => css`> *{margin-bottom:${rem(theme.sanity.space[2])};}`), SearchFacets = (props) => {
|
|
5367
|
-
let $ = c(6), { layout: t0 } = props, layout = t0 === void 0 ? "inline" : t0, searchFacets = useTypedSelector(_temp$
|
|
5368
|
-
$[0] === searchFacets ? t1 = $[1] : (t1 = searchFacets.map(_temp2$
|
|
5367
|
+
let $ = c(6), { layout: t0 } = props, layout = t0 === void 0 ? "inline" : t0, searchFacets = useTypedSelector(_temp$27), t1;
|
|
5368
|
+
$[0] === searchFacets ? t1 = $[1] : (t1 = searchFacets.map(_temp2$14), $[0] = searchFacets, $[1] = t1);
|
|
5369
5369
|
let Items = t1;
|
|
5370
5370
|
if (layout === "inline") {
|
|
5371
5371
|
if (searchFacets.length === 0) return null;
|
|
@@ -5388,15 +5388,15 @@ const StackContainer = /* @__PURE__ */ styled(Flex).withConfig({
|
|
|
5388
5388
|
}
|
|
5389
5389
|
throw Error("Invalid layout");
|
|
5390
5390
|
};
|
|
5391
|
-
function _temp$
|
|
5391
|
+
function _temp$27(state) {
|
|
5392
5392
|
return state.search.facets;
|
|
5393
5393
|
}
|
|
5394
|
-
function _temp2$
|
|
5394
|
+
function _temp2$14(facet) {
|
|
5395
5395
|
let key = facet.id;
|
|
5396
5396
|
return facet.type === "number" ? /* @__PURE__ */ jsx(SearchFacetNumber, { facet }, key) : facet.type === "searchable" ? /* @__PURE__ */ jsx(SearchFacetTags, { facet }, key) : facet.type === "select" ? /* @__PURE__ */ jsx(SearchFacetSelect, { facet }, key) : facet.type === "string" ? /* @__PURE__ */ jsx(SearchFacetString, { facet }, key) : null;
|
|
5397
5397
|
}
|
|
5398
5398
|
const SearchFacetsControl = () => {
|
|
5399
|
-
let $ = c(35), dispatch = useDispatch(), assetTypes = useTypedSelector(_temp$
|
|
5399
|
+
let $ = c(35), dispatch = useDispatch(), assetTypes = useTypedSelector(_temp$26), searchFacets = useTypedSelector(_temp2$13), selectedDocument = useTypedSelector(_temp3$6), popoverProps = usePortalPopoverProps(), { creditLine } = useToolOptions(), isTool = !selectedDocument, T0, T1, T2, t0, t1, t2;
|
|
5400
5400
|
if ($[0] !== assetTypes || $[1] !== creditLine?.enabled || $[2] !== dispatch || $[3] !== isTool || $[4] !== searchFacets) {
|
|
5401
5401
|
let t3;
|
|
5402
5402
|
$[11] !== assetTypes || $[12] !== creditLine?.enabled || $[13] !== isTool ? (t3 = (facet) => !creditLine?.enabled && facet?.type === "string" && facet?.name === "creditLine" ? !1 : facet.type === "group" || facet.type === "divider" ? !0 : isTool ? !facet?.selectOnly : facet.assetTypes.filter((assetType) => assetTypes.includes(assetType)).length > 0, $[11] = assetTypes, $[12] = creditLine?.enabled, $[13] = isTool, $[14] = t3) : t3 = $[14];
|
|
@@ -5458,13 +5458,13 @@ const SearchFacetsControl = () => {
|
|
|
5458
5458
|
let t7;
|
|
5459
5459
|
return $[31] !== T2 || $[32] !== t5 || $[33] !== t6 ? (t7 = /* @__PURE__ */ jsxs(T2, { children: [t5, t6] }), $[31] = T2, $[32] = t5, $[33] = t6, $[34] = t7) : t7 = $[34], t7;
|
|
5460
5460
|
};
|
|
5461
|
-
function _temp$
|
|
5461
|
+
function _temp$26(state) {
|
|
5462
5462
|
return state.assets.assetTypes;
|
|
5463
5463
|
}
|
|
5464
|
-
function _temp2$
|
|
5464
|
+
function _temp2$13(state_0) {
|
|
5465
5465
|
return state_0.search.facets;
|
|
5466
5466
|
}
|
|
5467
|
-
function _temp3$
|
|
5467
|
+
function _temp3$6(state_1) {
|
|
5468
5468
|
return state_1.selected.document;
|
|
5469
5469
|
}
|
|
5470
5470
|
function _temp4$3(facet_0, index, facets) {
|
|
@@ -5491,7 +5491,7 @@ const DialogSearchFacets = (props) => {
|
|
|
5491
5491
|
children: [t2, children]
|
|
5492
5492
|
}), $[3] = children, $[4] = handleClose, $[5] = id, $[6] = t3) : t3 = $[6], t3;
|
|
5493
5493
|
}, DialogTagCreate = (props) => {
|
|
5494
|
-
let $ = c(37), { children, dialog: t0 } = props, { id } = t0, dispatch = useDispatch(), creating = useTypedSelector(_temp$
|
|
5494
|
+
let $ = c(37), { children, dialog: t0 } = props, { id } = t0, dispatch = useDispatch(), creating = useTypedSelector(_temp$25), creatingError = useTypedSelector(_temp2$12), t1;
|
|
5495
5495
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t1 = { name: "" }, $[0] = t1) : t1 = $[0];
|
|
5496
5496
|
let t2;
|
|
5497
5497
|
$[1] === Symbol.for("react.memo_cache_sentinel") ? (t2 = {
|
|
@@ -5562,16 +5562,16 @@ const DialogSearchFacets = (props) => {
|
|
|
5562
5562
|
children: [t15, children]
|
|
5563
5563
|
}), $[31] = children, $[32] = handleClose, $[33] = id, $[34] = t15, $[35] = t9, $[36] = t16) : t16 = $[36], t16;
|
|
5564
5564
|
};
|
|
5565
|
-
function _temp$
|
|
5565
|
+
function _temp$25(state) {
|
|
5566
5566
|
return state.tags.creating;
|
|
5567
5567
|
}
|
|
5568
|
-
function _temp2$
|
|
5568
|
+
function _temp2$12(state_0) {
|
|
5569
5569
|
return state_0.tags.creatingError;
|
|
5570
5570
|
}
|
|
5571
5571
|
const DialogTagEdit = (props) => {
|
|
5572
5572
|
let $ = c(64), { children, dialog: t0 } = props, { id, tagId } = t0, client = useVersionedClient(), dispatch = useDispatch(), t1;
|
|
5573
5573
|
$[0] === tagId ? t1 = $[1] : (t1 = (state) => selectTagById(state, String(tagId)), $[0] = tagId, $[1] = t1);
|
|
5574
|
-
let tagItem = useTypedSelector(t1), [tagSnapshot, setTagSnapshot] = useState(tagItem?.tag), currentTag = tagItem ? tagItem?.tag : tagSnapshot, generateDefaultValues = _temp$
|
|
5574
|
+
let tagItem = useTypedSelector(t1), [tagSnapshot, setTagSnapshot] = useState(tagItem?.tag), currentTag = tagItem ? tagItem?.tag : tagSnapshot, generateDefaultValues = _temp$24, t2 = tagItem?.tag, t3;
|
|
5575
5575
|
$[2] === t2 ? t3 = $[3] : (t3 = generateDefaultValues(t2), $[2] = t2, $[3] = t3);
|
|
5576
5576
|
let t4;
|
|
5577
5577
|
$[4] === Symbol.for("react.memo_cache_sentinel") ? (t4 = zodFormResolver(tagFormSchema), $[4] = t4) : t4 = $[4];
|
|
@@ -5706,15 +5706,15 @@ const DialogTagEdit = (props) => {
|
|
|
5706
5706
|
children: [t25, children]
|
|
5707
5707
|
}), $[58] = children, $[59] = handleClose, $[60] = id, $[61] = t18, $[62] = t25, $[63] = t26) : t26 = $[63], t26;
|
|
5708
5708
|
};
|
|
5709
|
-
function _temp$
|
|
5709
|
+
function _temp$24(tag) {
|
|
5710
5710
|
return { name: tag?.name?.current || "" };
|
|
5711
5711
|
}
|
|
5712
5712
|
const TagContainer = styled(Flex).withConfig({
|
|
5713
5713
|
displayName: "TagContainer",
|
|
5714
|
-
componentId: "sc-
|
|
5714
|
+
componentId: "sc-3v39jc-0"
|
|
5715
5715
|
})`height:${32}px;`, ButtonContainer = styled(Flex).withConfig({
|
|
5716
5716
|
displayName: "ButtonContainer",
|
|
5717
|
-
componentId: "sc-
|
|
5717
|
+
componentId: "sc-3v39jc-1"
|
|
5718
5718
|
})`@media (pointer:fine){visibility:hidden;}@media (hover:hover) and (pointer:fine){${TagContainer}:hover &{visibility:visible;}}`, TagButton = (props) => {
|
|
5719
5719
|
let $ = c(10), { disabled, icon, onClick, tone, tooltip } = props, t0;
|
|
5720
5720
|
$[0] === tooltip ? t0 = $[1] : (t0 = /* @__PURE__ */ jsx(Container, {
|
|
@@ -5893,12 +5893,12 @@ const TagContainer = styled(Flex).withConfig({
|
|
|
5893
5893
|
}), TagsVirtualized = (t0) => {
|
|
5894
5894
|
let $ = c(15), { tags } = t0, assetsPicked = useTypedSelector(selectAssetsPicked), [isScrolling, setIsScrolling] = useState(!1), items;
|
|
5895
5895
|
if ($[0] !== assetsPicked || $[1] !== tags) {
|
|
5896
|
-
let pickedTagIds = assetsPicked?.reduce(_temp2$
|
|
5896
|
+
let pickedTagIds = assetsPicked?.reduce(_temp2$11, []), pickedTagIdsUnique = [...new Set(pickedTagIds)], t1;
|
|
5897
5897
|
$[3] === assetsPicked ? t1 = $[4] : (t1 = (acc_0, tagId) => (assetsPicked.every((assetItem) => (assetItem.asset.opt?.media?.tags?.findIndex((tag_0) => tag_0._ref === tagId) ?? -1) >= 0) ? acc_0.appliedToAll.push(tagId) : acc_0.appliedToSome.push(tagId), acc_0), $[3] = assetsPicked, $[4] = t1);
|
|
5898
5898
|
let tagIdsSegmented = pickedTagIdsUnique.reduce(t1, {
|
|
5899
5899
|
appliedToAll: [],
|
|
5900
5900
|
appliedToSome: []
|
|
5901
|
-
}), tagsAppliedToAll = tags.filter((tag_1) => tagIdsSegmented.appliedToAll.includes(tag_1.tag._id)).map(_temp3$
|
|
5901
|
+
}), tagsAppliedToAll = tags.filter((tag_1) => tagIdsSegmented.appliedToAll.includes(tag_1.tag._id)).map(_temp3$5), tagsAppliedToSome = tags.filter((tag_2) => tagIdsSegmented.appliedToSome.includes(tag_2.tag._id)).map(_temp4$2), tagsUnused = tags.filter((tag_3) => !pickedTagIdsUnique.includes(tag_3.tag._id)).map(_temp5$2);
|
|
5902
5902
|
items = [], assetsPicked.length === 0 ? items = tags.map(_temp6) : (tagsAppliedToAll?.length > 0 && (items = [
|
|
5903
5903
|
...items,
|
|
5904
5904
|
assetsPicked.length === 1 ? "Used" : "Used by all",
|
|
@@ -5938,14 +5938,14 @@ const TagContainer = styled(Flex).withConfig({
|
|
|
5938
5938
|
totalCount: items.length
|
|
5939
5939
|
}), $[11] = items.length, $[12] = t1, $[13] = t2, $[14] = t4) : t4 = $[14], t4;
|
|
5940
5940
|
};
|
|
5941
|
-
function _temp$
|
|
5941
|
+
function _temp$23(tag) {
|
|
5942
5942
|
return tag._ref;
|
|
5943
5943
|
}
|
|
5944
|
-
function _temp2$
|
|
5945
|
-
let assetTagIds = val?.asset?.opt?.media?.tags?.map(_temp$
|
|
5944
|
+
function _temp2$11(acc, val) {
|
|
5945
|
+
let assetTagIds = val?.asset?.opt?.media?.tags?.map(_temp$23) || [];
|
|
5946
5946
|
return acc = acc.concat(assetTagIds), acc;
|
|
5947
5947
|
}
|
|
5948
|
-
function _temp3$
|
|
5948
|
+
function _temp3$5(tagItem) {
|
|
5949
5949
|
return {
|
|
5950
5950
|
...tagItem,
|
|
5951
5951
|
actions: [
|
|
@@ -5990,7 +5990,7 @@ function _temp6(tagItem_2) {
|
|
|
5990
5990
|
};
|
|
5991
5991
|
}
|
|
5992
5992
|
const TagViewHeader = (t0) => {
|
|
5993
|
-
let $ = c(22), { allowCreate, light, title } = t0, scheme = useColorSchemeValue(), dispatch = useDispatch(), tagsCreating = useTypedSelector(_temp$
|
|
5993
|
+
let $ = c(22), { allowCreate, light, title } = t0, scheme = useColorSchemeValue(), dispatch = useDispatch(), tagsCreating = useTypedSelector(_temp$22), tagsFetching = useTypedSelector(_temp2$10), t1;
|
|
5994
5994
|
$[0] === dispatch ? t1 = $[1] : (t1 = () => {
|
|
5995
5995
|
dispatch(DIALOG_ACTIONS.showTagCreate());
|
|
5996
5996
|
}, $[0] = dispatch, $[1] = t1);
|
|
@@ -6043,16 +6043,16 @@ const TagViewHeader = (t0) => {
|
|
|
6043
6043
|
children: [t6, t7]
|
|
6044
6044
|
}) }), $[18] = t3, $[19] = t6, $[20] = t7, $[21] = t8) : t8 = $[21], t8;
|
|
6045
6045
|
};
|
|
6046
|
-
function _temp$
|
|
6046
|
+
function _temp$22(state) {
|
|
6047
6047
|
return state.tags.creating;
|
|
6048
6048
|
}
|
|
6049
|
-
function _temp2$
|
|
6049
|
+
function _temp2$10(state_0) {
|
|
6050
6050
|
return state_0.tags.fetching;
|
|
6051
6051
|
}
|
|
6052
6052
|
const TagView = () => {
|
|
6053
6053
|
let $ = c(16), numPickedAssets = useTypedSelector(selectAssetsPickedLength), { excludeTagSlugs } = useToolOptions(), tagsAll = useTypedSelector(selectTags), t0;
|
|
6054
6054
|
$[0] !== excludeTagSlugs || $[1] !== tagsAll ? (t0 = excludeTagSlugs.length > 0 ? tagsAll.filter((t) => !excludeTagSlugs.includes(t.tag.name.current)) : tagsAll, $[0] = excludeTagSlugs, $[1] = tagsAll, $[2] = t0) : t0 = $[2];
|
|
6055
|
-
let tags = t0, fetching = useTypedSelector(_temp$
|
|
6055
|
+
let tags = t0, fetching = useTypedSelector(_temp$21), fetchComplete = useTypedSelector(_temp2$9) !== -1, hasTags = !fetching && tags?.length > 0, hasPicked = numPickedAssets > 0, t1 = hasPicked ? "Tags (in selection)" : "Tags", t2;
|
|
6056
6056
|
$[3] !== hasPicked || $[4] !== t1 ? (t2 = /* @__PURE__ */ jsx(TagViewHeader, {
|
|
6057
6057
|
allowCreate: !0,
|
|
6058
6058
|
light: hasPicked,
|
|
@@ -6081,10 +6081,10 @@ const TagView = () => {
|
|
|
6081
6081
|
]
|
|
6082
6082
|
}), $[12] = t2, $[13] = t3, $[14] = t4, $[15] = t5) : t5 = $[15], t5;
|
|
6083
6083
|
};
|
|
6084
|
-
function _temp$
|
|
6084
|
+
function _temp$21(state) {
|
|
6085
6085
|
return state.tags.fetching;
|
|
6086
6086
|
}
|
|
6087
|
-
function _temp2$
|
|
6087
|
+
function _temp2$9(state_0) {
|
|
6088
6088
|
return state_0.tags.fetchCount;
|
|
6089
6089
|
}
|
|
6090
6090
|
const DialogTags = (props) => {
|
|
@@ -6110,7 +6110,7 @@ const DialogTags = (props) => {
|
|
|
6110
6110
|
children: [t2, children]
|
|
6111
6111
|
}), $[3] = children, $[4] = handleClose, $[5] = id, $[6] = t3) : t3 = $[6], t3;
|
|
6112
6112
|
}, Dialogs = () => {
|
|
6113
|
-
let $ = c(2), currentDialogs = useTypedSelector(_temp$
|
|
6113
|
+
let $ = c(2), currentDialogs = useTypedSelector(_temp$20), t0;
|
|
6114
6114
|
if ($[0] !== currentDialogs) {
|
|
6115
6115
|
let renderDialogs = (dialogs, index) => {
|
|
6116
6116
|
if (dialogs.length === 0 || index >= dialogs.length) return null;
|
|
@@ -6154,11 +6154,11 @@ const DialogTags = (props) => {
|
|
|
6154
6154
|
} else t0 = $[1];
|
|
6155
6155
|
return t0;
|
|
6156
6156
|
};
|
|
6157
|
-
function _temp$
|
|
6157
|
+
function _temp$20(state) {
|
|
6158
6158
|
return state.dialog.items;
|
|
6159
6159
|
}
|
|
6160
6160
|
const Notifications = () => {
|
|
6161
|
-
let $ = c(4), items = useTypedSelector(_temp$
|
|
6161
|
+
let $ = c(4), items = useTypedSelector(_temp$19), toast = useToast(), t0, t1;
|
|
6162
6162
|
return $[0] !== items || $[1] !== toast ? (t0 = () => {
|
|
6163
6163
|
if (items.length > 0) {
|
|
6164
6164
|
let lastItem = items[items.length - 1];
|
|
@@ -6170,7 +6170,7 @@ const Notifications = () => {
|
|
|
6170
6170
|
}
|
|
6171
6171
|
}, t1 = [items, toast], $[0] = items, $[1] = toast, $[2] = t0, $[3] = t1) : (t0 = $[2], t1 = $[3]), useEffect(t0, t1), null;
|
|
6172
6172
|
};
|
|
6173
|
-
function _temp$
|
|
6173
|
+
function _temp$19(state) {
|
|
6174
6174
|
return state.notifications.items;
|
|
6175
6175
|
}
|
|
6176
6176
|
const debugSlice = createSlice({
|
|
@@ -6377,7 +6377,7 @@ function ReduxProvider(t0) {
|
|
|
6377
6377
|
* a second time.
|
|
6378
6378
|
*/
|
|
6379
6379
|
const EditAssetDialog = (t0) => {
|
|
6380
|
-
let $ = c(9), { assetId, onClose } = t0, dispatch = useDispatch(), openDialogCount = useTypedSelector(_temp$
|
|
6380
|
+
let $ = c(9), { assetId, onClose } = t0, dispatch = useDispatch(), openDialogCount = useTypedSelector(_temp$18), hasOpenedRef = useRef(!1), t1, t2;
|
|
6381
6381
|
$[0] !== assetId || $[1] !== dispatch ? (t1 = () => {
|
|
6382
6382
|
let queryFilter = `${constructFilter({
|
|
6383
6383
|
assetTypes: ["file", "image"],
|
|
@@ -6427,11 +6427,11 @@ const EditAssetDialog = (t0) => {
|
|
|
6427
6427
|
children: t7
|
|
6428
6428
|
}), $[15] = client, $[16] = props.assetType, $[17] = selectedAssets, $[18] = t3, $[19] = t7, $[20] = t8) : t8 = $[20], t8;
|
|
6429
6429
|
};
|
|
6430
|
-
function _temp$
|
|
6430
|
+
function _temp$18(state) {
|
|
6431
6431
|
return state.dialog.items.length;
|
|
6432
6432
|
}
|
|
6433
6433
|
const ButtonViewGroup = () => {
|
|
6434
|
-
let $ = c(16), dispatch = useDispatch(), view = useTypedSelector(_temp$
|
|
6434
|
+
let $ = c(16), dispatch = useDispatch(), view = useTypedSelector(_temp$17), t0;
|
|
6435
6435
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = { whiteSpace: "nowrap" }, $[0] = t0) : t0 = $[0];
|
|
6436
6436
|
let t1 = view === "grid" ? "default" : "ghost", t2;
|
|
6437
6437
|
$[1] === dispatch ? t2 = $[2] : (t2 = () => dispatch(assetsActions.viewSet({ view: "grid" })), $[1] = dispatch, $[2] = t2);
|
|
@@ -6470,11 +6470,11 @@ const ButtonViewGroup = () => {
|
|
|
6470
6470
|
children: [t4, t8]
|
|
6471
6471
|
}), $[13] = t4, $[14] = t8, $[15] = t9) : t9 = $[15], t9;
|
|
6472
6472
|
};
|
|
6473
|
-
function _temp$
|
|
6473
|
+
function _temp$17(state) {
|
|
6474
6474
|
return state.assets.view;
|
|
6475
6475
|
}
|
|
6476
6476
|
const OrderSelect = () => {
|
|
6477
|
-
let $ = c(15), dispatch = useDispatch(), order = useTypedSelector(_temp$
|
|
6477
|
+
let $ = c(15), dispatch = useDispatch(), order = useTypedSelector(_temp$16), popoverProps = usePortalPopoverProps(), t0;
|
|
6478
6478
|
$[0] !== order.direction || $[1] !== order.field ? (t0 = getOrderTitle(order.field, order.direction), $[0] = order.direction, $[1] = order.field, $[2] = t0) : t0 = $[2];
|
|
6479
6479
|
let t1;
|
|
6480
6480
|
$[3] === t0 ? t1 = $[4] : (t1 = /* @__PURE__ */ jsx(Button, {
|
|
@@ -6515,7 +6515,7 @@ const OrderSelect = () => {
|
|
|
6515
6515
|
popover: popoverProps
|
|
6516
6516
|
}), $[11] = popoverProps, $[12] = t1, $[13] = t3, $[14] = t4) : t4 = $[14], t4;
|
|
6517
6517
|
};
|
|
6518
|
-
function _temp$
|
|
6518
|
+
function _temp$16(state) {
|
|
6519
6519
|
return state.assets.order;
|
|
6520
6520
|
}
|
|
6521
6521
|
const Progress = (props) => {
|
|
@@ -6563,7 +6563,7 @@ const Progress = (props) => {
|
|
|
6563
6563
|
}), /* @__PURE__ */ jsx("path", { d: "M384 160a32 32 0 1132-32 32 32 0 01-32 32z" })]
|
|
6564
6564
|
}), $[0] = t0) : t0 = $[0], t0;
|
|
6565
6565
|
}, TextInputSearch = () => {
|
|
6566
|
-
let $ = c(14), searchQuery = useTypedSelector(_temp$
|
|
6566
|
+
let $ = c(14), searchQuery = useTypedSelector(_temp$15), dispatch = useDispatch(), t0;
|
|
6567
6567
|
$[0] === dispatch ? t0 = $[1] : (t0 = (e) => {
|
|
6568
6568
|
dispatch(searchActions.querySet({ searchQuery: e.currentTarget.value }));
|
|
6569
6569
|
}, $[0] = dispatch, $[1] = t0);
|
|
@@ -6605,11 +6605,11 @@ const Progress = (props) => {
|
|
|
6605
6605
|
children: [t3, t4]
|
|
6606
6606
|
}), $[11] = t3, $[12] = t4, $[13] = t5) : t5 = $[13], t5;
|
|
6607
6607
|
};
|
|
6608
|
-
function _temp$
|
|
6608
|
+
function _temp$15(state) {
|
|
6609
6609
|
return state.search.query;
|
|
6610
6610
|
}
|
|
6611
6611
|
const Controls = () => {
|
|
6612
|
-
let $ = c(62), dispatch = useDispatch(), fetching = useTypedSelector(_temp$
|
|
6612
|
+
let $ = c(62), dispatch = useDispatch(), fetching = useTypedSelector(_temp$14), foldersPanelVisible = useTypedSelector(_temp2$8), pageIndex = useTypedSelector(_temp3$4), searchFacets = useTypedSelector(_temp4$1), tagsPanelVisible = useTypedSelector(_temp5$1), mediaIndex = useMediaIndex(), t0;
|
|
6613
6613
|
$[0] === dispatch ? t0 = $[1] : (t0 = () => {
|
|
6614
6614
|
dispatch(dialogActions.showSearchFacets());
|
|
6615
6615
|
}, $[0] = dispatch, $[1] = t0);
|
|
@@ -6814,13 +6814,13 @@ const Controls = () => {
|
|
|
6814
6814
|
]
|
|
6815
6815
|
}), $[58] = t20, $[59] = t34, $[60] = t35, $[61] = t36) : t36 = $[61], t36;
|
|
6816
6816
|
};
|
|
6817
|
-
function _temp$
|
|
6817
|
+
function _temp$14(state) {
|
|
6818
6818
|
return state.assets.fetching;
|
|
6819
6819
|
}
|
|
6820
|
-
function _temp2$
|
|
6820
|
+
function _temp2$8(state_0) {
|
|
6821
6821
|
return state_0.folders.panelVisible;
|
|
6822
6822
|
}
|
|
6823
|
-
function _temp3$
|
|
6823
|
+
function _temp3$4(state_1) {
|
|
6824
6824
|
return state_1.assets.pageIndex;
|
|
6825
6825
|
}
|
|
6826
6826
|
function _temp4$1(state_2) {
|
|
@@ -6830,7 +6830,7 @@ function _temp5$1(state_3) {
|
|
|
6830
6830
|
return state_3.tags.panelVisible;
|
|
6831
6831
|
}
|
|
6832
6832
|
const DebugControls = () => {
|
|
6833
|
-
let $ = c(16), dispatch = useDispatch(), badConnection = useTypedSelector(_temp$
|
|
6833
|
+
let $ = c(16), dispatch = useDispatch(), badConnection = useTypedSelector(_temp$13), debugEnabled = useTypedSelector(_temp2$7), t0;
|
|
6834
6834
|
$[0] === dispatch ? t0 = $[1] : (t0 = (e) => {
|
|
6835
6835
|
let checked = e.target.checked;
|
|
6836
6836
|
dispatch(debugActions.setBadConnection(checked));
|
|
@@ -6892,14 +6892,14 @@ const DebugControls = () => {
|
|
|
6892
6892
|
})
|
|
6893
6893
|
}), $[13] = t5, $[14] = t8, $[15] = t9) : t9 = $[15], t9;
|
|
6894
6894
|
};
|
|
6895
|
-
function _temp$
|
|
6895
|
+
function _temp$13(state) {
|
|
6896
6896
|
return state.debug.badConnection;
|
|
6897
6897
|
}
|
|
6898
|
-
function _temp2$
|
|
6898
|
+
function _temp2$7(state_0) {
|
|
6899
6899
|
return state_0.debug.enabled;
|
|
6900
6900
|
}
|
|
6901
6901
|
const FolderBreadcrumbs = () => {
|
|
6902
|
-
let $ = c(13), dispatch = useDispatch(), currentFolderId = useTypedSelector(_temp$
|
|
6902
|
+
let $ = c(13), dispatch = useDispatch(), currentFolderId = useTypedSelector(_temp$12), segments = useTypedSelector(selectCurrentFolderSegments);
|
|
6903
6903
|
if (!currentFolderId) return null;
|
|
6904
6904
|
let t0;
|
|
6905
6905
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = [
|
|
@@ -6943,12 +6943,12 @@ const FolderBreadcrumbs = () => {
|
|
|
6943
6943
|
})
|
|
6944
6944
|
}), $[10] = t1, $[11] = t2, $[12] = t3) : t3 = $[12], t3;
|
|
6945
6945
|
};
|
|
6946
|
-
function _temp$
|
|
6946
|
+
function _temp$12(state) {
|
|
6947
6947
|
return state.folders.currentFolderId;
|
|
6948
6948
|
}
|
|
6949
6949
|
const FolderPanel = () => {
|
|
6950
6950
|
let $ = c(2);
|
|
6951
|
-
if (!useTypedSelector(_temp$
|
|
6951
|
+
if (!useTypedSelector(_temp$11)) return null;
|
|
6952
6952
|
let t0;
|
|
6953
6953
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = {
|
|
6954
6954
|
position: "relative",
|
|
@@ -6973,7 +6973,7 @@ const FolderPanel = () => {
|
|
|
6973
6973
|
})
|
|
6974
6974
|
}), $[1] = t1) : t1 = $[1], t1;
|
|
6975
6975
|
};
|
|
6976
|
-
function _temp$
|
|
6976
|
+
function _temp$11(state) {
|
|
6977
6977
|
return state.folders.panelVisible;
|
|
6978
6978
|
}
|
|
6979
6979
|
const DropzoneDispatchContext = createContext(void 0), DropzoneDispatchProvider = (props) => {
|
|
@@ -6989,7 +6989,7 @@ const DropzoneDispatchContext = createContext(void 0), DropzoneDispatchProvider
|
|
|
6989
6989
|
if (context === void 0) throw Error("useDropzoneActions must be used within an DropzoneDispatchProvider");
|
|
6990
6990
|
return context;
|
|
6991
6991
|
}, Header = (props) => {
|
|
6992
|
-
let $ = c(23), { onClose } = props, { open } = useDropzoneActions(), { onSelect } = useAssetSourceActions(), assetTypes = useTypedSelector(_temp$
|
|
6992
|
+
let $ = c(23), { onClose } = props, { open } = useDropzoneActions(), { onSelect } = useAssetSourceActions(), assetTypes = useTypedSelector(_temp$10), selectedDocument = useTypedSelector(_temp2$6), { directUploads } = useToolOptions(), t0;
|
|
6993
6993
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = { whiteSpace: "nowrap" }, $[0] = t0) : t0 = $[0];
|
|
6994
6994
|
let t1;
|
|
6995
6995
|
$[1] !== assetTypes || $[2] !== onSelect ? (t1 = onSelect ? `Insert ${assetTypes.join(" or ")}` : "Browse Assets", $[1] = assetTypes, $[2] = onSelect, $[3] = t1) : t1 = $[3];
|
|
@@ -7057,14 +7057,14 @@ const DropzoneDispatchContext = createContext(void 0), DropzoneDispatchProvider
|
|
|
7057
7057
|
})
|
|
7058
7058
|
}), $[20] = t4, $[21] = t7, $[22] = t8) : t8 = $[22], t8;
|
|
7059
7059
|
};
|
|
7060
|
-
function _temp$
|
|
7060
|
+
function _temp$10(state) {
|
|
7061
7061
|
return state.assets.assetTypes;
|
|
7062
7062
|
}
|
|
7063
|
-
function _temp2$
|
|
7063
|
+
function _temp2$6(state_0) {
|
|
7064
7064
|
return state_0.selected.document;
|
|
7065
7065
|
}
|
|
7066
7066
|
const TableHeaderItem = (props) => {
|
|
7067
|
-
let $ = c(26), { field, title } = props, dispatch = useDispatch(), order = useTypedSelector(_temp$
|
|
7067
|
+
let $ = c(26), { field, title } = props, dispatch = useDispatch(), order = useTypedSelector(_temp$9), isActive = order.field === field, t0;
|
|
7068
7068
|
$[0] !== dispatch || $[1] !== field || $[2] !== isActive || $[3] !== order.direction || $[4] !== title ? (t0 = () => {
|
|
7069
7069
|
if (!(!field || !title)) {
|
|
7070
7070
|
if (isActive) {
|
|
@@ -7113,14 +7113,14 @@ const TableHeaderItem = (props) => {
|
|
|
7113
7113
|
children: t9
|
|
7114
7114
|
}), $[23] = t1, $[24] = t9, $[25] = t10) : t10 = $[25], t10;
|
|
7115
7115
|
};
|
|
7116
|
-
function _temp$
|
|
7116
|
+
function _temp$9(state) {
|
|
7117
7117
|
return state.assets.order;
|
|
7118
7118
|
}
|
|
7119
7119
|
const ContextActionContainer$1 = /* @__PURE__ */ styled(Flex).withConfig({
|
|
7120
7120
|
displayName: "ContextActionContainer",
|
|
7121
|
-
componentId: "sc-
|
|
7121
|
+
componentId: "sc-r1w061-0"
|
|
7122
7122
|
})(({ $scheme }) => css`cursor:pointer;@media (hover:hover) and (pointer:fine){&:hover{background:${getSchemeColor($scheme, "bg")};}}`), TableHeader = () => {
|
|
7123
|
-
let $ = c(24), scheme = useColorSchemeValue(), dispatch = useDispatch(), fetching = useTypedSelector(_temp$
|
|
7123
|
+
let $ = c(24), scheme = useColorSchemeValue(), dispatch = useDispatch(), fetching = useTypedSelector(_temp$8), itemsLength = useTypedSelector(selectAssetsLength), numPickedAssets = useTypedSelector(selectAssetsPickedLength), mediaIndex = useMediaIndex(), { onSelect } = useAssetSourceActions(), allSelected = numPickedAssets === itemsLength, t0;
|
|
7124
7124
|
$[0] !== allSelected || $[1] !== dispatch ? (t0 = (e) => {
|
|
7125
7125
|
e.stopPropagation(), dispatch(allSelected ? assetsActions.pickClear() : assetsActions.pickAll());
|
|
7126
7126
|
}, $[0] = allSelected, $[1] = dispatch, $[2] = t0) : t0 = $[2];
|
|
@@ -7189,20 +7189,20 @@ const ContextActionContainer$1 = /* @__PURE__ */ styled(Flex).withConfig({
|
|
|
7189
7189
|
]
|
|
7190
7190
|
}), $[21] = t4, $[22] = t5, $[23] = t14) : t14 = $[23], t14;
|
|
7191
7191
|
};
|
|
7192
|
-
function _temp$
|
|
7192
|
+
function _temp$8(state) {
|
|
7193
7193
|
return state.assets.fetching;
|
|
7194
7194
|
}
|
|
7195
7195
|
const ContainerGrid$1 = /* @__PURE__ */ styled(Grid).withConfig({
|
|
7196
7196
|
displayName: "ContainerGrid",
|
|
7197
|
-
componentId: "sc-
|
|
7197
|
+
componentId: "sc-mfq3ng-0"
|
|
7198
7198
|
})(({ $scheme, $selected, $updating }) => css`align-items:center;cursor:${$selected ? "default" : "pointer"};height:100%;pointer-events:${$updating ? "none" : "auto"};user-select:none;white-space:nowrap;${!$updating && css`@media (hover:hover) and (pointer:fine){&:hover{background:${getSchemeColor($scheme, "bg")};}}`}`), ContextActionContainer = /* @__PURE__ */ styled(Flex).withConfig({
|
|
7199
7199
|
displayName: "ContextActionContainer",
|
|
7200
|
-
componentId: "sc-
|
|
7200
|
+
componentId: "sc-mfq3ng-1"
|
|
7201
7201
|
})(({ $scheme }) => css`cursor:pointer;@media (hover:hover) and (pointer:fine){&:hover{background:${getSchemeColor($scheme, "bg2")};}}`), StyledWarningIcon = /* @__PURE__ */ styled(WarningFilledIcon).withConfig({
|
|
7202
7202
|
displayName: "StyledWarningIcon",
|
|
7203
|
-
componentId: "sc-
|
|
7203
|
+
componentId: "sc-mfq3ng-2"
|
|
7204
7204
|
})(({ theme }) => ({ color: theme.sanity.color.spot.red })), TableRowAsset = (props) => {
|
|
7205
|
-
let $ = c(150), { id, selected } = props, scheme = useColorSchemeValue(), shiftPressed = useKeyPress("shift"), [referenceCountVisible, setReferenceCountVisible] = useState(!1), refCountVisibleTimeout = useRef(null), dispatch = useDispatch(), lastPicked = useTypedSelector(_temp$
|
|
7205
|
+
let $ = c(150), { id, selected } = props, scheme = useColorSchemeValue(), shiftPressed = useKeyPress("shift"), [referenceCountVisible, setReferenceCountVisible] = useState(!1), refCountVisibleTimeout = useRef(null), dispatch = useDispatch(), lastPicked = useTypedSelector(_temp$7), t0;
|
|
7206
7206
|
$[0] === id ? t0 = $[1] : (t0 = (state_0) => selectAssetById(state_0, id), $[0] = id, $[1] = t0);
|
|
7207
7207
|
let item = useTypedSelector(t0), mediaIndex = useMediaIndex(), asset = item?.asset, error = item?.error, isOpaque = item?.asset?.metadata?.isOpaque, picked = item?.picked, updating = item?.updating, { isMultiSelect, onSelect } = useAssetSourceActions(), t1;
|
|
7208
7208
|
$[2] !== asset || $[3] !== dispatch || $[4] !== isMultiSelect || $[5] !== lastPicked || $[6] !== onSelect || $[7] !== picked || $[8] !== selected || $[9] !== shiftPressed ? (t1 = (e) => {
|
|
@@ -7492,7 +7492,7 @@ const ContainerGrid$1 = /* @__PURE__ */ styled(Grid).withConfig({
|
|
|
7492
7492
|
textOverflow: "ellipsis",
|
|
7493
7493
|
children: referenceCountVisible ? /* @__PURE__ */ jsx(WithReferringDocuments, {
|
|
7494
7494
|
id,
|
|
7495
|
-
children: _temp2$
|
|
7495
|
+
children: _temp2$5
|
|
7496
7496
|
}) : /* @__PURE__ */ jsx(Fragment, { children: "-" })
|
|
7497
7497
|
}), $[120] = id, $[121] = referenceCountVisible, $[122] = t59) : t59 = $[122];
|
|
7498
7498
|
let t60;
|
|
@@ -7556,19 +7556,19 @@ const ContainerGrid$1 = /* @__PURE__ */ styled(Grid).withConfig({
|
|
|
7556
7556
|
}), $[135] = item.updating, $[136] = scheme, $[137] = selected, $[138] = t13, $[139] = t22, $[140] = t28, $[141] = t36, $[142] = t41, $[143] = t47, $[144] = t5, $[145] = t55, $[146] = t60, $[147] = t65, $[148] = t9, $[149] = t66) : t66 = $[149], t66;
|
|
7557
7557
|
};
|
|
7558
7558
|
var TableRowAsset_default = memo(TableRowAsset);
|
|
7559
|
-
function _temp$
|
|
7559
|
+
function _temp$7(state) {
|
|
7560
7560
|
return state.assets.lastPicked;
|
|
7561
7561
|
}
|
|
7562
|
-
function _temp2$
|
|
7562
|
+
function _temp2$5(t0) {
|
|
7563
7563
|
let { isLoading, referringDocuments } = t0, uniqueDocuments = getUniqueDocuments(referringDocuments);
|
|
7564
7564
|
return isLoading ? /* @__PURE__ */ jsx(Fragment, { children: "-" }) : /* @__PURE__ */ jsx(Fragment, { children: Array.isArray(uniqueDocuments) ? uniqueDocuments.length : 0 });
|
|
7565
7565
|
}
|
|
7566
7566
|
const ContainerGrid = /* @__PURE__ */ styled(Grid).withConfig({
|
|
7567
7567
|
displayName: "ContainerGrid",
|
|
7568
|
-
componentId: "sc-
|
|
7568
|
+
componentId: "sc-ezmovx-0"
|
|
7569
7569
|
})(({ theme }) => css`align-items:center;cursor:pointer;height:100%;user-select:none;white-space:nowrap;@media (hover:hover) and (pointer:fine){&:hover{background:${theme.sanity.color.card.enabled.bg};}}`), FolderBadge = /* @__PURE__ */ styled(Box).withConfig({
|
|
7570
7570
|
displayName: "FolderBadge",
|
|
7571
|
-
componentId: "sc-
|
|
7571
|
+
componentId: "sc-ezmovx-1"
|
|
7572
7572
|
})(({ theme }) => css`background:${theme.sanity.color.spot.yellow};border-radius:6px;height:42px;position:relative;width:52px;&::before{background:${theme.sanity.color.spot.yellow};border-radius:6px 6px 0 0;content:'';height:12px;left:0;position:absolute;top:-6px;width:18px;}`), TableRowFolder = (t0) => {
|
|
7573
7573
|
let $ = c(45), { folderId, name, totalCount } = t0, dispatch = useDispatch(), mediaIndex = useMediaIndex(), scheme = useColorSchemeValue(), t1;
|
|
7574
7574
|
$[0] !== dispatch || $[1] !== folderId ? (t1 = () => dispatch(foldersActions.currentFolderSet({ folderId })), $[0] = dispatch, $[1] = folderId, $[2] = t1) : t1 = $[2];
|
|
@@ -7867,8 +7867,8 @@ const ContainerGrid = /* @__PURE__ */ styled(Grid).withConfig({
|
|
|
7867
7867
|
}
|
|
7868
7868
|
return null;
|
|
7869
7869
|
}), AssetTableVirtualized = (props) => {
|
|
7870
|
-
let $ = c(15), { items, onLoadMore } = props, selectedAssets = useTypedSelector(_temp$
|
|
7871
|
-
$[0] === selectedAssets ? t0 = $[1] : (t0 = selectedAssets && selectedAssets.map(_temp2$
|
|
7870
|
+
let $ = c(15), { items, onLoadMore } = props, selectedAssets = useTypedSelector(_temp$6), t0;
|
|
7871
|
+
$[0] === selectedAssets ? t0 = $[1] : (t0 = selectedAssets && selectedAssets.map(_temp2$4) || [], $[0] = selectedAssets, $[1] = t0);
|
|
7872
7872
|
let selectedIds = t0, totalCount = items?.length;
|
|
7873
7873
|
if (totalCount === 0) return null;
|
|
7874
7874
|
let t1;
|
|
@@ -7891,22 +7891,22 @@ const ContainerGrid = /* @__PURE__ */ styled(Grid).withConfig({
|
|
|
7891
7891
|
computeItemKey: t1,
|
|
7892
7892
|
endReached: onLoadMore,
|
|
7893
7893
|
groupCounts: t2,
|
|
7894
|
-
groupContent: _temp3$
|
|
7894
|
+
groupContent: _temp3$3,
|
|
7895
7895
|
itemContent: t3,
|
|
7896
7896
|
style: t4
|
|
7897
7897
|
}), $[10] = onLoadMore, $[11] = t1, $[12] = t2, $[13] = t3, $[14] = t5) : t5 = $[14], t5;
|
|
7898
7898
|
};
|
|
7899
|
-
function _temp$
|
|
7899
|
+
function _temp$6(state) {
|
|
7900
7900
|
return state.selected.assets;
|
|
7901
7901
|
}
|
|
7902
|
-
function _temp2$
|
|
7902
|
+
function _temp2$4(asset) {
|
|
7903
7903
|
return asset._id;
|
|
7904
7904
|
}
|
|
7905
|
-
function _temp3$
|
|
7905
|
+
function _temp3$3() {
|
|
7906
7906
|
return /* @__PURE__ */ jsx(TableHeader, {});
|
|
7907
7907
|
}
|
|
7908
7908
|
const Items = () => {
|
|
7909
|
-
let $ = c(15), dispatch = useDispatch(), fetchCount = useTypedSelector(_temp$
|
|
7909
|
+
let $ = c(15), dispatch = useDispatch(), fetchCount = useTypedSelector(_temp$5), fetching = useTypedSelector(_temp2$3), foldersPanelVisible = useTypedSelector(_temp3$2), tagsPanelVisible = useTypedSelector(_temp4), view = useTypedSelector(_temp5), combinedItems = useTypedSelector(selectCombinedItems), mediaIndex = useMediaIndex(), hasFetchedOnce = fetchCount >= 0, hasItems = combinedItems.length > 0, t0;
|
|
7910
7910
|
$[0] !== dispatch || $[1] !== fetching ? (t0 = () => {
|
|
7911
7911
|
fetching || dispatch(assetsActions.loadNextPage());
|
|
7912
7912
|
}, $[0] = dispatch, $[1] = fetching, $[2] = t0) : t0 = $[2];
|
|
@@ -7941,13 +7941,13 @@ const Items = () => {
|
|
|
7941
7941
|
})] })
|
|
7942
7942
|
}), $[10] = combinedItems, $[11] = handleLoadMoreItems, $[12] = isEmpty, $[13] = view, $[14] = t4) : t4 = $[14], t4;
|
|
7943
7943
|
};
|
|
7944
|
-
function _temp$
|
|
7944
|
+
function _temp$5(state) {
|
|
7945
7945
|
return state.assets.fetchCount;
|
|
7946
7946
|
}
|
|
7947
|
-
function _temp2$
|
|
7947
|
+
function _temp2$3(state_0) {
|
|
7948
7948
|
return state_0.assets.fetching;
|
|
7949
7949
|
}
|
|
7950
|
-
function _temp3$
|
|
7950
|
+
function _temp3$2(state_1) {
|
|
7951
7951
|
return state_1.folders.panelVisible;
|
|
7952
7952
|
}
|
|
7953
7953
|
function _temp4(state_2) {
|
|
@@ -7957,7 +7957,7 @@ function _temp5(state_3) {
|
|
|
7957
7957
|
return state_3.assets.view;
|
|
7958
7958
|
}
|
|
7959
7959
|
const PickedBar = () => {
|
|
7960
|
-
let $ = c(57), scheme = useColorSchemeValue(), dispatch = useDispatch(), assetsPicked = useTypedSelector(selectAssetsPicked), currentFolderId = useTypedSelector(_temp$
|
|
7960
|
+
let $ = c(57), scheme = useColorSchemeValue(), dispatch = useDispatch(), assetsPicked = useTypedSelector(selectAssetsPicked), currentFolderId = useTypedSelector(_temp$4), { isMultiSelect, onSelect } = useAssetSourceActions(), t0;
|
|
7961
7961
|
$[0] !== assetsPicked[0] || $[1] !== assetsPicked.length ? (t0 = assetsPicked.length === 1 && !!assetsPicked[0] && isImageAsset(assetsPicked[0].asset), $[0] = assetsPicked[0], $[1] = assetsPicked.length, $[2] = t0) : t0 = $[2];
|
|
7962
7962
|
let canReplace = t0, t1;
|
|
7963
7963
|
$[3] === dispatch ? t1 = $[4] : (t1 = () => {
|
|
@@ -7985,7 +7985,7 @@ const PickedBar = () => {
|
|
|
7985
7985
|
let handleRemovePickedFromFolder = t5, t6;
|
|
7986
7986
|
$[18] !== assetsPicked || $[19] !== onSelect ? (t6 = () => {
|
|
7987
7987
|
if (!onSelect) return;
|
|
7988
|
-
let pickedAssetIds = assetsPicked.map(_temp2$
|
|
7988
|
+
let pickedAssetIds = assetsPicked.map(_temp2$2);
|
|
7989
7989
|
pickedAssetIds.length !== 0 && onSelect(pickedAssetIds);
|
|
7990
7990
|
}, $[18] = assetsPicked, $[19] = onSelect, $[20] = t6) : t6 = $[20];
|
|
7991
7991
|
let handleInsertPicked = t6;
|
|
@@ -8128,10 +8128,10 @@ const PickedBar = () => {
|
|
|
8128
8128
|
children: t19
|
|
8129
8129
|
}), $[54] = t19, $[55] = t8, $[56] = t20) : t20 = $[56], t20;
|
|
8130
8130
|
};
|
|
8131
|
-
function _temp$
|
|
8131
|
+
function _temp$4(state) {
|
|
8132
8132
|
return state.folders.currentFolderId;
|
|
8133
8133
|
}
|
|
8134
|
-
function _temp2$
|
|
8134
|
+
function _temp2$2(item) {
|
|
8135
8135
|
return {
|
|
8136
8136
|
kind: "assetDocumentId",
|
|
8137
8137
|
value: item.asset._id
|
|
@@ -8139,7 +8139,7 @@ function _temp2$1(item) {
|
|
|
8139
8139
|
}
|
|
8140
8140
|
const TagsPanel = () => {
|
|
8141
8141
|
let $ = c(2);
|
|
8142
|
-
if (!useTypedSelector(_temp$
|
|
8142
|
+
if (!useTypedSelector(_temp$3)) return null;
|
|
8143
8143
|
let t0;
|
|
8144
8144
|
$[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = {
|
|
8145
8145
|
position: "relative",
|
|
@@ -8164,15 +8164,15 @@ const TagsPanel = () => {
|
|
|
8164
8164
|
})
|
|
8165
8165
|
}), $[1] = t1) : t1 = $[1], t1;
|
|
8166
8166
|
};
|
|
8167
|
-
function _temp$
|
|
8167
|
+
function _temp$3(state) {
|
|
8168
8168
|
return state.tags.panelVisible;
|
|
8169
8169
|
}
|
|
8170
8170
|
const UploadContainer = styled.div.withConfig({
|
|
8171
8171
|
displayName: "UploadContainer",
|
|
8172
|
-
componentId: "sc-
|
|
8172
|
+
componentId: "sc-cm6qls-0"
|
|
8173
8173
|
})`color:white;height:100%;min-height:100%;right:0;top:0;width:100%;&:focus{outline:none;}`, DragActiveContainer = styled.div.withConfig({
|
|
8174
8174
|
displayName: "DragActiveContainer",
|
|
8175
|
-
componentId: "sc-
|
|
8175
|
+
componentId: "sc-cm6qls-1"
|
|
8176
8176
|
})`align-items:center;background:rgba(0,0,0,0.75);display:flex;height:100%;justify-content:center;position:absolute;right:0;top:0;width:100%;z-index:3;`;
|
|
8177
8177
|
async function filterFiles(fileList) {
|
|
8178
8178
|
let files = Array.from(fileList), filteredFiles = [];
|
|
@@ -8182,7 +8182,7 @@ async function filterFiles(fileList) {
|
|
|
8182
8182
|
return filteredFiles;
|
|
8183
8183
|
}
|
|
8184
8184
|
const UploadDropzone = (props) => {
|
|
8185
|
-
let $ = c(32), { children } = props, { dropzone: t0, directUploads } = useToolOptions(), { maxSize } = t0, { onSelect } = useAssetSourceActions(), dispatch = useDispatch(), assetTypes = useTypedSelector(_temp$
|
|
8185
|
+
let $ = c(32), { children } = props, { dropzone: t0, directUploads } = useToolOptions(), { maxSize } = t0, { onSelect } = useAssetSourceActions(), dispatch = useDispatch(), assetTypes = useTypedSelector(_temp$2), isImageAssetType = assetTypes.length === 1 && assetTypes[0] === "image", t1;
|
|
8186
8186
|
$[0] !== assetTypes[0] || $[1] !== assetTypes.length || $[2] !== dispatch ? (t1 = async (acceptedFiles) => {
|
|
8187
8187
|
acceptedFiles.forEach((file) => dispatch(uploadsActions.uploadRequest({
|
|
8188
8188
|
file,
|
|
@@ -8191,7 +8191,7 @@ const UploadDropzone = (props) => {
|
|
|
8191
8191
|
}, $[0] = assetTypes[0], $[1] = assetTypes.length, $[2] = dispatch, $[3] = t1) : t1 = $[3];
|
|
8192
8192
|
let handleDrop = t1, t2;
|
|
8193
8193
|
$[4] === dispatch ? t2 = $[5] : (t2 = (rejections) => {
|
|
8194
|
-
rejections.flatMap(_temp3).includes("file-too-large") && dispatch(notificationsActions.add({
|
|
8194
|
+
rejections.flatMap(_temp3$1).includes("file-too-large") && dispatch(notificationsActions.add({
|
|
8195
8195
|
status: "error",
|
|
8196
8196
|
title: "One or more files exceed the maximum upload size."
|
|
8197
8197
|
}));
|
|
@@ -8253,16 +8253,16 @@ const UploadDropzone = (props) => {
|
|
|
8253
8253
|
children: t12
|
|
8254
8254
|
}), $[29] = open, $[30] = t12, $[31] = t13) : t13 = $[31], t13;
|
|
8255
8255
|
};
|
|
8256
|
-
function _temp$
|
|
8256
|
+
function _temp$2(state) {
|
|
8257
8257
|
return state.assets.assetTypes;
|
|
8258
8258
|
}
|
|
8259
|
-
function _temp2(t0) {
|
|
8259
|
+
function _temp2$1(t0) {
|
|
8260
8260
|
let { code } = t0;
|
|
8261
8261
|
return code;
|
|
8262
8262
|
}
|
|
8263
|
-
function _temp3(t0) {
|
|
8263
|
+
function _temp3$1(t0) {
|
|
8264
8264
|
let { errors } = t0;
|
|
8265
|
-
return errors.map(_temp2);
|
|
8265
|
+
return errors.map(_temp2$1);
|
|
8266
8266
|
}
|
|
8267
8267
|
function getMediaTagNames(schemaType) {
|
|
8268
8268
|
let mediaTags = schemaType?.options?.mediaTags;
|
|
@@ -8299,22 +8299,26 @@ function createTagHandler(dispatch) {
|
|
|
8299
8299
|
};
|
|
8300
8300
|
}
|
|
8301
8301
|
function useBrowserInit(client, schemaType) {
|
|
8302
|
-
let
|
|
8303
|
-
|
|
8302
|
+
let $ = c(16), dispatch = useDispatch(), tagsByIds = useSelector(_temp$1), tagsFetchCount = useSelector(_temp2), t0;
|
|
8303
|
+
$[0] === schemaType ? t0 = $[1] : (t0 = getMediaTagNames(schemaType), $[0] = schemaType, $[1] = t0);
|
|
8304
|
+
let tagNames = t0, hasMediaTags = tagNames.length > 0, t1, t2;
|
|
8305
|
+
$[2] !== client || $[3] !== dispatch || $[4] !== hasMediaTags ? (t1 = () => {
|
|
8304
8306
|
hasMediaTags || dispatch(searchActions.facetsClear()), dispatch(tagsActions.fetchRequest()), dispatch(foldersActions.fetchRequest());
|
|
8305
8307
|
let assetSubscription = client.listen(groq`*[_type in ["sanity.fileAsset", "sanity.imageAsset"] && !(_id in path("drafts.**"))]`).subscribe(createAssetHandler(dispatch)), tagSubscription = client.listen(groq`*[_type == "${TAG_DOCUMENT_NAME}" && !(_id in path("drafts.**"))]`).subscribe(createTagHandler(dispatch)), folderSubscription = client.listen(groq`*[_type == "${FOLDER_DOCUMENT_NAME}" && !(_id in path("drafts.**"))]`).subscribe(() => dispatch(foldersActions.fetchRequest()));
|
|
8306
8308
|
return () => {
|
|
8307
8309
|
assetSubscription.unsubscribe(), tagSubscription.unsubscribe(), folderSubscription.unsubscribe();
|
|
8308
8310
|
};
|
|
8309
|
-
}, [
|
|
8311
|
+
}, t2 = [
|
|
8310
8312
|
client,
|
|
8311
8313
|
dispatch,
|
|
8312
8314
|
hasMediaTags
|
|
8313
|
-
]), useEffect(
|
|
8315
|
+
], $[2] = client, $[3] = dispatch, $[4] = hasMediaTags, $[5] = t1, $[6] = t2) : (t1 = $[5], t2 = $[6]), useEffect(t1, t2);
|
|
8316
|
+
let t3;
|
|
8317
|
+
$[7] !== dispatch || $[8] !== hasMediaTags || $[9] !== tagNames || $[10] !== tagsByIds || $[11] !== tagsFetchCount ? (t3 = () => {
|
|
8314
8318
|
if (!hasMediaTags || tagsFetchCount < 0) return;
|
|
8315
8319
|
let tagFacetInput = inputs.tag;
|
|
8316
8320
|
if (tagFacetInput.type !== "searchable") return;
|
|
8317
|
-
let resolvedTags = tagNames.map((name) => Object.values(tagsByIds).find((item) => item.tag.name.current === name)).filter(
|
|
8321
|
+
let resolvedTags = tagNames.map((name) => Object.values(tagsByIds).find((item) => item.tag.name.current === name)).filter(_temp3);
|
|
8318
8322
|
dispatch(searchActions.facetsClear());
|
|
8319
8323
|
for (let tagItem of resolvedTags) dispatch(searchActions.facetsAdd({ facet: {
|
|
8320
8324
|
...tagFacetInput,
|
|
@@ -8324,7 +8328,18 @@ function useBrowserInit(client, schemaType) {
|
|
|
8324
8328
|
value: tagItem.tag._id
|
|
8325
8329
|
}
|
|
8326
8330
|
} }));
|
|
8327
|
-
}, [
|
|
8331
|
+
}, $[7] = dispatch, $[8] = hasMediaTags, $[9] = tagNames, $[10] = tagsByIds, $[11] = tagsFetchCount, $[12] = t3) : t3 = $[12];
|
|
8332
|
+
let t4;
|
|
8333
|
+
$[13] !== hasMediaTags || $[14] !== tagsFetchCount ? (t4 = [tagsFetchCount, hasMediaTags], $[13] = hasMediaTags, $[14] = tagsFetchCount, $[15] = t4) : t4 = $[15], useEffect(t3, t4);
|
|
8334
|
+
}
|
|
8335
|
+
function _temp3(item_0) {
|
|
8336
|
+
return !!item_0;
|
|
8337
|
+
}
|
|
8338
|
+
function _temp2(state_0) {
|
|
8339
|
+
return state_0.tags.fetchCount;
|
|
8340
|
+
}
|
|
8341
|
+
function _temp$1(state) {
|
|
8342
|
+
return state.tags.byIds;
|
|
8328
8343
|
}
|
|
8329
8344
|
const BrowserContent = (t0) => {
|
|
8330
8345
|
let $ = c(14), { onClose, schemaType } = t0, client = useVersionedClient(), [portalElement, setPortalElement] = useState(null);
|