@bynder/compact-view 5.2.3 → 5.2.4
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/AccessToken2.js +1 -1
- package/ActiveFilters.js +49 -50
- package/AddMedia.js +19 -18
- package/Advanced.js +13 -13
- package/App.js +60 -59
- package/Arrow.js +1 -1
- package/AssetFilter.js +38 -38
- package/AssetItem.js +10 -17
- package/AssetList.js +5 -5
- package/AssetTypeItem.js +21 -21
- package/AssetsView.js +13 -13
- package/Axios2.js +82 -76
- package/AxiosError.js +36 -35
- package/ButtonAction.js +1 -1
- package/CanceledError.js +15 -8
- package/Card.js +1 -1
- package/Chip.js +1 -1
- package/CollectionCard.js +22 -22
- package/CollectionItem.js +9 -9
- package/CollectionList.js +5 -5
- package/CollectionView.js +11 -11
- package/ColorPicker.js +1 -1
- package/ColorPickerSolid.js +3 -3
- package/ColorPickerWithOpacity.js +3 -3
- package/Component.js +158 -0
- package/Component2.js +4 -0
- package/ConfigContext.js +7 -8
- package/Container.js +1 -1
- package/ContextAction.js +1 -1
- package/ControlGroup.js +6 -6
- package/Dat.js +33 -32
- package/DatDropdownItem.js +1 -1
- package/DesignSystemProvider.js +7 -7
- package/DirectionSelect.js +11 -10
- package/DomainInput.js +19 -11
- package/Draggable.js +337 -0
- package/Draggable2.js +4 -0
- package/DraggableCore.js +312 -0
- package/DraggableCore2.js +4 -0
- package/Dropdown.js +37 -37
- package/Dropdown2.js +1 -1
- package/DropdownListItem.js +1 -1
- package/FieldSelect.js +19 -17
- package/FileSelector.js +38 -37
- package/FontPicker.js +1 -1
- package/Form.js +1 -1
- package/Header.js +5 -4
- package/HttpStatusCode.js +7 -1
- package/InfiniteScroll.js +1 -1
- package/InlineBanner.js +1 -1
- package/Input.js +1 -1
- package/InterceptorManager.js +2 -1
- package/Item.js +8 -8
- package/Item4.js +2 -2
- package/LeftArrow.js +1 -1
- package/ListItem2.js +1 -1
- package/ModalBase.js +15 -15
- package/NoResults.js +1 -1
- package/Option_new.js +36 -29
- package/ReactPropTypesSecret.js +10 -0
- package/RightArrow.js +1 -1
- package/SearchInput.js +1 -1
- package/SearchInput2.js +1 -1
- package/SelectionFooter.js +41 -31
- package/Shield.js +2 -2
- package/Smartfilters_new.js +107 -98
- package/StatefulAssetList.js +50 -50
- package/StoreInitializer.js +32 -16
- package/SwitchNLS.js +1 -1
- package/TagItem.js +15 -15
- package/Tags.js +1 -1
- package/Toolbar.js +23 -20
- package/Tooltip2.js +1 -1
- package/ViewSwitch.js +17 -15
- package/_commonjsHelpers.js +28 -3
- package/adapters.js +54 -42
- package/api/filterAssets.d.ts +1 -1
- package/api/getAssets.d.ts +1 -1
- package/api/getFilters.d.ts +1 -1
- package/api/rest/index.d.ts +1 -1
- package/api/rest/types.d.ts +1 -1
- package/api2.js +1 -1
- package/asset.type.js +1 -1
- package/autocomplete.js +1 -1
- package/axios.js +1 -1
- package/bodyScrollLock.esm.js +68 -0
- package/buildURL.js +13 -15
- package/checkGlobals.js +1 -1
- package/cjs.js +7 -0
- package/cjs2.js +15 -0
- package/cjs3.js +4 -0
- package/clsx.m.js +6 -0
- package/clsx.m2.js +15 -0
- package/combineMetaproperties.js +3 -1
- package/composeSignals.js +1 -1
- package/cookieStore.js +1 -1
- package/cookies.js +13 -11
- package/currentScopes.js +1 -1
- package/data.js +1 -1
- package/devUtils.js +1 -1
- package/dispatchRequest.js +5 -5
- package/domFns.js +151 -0
- package/domFns2.js +4 -0
- package/factoryWithThrowingShims.js +52 -0
- package/fetch2.js +156 -128
- package/filter/AssetFilterContext.d.ts +3 -3
- package/filterAssets.js +1 -1
- package/getAsset.js +1 -1
- package/getAssetCounts.js +1 -1
- package/getAssets.js +1 -1
- package/getCollections.js +1 -1
- package/getFilterOptions.js +1 -1
- package/getFilters.js +1 -1
- package/getFilters_new.js +1 -1
- package/getPrefix.js +35 -0
- package/getPrefix2.js +4 -0
- package/getSimilarityAssets.js +1 -1
- package/goober.modern.js +75 -0
- package/handlers.js +1 -1
- package/iconBase.js +56 -0
- package/iconContext.js +12 -0
- package/iconsManifest.js +222 -0
- package/index-esm.js +1 -4
- package/index.browser.js +1 -1
- package/index.m.js +9 -0
- package/index.m2.js +17 -0
- package/index10.js +18 -2
- package/index11.js +181 -15
- package/index112.js +1 -1
- package/index12.js +313 -36
- package/index13.js +5 -2430
- package/index14.js +3 -557
- package/index15.js +15 -55
- package/index16.js +3 -2
- package/index17.js +3 -87
- package/index18.js +36 -60
- package/index19.js +3 -7
- package/index20.js +2429 -12
- package/index21.js +557 -10
- package/index22.js +1 -1
- package/index23.js +119 -6
- package/index24.js +39 -7
- package/index25.js +2 -5
- package/index26.js +86 -9
- package/index27.js +55 -8
- package/index28.js +6 -636
- package/index29.js +8692 -74
- package/index3.js +1684 -5
- package/index30.js +2 -5
- package/index31.js +4 -20
- package/index310.js +2 -0
- package/index32.js +11 -2
- package/index33.js +5083 -4
- package/index34.js +2 -18
- package/index35.js +59 -5
- package/index36.js +2 -2
- package/index37.js +13 -11
- package/index38.js +46 -10
- package/index39.js +6 -12
- package/index4.js +5 -1684
- package/index40.js +8 -11
- package/index41.js +26 -18
- package/index42.js +2 -64
- package/index43.js +63 -5
- package/index44.js +9 -55
- package/index45.js +7 -67
- package/index46.js +8 -31
- package/index47.js +5 -11
- package/index48.js +10 -121
- package/index49.js +9 -86
- package/index5.js +215 -23
- package/index50.js +636 -7
- package/index51.js +74 -11
- package/index52.js +4 -13
- package/index53.js +19 -13
- package/index54.js +4 -6
- package/index55.js +18 -7
- package/index56.js +5 -14
- package/index57.js +10 -28
- package/index58.js +10 -15
- package/index59.js +15 -0
- package/index6.js +250 -299
- package/index60.js +13 -0
- package/index61.js +21 -0
- package/index62.js +8 -0
- package/index63.js +57 -0
- package/index64.js +4 -0
- package/index65.js +69 -0
- package/index66.js +33 -0
- package/index67.js +13 -0
- package/index68.js +123 -0
- package/index69.js +88 -0
- package/index7.js +22 -5047
- package/index70.js +10 -0
- package/index71.js +13 -0
- package/index72.js +13 -225
- package/index73.js +16 -0
- package/index74.js +9 -0
- package/index75.js +228 -0
- package/index76.js +9 -0
- package/index77.js +17 -0
- package/index78.js +31 -0
- package/index79.js +18 -0
- package/index8.js +5044 -47
- package/index9.js +50 -15
- package/isAbsoluteURL.js +1 -1
- package/isURLSameOrigin.js +1 -1
- package/localization.js +15 -15
- package/log.js +14 -0
- package/log2.js +4 -0
- package/matchRequestUrl.js +1 -1
- package/mergeConfig.js +37 -32
- package/notify.js +2 -2
- package/package.json +1 -1
- package/positionFns.js +101 -0
- package/positionFns2.js +4 -0
- package/react-laag.esm.js +957 -0
- package/react.js +8 -8
- package/react2.js +9 -9
- package/resolveConfig.js +23 -23
- package/select/add-media/AddMedia.d.ts +3 -1
- package/select/current-selection/SelectedItems.d.ts +1 -1
- package/shims.js +29 -0
- package/shims2.js +4 -0
- package/store/StoreInitializer.d.ts +5 -1
- package/store/useAssetFilterStore.d.ts +55 -0
- package/store/useSelectionStore.d.ts +47 -0
- package/styled-components.browser.esm.js +2 -2
- package/throttle.js +1 -1
- package/toURLEncodedForm.js +11 -10
- package/tokenExpirationHelper.js +1 -1
- package/transformData.js +1 -1
- package/transitional.js +4 -3
- package/useAssetFilterStore.js +152 -0
- package/useDatStore.js +1 -1
- package/useEffectEvent.js +7 -7
- package/useFonts.js +2 -2
- package/useOrderingStore.js +1 -1
- package/useRouterStore.js +1 -1
- package/useSearchStore.js +1 -1
- package/useSelectionStore.js +131 -0
- package/useSimilaritySearchStore.js +1 -1
- package/useTranslate.js +1 -1
- package/utils/combineMetaproperties.d.ts +2 -0
- package/utils6.js +160 -118
- package/utils7.js +7 -68
- package/utils8.js +68 -7
- package/xhr.js +47 -46
- package/AssetFilterContext.js +0 -161
- package/SelectionContext.js +0 -143
- package/select/SelectionContext.d.ts +0 -30
- /package/{Middleware.js → Middleware2.js} +0 -0
- /package/{middleware2.js → middleware.js} +0 -0
package/AssetList.js
CHANGED
|
@@ -6,9 +6,9 @@ import { CardSkeleton as V } from "./CardSkeleton.js";
|
|
|
6
6
|
import { DragSelect as X } from "./DragSelect.js";
|
|
7
7
|
import { useDimensions as Y } from "./useDimensions.js";
|
|
8
8
|
import { InfiniteScroll as Z } from "./InfiniteScroll.js";
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
9
|
+
import { useSimilaritySearchStore as $ } from "./useSimilaritySearchStore.js";
|
|
10
|
+
import { useSimilarityAssets as T } from "./getSimilarityAssets.js";
|
|
11
|
+
import { useSelectionStore as ee } from "./useSelectionStore.js";
|
|
12
12
|
function he({
|
|
13
13
|
assets: e,
|
|
14
14
|
count: l,
|
|
@@ -26,11 +26,11 @@ function he({
|
|
|
26
26
|
theme: S,
|
|
27
27
|
children: B = null
|
|
28
28
|
}) {
|
|
29
|
-
const x = P(null), { dimensions: M } = Y(x.current), [f, v] = k([]), [D, b] = k("inactive"), { clear: R } =
|
|
29
|
+
const x = P(null), { dimensions: M } = Y(x.current), [f, v] = k([]), [D, b] = k("inactive"), { clear: R } = ee(), {
|
|
30
30
|
setIsEnabled: C,
|
|
31
31
|
isEnabled: H,
|
|
32
32
|
setIsSelected: W
|
|
33
|
-
} =
|
|
33
|
+
} = $(), { resetData: j, search: p } = T(), [A, E] = te(l, M), L = P(!1);
|
|
34
34
|
J(() => {
|
|
35
35
|
!L.current && e.value && e.value.length > 0 && (L.current = !0, (async () => {
|
|
36
36
|
if (e.value && e.value.length > 0) {
|
package/AssetTypeItem.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { jsx as t, jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { Checkbox as
|
|
4
|
-
import { token as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
function
|
|
9
|
-
const n =
|
|
10
|
-
function
|
|
11
|
-
i ?
|
|
1
|
+
import { jsx as t, jsxs as r } from "react/jsx-runtime";
|
|
2
|
+
import m from "./styled-components.browser.esm.js";
|
|
3
|
+
import { Checkbox as l } from "./Checkbox.js";
|
|
4
|
+
import { token as y } from "./token.js";
|
|
5
|
+
import { getAssetTypeIcon as p, assetTypeToString as s } from "./asset.type.js";
|
|
6
|
+
import { ListItem as f, StyledCheckboxWrapper as h, Content as g } from "./Checkbox.styles.js";
|
|
7
|
+
import { useAssetFilterStore as C } from "./useAssetFilterStore.js";
|
|
8
|
+
function L(e) {
|
|
9
|
+
const { assetTypes: n, addAssetType: o, removeAssetType: d } = C(), i = n.includes(e.type);
|
|
10
|
+
function a() {
|
|
11
|
+
i ? d(e.type) : o(e.type);
|
|
12
12
|
}
|
|
13
|
-
const c =
|
|
14
|
-
return /* @__PURE__ */ t(
|
|
15
|
-
|
|
13
|
+
const c = p(e.type);
|
|
14
|
+
return /* @__PURE__ */ t(f, { "data-testid": "advanced-options", children: /* @__PURE__ */ t(h, { $isChecked: i, $isLoading: e.isLoading, children: /* @__PURE__ */ t(
|
|
15
|
+
l,
|
|
16
16
|
{
|
|
17
17
|
isChecked: i,
|
|
18
|
-
onChange:
|
|
18
|
+
onChange: a,
|
|
19
19
|
"data-testid": `${s(e.type)}-filter`,
|
|
20
|
-
children: /* @__PURE__ */
|
|
20
|
+
children: /* @__PURE__ */ r(g, { $isChecked: i, children: [
|
|
21
21
|
/* @__PURE__ */ t(c, {}),
|
|
22
|
-
/* @__PURE__ */ t(
|
|
23
|
-
/* @__PURE__ */ t("span", { className: "fade-in-down", children: e.count })
|
|
22
|
+
/* @__PURE__ */ t(k, { "data-testid": "asset-type-label", children: s(e.type) }),
|
|
23
|
+
/* @__PURE__ */ t("span", { className: "fade-in-down", "data-testid": "asset-type-count", children: e.count })
|
|
24
24
|
] })
|
|
25
25
|
}
|
|
26
26
|
) }) });
|
|
27
27
|
}
|
|
28
|
-
const
|
|
29
|
-
margin: 1px ${
|
|
28
|
+
const k = m.div`
|
|
29
|
+
margin: 1px ${y.spacing3};
|
|
30
30
|
flex-grow: 1;
|
|
31
31
|
`;
|
|
32
32
|
export {
|
|
33
|
-
|
|
33
|
+
L as AssetTypeItem
|
|
34
34
|
};
|
package/AssetsView.js
CHANGED
|
@@ -2,44 +2,44 @@ import { jsx as h } from "react/jsx-runtime";
|
|
|
2
2
|
import { useMemo as y } from "react";
|
|
3
3
|
import { useFilterAssets as A } from "./filterAssets.js";
|
|
4
4
|
import { useConfig as g } from "./ConfigContext.js";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
5
|
+
import { useOrderingSelectors as T } from "./useOrderingStore.js";
|
|
6
|
+
import { StatefulAssetList as F } from "./StatefulAssetList.js";
|
|
7
|
+
import { useSearchStateByPage as b } from "./useSearchStore.js";
|
|
8
|
+
import { useSimilaritySearchStore as v } from "./useSimilaritySearchStore.js";
|
|
9
|
+
import { useSimilarityAssets as w } from "./getSimilarityAssets.js";
|
|
10
|
+
import { useAssetFilterStore as B } from "./useAssetFilterStore.js";
|
|
11
11
|
function k() {
|
|
12
|
-
const { assetTypes:
|
|
12
|
+
const { assetTypes: t, tags: r, isLimited: s, selectedSmartfilterOptions: o } = B(), {
|
|
13
13
|
isSelected: l,
|
|
14
14
|
isNLSSelected: m,
|
|
15
15
|
NLSSearchText: f
|
|
16
|
-
} =
|
|
16
|
+
} = v(), { connection: S } = w(), { value: c } = b("assets"), i = T.use.assets(), {
|
|
17
17
|
assetFilter: e,
|
|
18
18
|
assetTypes: a,
|
|
19
19
|
language: n,
|
|
20
20
|
noCache: u
|
|
21
21
|
} = g(), d = y(() => e === void 0 ? {
|
|
22
|
-
filter: { assetTypes:
|
|
22
|
+
filter: { assetTypes: t, selectedSmartfilterOptions: o, tags: r, isLimited: s },
|
|
23
23
|
searchTerm: c,
|
|
24
24
|
orderBy: i,
|
|
25
25
|
allAssetTypes: a,
|
|
26
26
|
language: n
|
|
27
27
|
} : e && e.showToolbar ? {
|
|
28
|
-
filter: { assetTypes:
|
|
28
|
+
filter: { assetTypes: t, selectedSmartfilterOptions: o, tags: r, isLimited: s },
|
|
29
29
|
searchTerm: c,
|
|
30
30
|
orderBy: i,
|
|
31
31
|
predefinedFilter: e,
|
|
32
32
|
allAssetTypes: a,
|
|
33
33
|
language: n
|
|
34
34
|
} : {
|
|
35
|
-
filter: { assetTypes:
|
|
35
|
+
filter: { assetTypes: t, selectedSmartfilterOptions: o, tags: r, isLimited: s },
|
|
36
36
|
predefinedFilter: e,
|
|
37
37
|
orderBy: i,
|
|
38
38
|
language: n
|
|
39
39
|
}, [
|
|
40
|
-
s,
|
|
41
40
|
t,
|
|
42
41
|
r,
|
|
42
|
+
s,
|
|
43
43
|
c,
|
|
44
44
|
i,
|
|
45
45
|
e,
|
|
@@ -48,7 +48,7 @@ function k() {
|
|
|
48
48
|
o
|
|
49
49
|
]), p = A(d, u);
|
|
50
50
|
return /* @__PURE__ */ h(
|
|
51
|
-
|
|
51
|
+
F,
|
|
52
52
|
{
|
|
53
53
|
connection: l || m && !!f ? S : p,
|
|
54
54
|
showActiveFilters: e === void 0 || e && e.showToolbar
|
package/Axios2.js
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import d from "./utils6.js";
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
2
|
+
import S from "./buildURL.js";
|
|
3
|
+
import E from "./InterceptorManager.js";
|
|
4
|
+
import I from "./dispatchRequest.js";
|
|
5
5
|
import w from "./mergeConfig.js";
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
import U from "./buildFullPath.js";
|
|
7
|
+
import y from "./validator.js";
|
|
8
|
+
import A from "./AxiosHeaders.js";
|
|
9
|
+
import T from "./transitional.js";
|
|
10
|
+
const l = y.validators;
|
|
11
|
+
class q {
|
|
11
12
|
constructor(t) {
|
|
12
13
|
this.defaults = t || {}, this.interceptors = {
|
|
13
|
-
request: new
|
|
14
|
-
response: new
|
|
14
|
+
request: new E(),
|
|
15
|
+
response: new E()
|
|
15
16
|
};
|
|
16
17
|
}
|
|
17
18
|
/**
|
|
@@ -25,112 +26,117 @@ class k {
|
|
|
25
26
|
async request(t, e) {
|
|
26
27
|
try {
|
|
27
28
|
return await this._request(t, e);
|
|
28
|
-
} catch (
|
|
29
|
-
if (
|
|
30
|
-
let
|
|
31
|
-
Error.captureStackTrace ? Error.captureStackTrace(
|
|
32
|
-
const
|
|
29
|
+
} catch (r) {
|
|
30
|
+
if (r instanceof Error) {
|
|
31
|
+
let n = {};
|
|
32
|
+
Error.captureStackTrace ? Error.captureStackTrace(n) : n = new Error();
|
|
33
|
+
const s = n.stack ? n.stack.replace(/^.+\n/, "") : "";
|
|
33
34
|
try {
|
|
34
|
-
|
|
35
|
-
` +
|
|
35
|
+
r.stack ? s && !String(r.stack).endsWith(s.replace(/^.+\n.+\n/, "")) && (r.stack += `
|
|
36
|
+
` + s) : r.stack = s;
|
|
36
37
|
} catch {
|
|
37
38
|
}
|
|
38
39
|
}
|
|
39
|
-
throw
|
|
40
|
+
throw r;
|
|
40
41
|
}
|
|
41
42
|
}
|
|
42
43
|
_request(t, e) {
|
|
43
44
|
typeof t == "string" ? (e = e || {}, e.url = t) : e = t || {}, e = w(this.defaults, e);
|
|
44
|
-
const { transitional:
|
|
45
|
-
|
|
46
|
-
silentJSONParsing:
|
|
47
|
-
forcedJSONParsing:
|
|
48
|
-
clarifyTimeoutError:
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
45
|
+
const { transitional: r, paramsSerializer: n, headers: s } = e;
|
|
46
|
+
r !== void 0 && y.assertOptions(r, {
|
|
47
|
+
silentJSONParsing: l.transitional(l.boolean),
|
|
48
|
+
forcedJSONParsing: l.transitional(l.boolean),
|
|
49
|
+
clarifyTimeoutError: l.transitional(l.boolean),
|
|
50
|
+
legacyInterceptorReqResOrdering: l.transitional(l.boolean)
|
|
51
|
+
}, !1), n != null && (d.isFunction(n) ? e.paramsSerializer = {
|
|
52
|
+
serialize: n
|
|
53
|
+
} : y.assertOptions(n, {
|
|
54
|
+
encode: l.function,
|
|
55
|
+
serialize: l.function
|
|
56
|
+
}, !0)), e.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? e.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : e.allowAbsoluteUrls = !0), y.assertOptions(e, {
|
|
57
|
+
baseUrl: l.spelling("baseURL"),
|
|
58
|
+
withXsrfToken: l.spelling("withXSRFToken")
|
|
57
59
|
}, !0), e.method = (e.method || this.defaults.method || "get").toLowerCase();
|
|
58
|
-
let f =
|
|
59
|
-
|
|
60
|
-
|
|
60
|
+
let f = s && d.merge(
|
|
61
|
+
s.common,
|
|
62
|
+
s[e.method]
|
|
61
63
|
);
|
|
62
|
-
|
|
64
|
+
s && d.forEach(
|
|
63
65
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
64
|
-
(
|
|
65
|
-
delete a
|
|
66
|
+
(a) => {
|
|
67
|
+
delete s[a];
|
|
66
68
|
}
|
|
67
|
-
), e.headers =
|
|
68
|
-
const
|
|
69
|
-
let
|
|
70
|
-
this.interceptors.request.forEach(function(
|
|
71
|
-
typeof
|
|
69
|
+
), e.headers = A.concat(f, s);
|
|
70
|
+
const u = [];
|
|
71
|
+
let b = !0;
|
|
72
|
+
this.interceptors.request.forEach(function(o) {
|
|
73
|
+
if (typeof o.runWhen == "function" && o.runWhen(e) === !1)
|
|
74
|
+
return;
|
|
75
|
+
b = b && o.synchronous;
|
|
76
|
+
const m = e.transitional || T;
|
|
77
|
+
m && m.legacyInterceptorReqResOrdering ? u.unshift(o.fulfilled, o.rejected) : u.push(o.fulfilled, o.rejected);
|
|
72
78
|
});
|
|
73
|
-
const
|
|
74
|
-
this.interceptors.response.forEach(function(
|
|
75
|
-
|
|
79
|
+
const p = [];
|
|
80
|
+
this.interceptors.response.forEach(function(o) {
|
|
81
|
+
p.push(o.fulfilled, o.rejected);
|
|
76
82
|
});
|
|
77
|
-
let
|
|
78
|
-
if (!
|
|
79
|
-
const
|
|
80
|
-
for (
|
|
81
|
-
|
|
82
|
-
return
|
|
83
|
+
let h, i = 0, c;
|
|
84
|
+
if (!b) {
|
|
85
|
+
const a = [I.bind(this), void 0];
|
|
86
|
+
for (a.unshift(...u), a.push(...p), c = a.length, h = Promise.resolve(e); i < c; )
|
|
87
|
+
h = h.then(a[i++], a[i++]);
|
|
88
|
+
return h;
|
|
83
89
|
}
|
|
84
|
-
|
|
85
|
-
let
|
|
86
|
-
for (
|
|
87
|
-
const
|
|
90
|
+
c = u.length;
|
|
91
|
+
let R = e;
|
|
92
|
+
for (; i < c; ) {
|
|
93
|
+
const a = u[i++], o = u[i++];
|
|
88
94
|
try {
|
|
89
|
-
|
|
90
|
-
} catch (
|
|
91
|
-
|
|
95
|
+
R = a(R);
|
|
96
|
+
} catch (m) {
|
|
97
|
+
o.call(this, m);
|
|
92
98
|
break;
|
|
93
99
|
}
|
|
94
100
|
}
|
|
95
101
|
try {
|
|
96
|
-
|
|
97
|
-
} catch (
|
|
98
|
-
return Promise.reject(
|
|
102
|
+
h = I.call(this, R);
|
|
103
|
+
} catch (a) {
|
|
104
|
+
return Promise.reject(a);
|
|
99
105
|
}
|
|
100
|
-
for (
|
|
101
|
-
|
|
102
|
-
return
|
|
106
|
+
for (i = 0, c = p.length; i < c; )
|
|
107
|
+
h = h.then(p[i++], p[i++]);
|
|
108
|
+
return h;
|
|
103
109
|
}
|
|
104
110
|
getUri(t) {
|
|
105
111
|
t = w(this.defaults, t);
|
|
106
|
-
const e =
|
|
107
|
-
return
|
|
112
|
+
const e = U(t.baseURL, t.url, t.allowAbsoluteUrls);
|
|
113
|
+
return S(e, t.params, t.paramsSerializer);
|
|
108
114
|
}
|
|
109
115
|
}
|
|
110
116
|
d.forEach(["delete", "get", "head", "options"], function(t) {
|
|
111
|
-
|
|
112
|
-
return this.request(w(
|
|
117
|
+
q.prototype[t] = function(e, r) {
|
|
118
|
+
return this.request(w(r || {}, {
|
|
113
119
|
method: t,
|
|
114
120
|
url: e,
|
|
115
|
-
data: (
|
|
121
|
+
data: (r || {}).data
|
|
116
122
|
}));
|
|
117
123
|
};
|
|
118
124
|
});
|
|
119
125
|
d.forEach(["post", "put", "patch"], function(t) {
|
|
120
|
-
function e(
|
|
121
|
-
return function(
|
|
122
|
-
return this.request(w(
|
|
126
|
+
function e(r) {
|
|
127
|
+
return function(s, f, u) {
|
|
128
|
+
return this.request(w(u || {}, {
|
|
123
129
|
method: t,
|
|
124
|
-
headers:
|
|
130
|
+
headers: r ? {
|
|
125
131
|
"Content-Type": "multipart/form-data"
|
|
126
132
|
} : {},
|
|
127
|
-
url:
|
|
133
|
+
url: s,
|
|
128
134
|
data: f
|
|
129
135
|
}));
|
|
130
136
|
};
|
|
131
137
|
}
|
|
132
|
-
|
|
138
|
+
q.prototype[t] = e(), q.prototype[t + "Form"] = e(!0);
|
|
133
139
|
});
|
|
134
140
|
export {
|
|
135
|
-
|
|
141
|
+
q as default
|
|
136
142
|
};
|
package/AxiosError.js
CHANGED
|
@@ -1,9 +1,24 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import N from "./utils6.js";
|
|
2
|
+
class R extends Error {
|
|
3
|
+
static from(E, t, _, i, s, O) {
|
|
4
|
+
const e = new R(E.message, t || E.code, _, i, s);
|
|
5
|
+
return e.cause = E, e.name = E.name, O && Object.assign(e, O), e;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Create an Error with the specified message, config, error code, request and response.
|
|
9
|
+
*
|
|
10
|
+
* @param {string} message The error message.
|
|
11
|
+
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
|
12
|
+
* @param {Object} [config] The config.
|
|
13
|
+
* @param {Object} [request] The request.
|
|
14
|
+
* @param {Object} [response] The response.
|
|
15
|
+
*
|
|
16
|
+
* @returns {Error} The created error.
|
|
17
|
+
*/
|
|
18
|
+
constructor(E, t, _, i, s) {
|
|
19
|
+
super(E), this.name = "AxiosError", this.isAxiosError = !0, t && (this.code = t), _ && (this.config = _), i && (this.request = i), s && (this.response = s, this.status = s.status);
|
|
20
|
+
}
|
|
21
|
+
toJSON() {
|
|
7
22
|
return {
|
|
8
23
|
// Standard
|
|
9
24
|
message: this.message,
|
|
@@ -17,38 +32,24 @@ a.inherits(e, Error, {
|
|
|
17
32
|
columnNumber: this.columnNumber,
|
|
18
33
|
stack: this.stack,
|
|
19
34
|
// Axios
|
|
20
|
-
config:
|
|
35
|
+
config: N.toJSONObject(this.config),
|
|
21
36
|
code: this.code,
|
|
22
37
|
status: this.status
|
|
23
38
|
};
|
|
24
39
|
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
"ERR_NOT_SUPPORT",
|
|
39
|
-
"ERR_INVALID_URL"
|
|
40
|
-
// eslint-disable-next-line func-names
|
|
41
|
-
].forEach((t) => {
|
|
42
|
-
u[t] = { value: t };
|
|
43
|
-
});
|
|
44
|
-
Object.defineProperties(e, u);
|
|
45
|
-
Object.defineProperty(R, "isAxiosError", { value: !0 });
|
|
46
|
-
e.from = (t, i, o, E, r, c) => {
|
|
47
|
-
const s = Object.create(R);
|
|
48
|
-
return a.toFlatObject(t, s, function(h) {
|
|
49
|
-
return h !== Error.prototype;
|
|
50
|
-
}, (n) => n !== "isAxiosError"), e.call(s, t.message, i, o, E, r), s.cause = t, s.name = t.name, c && Object.assign(s, c), s;
|
|
51
|
-
};
|
|
40
|
+
}
|
|
41
|
+
R.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
|
|
42
|
+
R.ERR_BAD_OPTION = "ERR_BAD_OPTION";
|
|
43
|
+
R.ECONNABORTED = "ECONNABORTED";
|
|
44
|
+
R.ETIMEDOUT = "ETIMEDOUT";
|
|
45
|
+
R.ERR_NETWORK = "ERR_NETWORK";
|
|
46
|
+
R.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
|
|
47
|
+
R.ERR_DEPRECATED = "ERR_DEPRECATED";
|
|
48
|
+
R.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
|
|
49
|
+
R.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
|
|
50
|
+
R.ERR_CANCELED = "ERR_CANCELED";
|
|
51
|
+
R.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
|
|
52
|
+
R.ERR_INVALID_URL = "ERR_INVALID_URL";
|
|
52
53
|
export {
|
|
53
|
-
|
|
54
|
+
R as default
|
|
54
55
|
};
|
package/ButtonAction.js
CHANGED
package/CanceledError.js
CHANGED
|
@@ -1,11 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import e from "./AxiosError.js";
|
|
2
|
+
class n extends e {
|
|
3
|
+
/**
|
|
4
|
+
* A `CanceledError` is an object that is thrown when an operation is canceled.
|
|
5
|
+
*
|
|
6
|
+
* @param {string=} message The message.
|
|
7
|
+
* @param {Object=} config The config.
|
|
8
|
+
* @param {Object=} request The request.
|
|
9
|
+
*
|
|
10
|
+
* @returns {CanceledError} The created error.
|
|
11
|
+
*/
|
|
12
|
+
constructor(r, o, t) {
|
|
13
|
+
super(r ?? "canceled", e.ERR_CANCELED, o, t), this.name = "CanceledError", this.__CANCEL__ = !0;
|
|
14
|
+
}
|
|
5
15
|
}
|
|
6
|
-
i.inherits(l, r, {
|
|
7
|
-
__CANCEL__: !0
|
|
8
|
-
});
|
|
9
16
|
export {
|
|
10
|
-
|
|
17
|
+
n as default
|
|
11
18
|
};
|
package/Card.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as t, jsxs as M } from "react/jsx-runtime";
|
|
2
2
|
import { useMemo as j } from "react";
|
|
3
3
|
import s, { css as c } from "./styled-components.browser.esm.js";
|
|
4
|
-
import { IconCheck as F } from "./
|
|
4
|
+
import { IconCheck as F } from "./index3.js";
|
|
5
5
|
import { token as r } from "./token.js";
|
|
6
6
|
import { Frame as z } from "./Frame.js";
|
|
7
7
|
import { CardContext as S } from "./context.js";
|
package/Chip.js
CHANGED
|
@@ -2,7 +2,7 @@ import { jsxs as C, jsx as n } from "react/jsx-runtime";
|
|
|
2
2
|
import { forwardRef as T } from "react";
|
|
3
3
|
import d, { css as e } from "./styled-components.browser.esm.js";
|
|
4
4
|
import { useFocusRing as $ } from "./useFocusRing.js";
|
|
5
|
-
import { IconCancel as q } from "./
|
|
5
|
+
import { IconCancel as q } from "./index3.js";
|
|
6
6
|
import { token as o } from "./token.js";
|
|
7
7
|
import { textStyles as u } from "./textStyles.js";
|
|
8
8
|
import { makeInternalTokens as I } from "./makeInternalTokens.js";
|
package/CollectionCard.js
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as e, jsxs as g } from "react/jsx-runtime";
|
|
2
2
|
import s from "./styled-components.browser.esm.js";
|
|
3
|
-
import { IconOpenInNew as u } from "./
|
|
3
|
+
import { IconOpenInNew as u } from "./index3.js";
|
|
4
4
|
import { Card as n } from "./Card.js";
|
|
5
|
-
import { token as
|
|
5
|
+
import { token as a } from "./token.js";
|
|
6
6
|
import { useSelectionMode as C, useConfig as h } from "./ConfigContext.js";
|
|
7
7
|
import { __ as o } from "./index2.js";
|
|
8
8
|
import { useRouter as x } from "./useRouterStore.js";
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
function P({ collection:
|
|
12
|
-
const
|
|
13
|
-
return /* @__PURE__ */
|
|
9
|
+
import { pluralize as $ } from "./text.js";
|
|
10
|
+
import { useSelectionStore as b } from "./useSelectionStore.js";
|
|
11
|
+
function P({ collection: t, fadeIn: d = !0, isSelected: r, style: l }) {
|
|
12
|
+
const c = C(), [, m] = x(), { toggleCollection: p } = b(), { hideExternalAccess: f } = h();
|
|
13
|
+
return /* @__PURE__ */ e(w, { id: t.id, style: l, $fadeIn: d, children: /* @__PURE__ */ g(
|
|
14
14
|
n,
|
|
15
15
|
{
|
|
16
|
-
contextAction: !f && /* @__PURE__ */
|
|
16
|
+
contextAction: !f && /* @__PURE__ */ e(
|
|
17
17
|
n.ContextActionButton,
|
|
18
18
|
{
|
|
19
19
|
"aria-label": o("Open in new tab"),
|
|
20
20
|
onClick: () => {
|
|
21
|
-
window.open(
|
|
21
|
+
window.open(t.url, "_blank");
|
|
22
22
|
},
|
|
23
|
-
children: /* @__PURE__ */
|
|
23
|
+
children: /* @__PURE__ */ e(u, {})
|
|
24
24
|
}
|
|
25
25
|
),
|
|
26
26
|
selectButtonAriaLabel: r ? o("Deselect") : o("Select"),
|
|
27
|
-
onSelect:
|
|
28
|
-
|
|
27
|
+
onSelect: c === "MultiSelect" ? (i) => {
|
|
28
|
+
i.stopPropagation(), p(t);
|
|
29
29
|
} : void 0,
|
|
30
30
|
isSelected: r,
|
|
31
|
-
onClick: () =>
|
|
31
|
+
onClick: () => m({ page: "collection", collection: t }),
|
|
32
32
|
"aria-selected": r,
|
|
33
33
|
"data-testid": "asset-card",
|
|
34
34
|
children: [
|
|
35
|
-
/* @__PURE__ */
|
|
36
|
-
/* @__PURE__ */
|
|
37
|
-
/* @__PURE__ */
|
|
35
|
+
/* @__PURE__ */ e(n.Frame, { children: /* @__PURE__ */ e(n.Images, { children: t.thumbnailUrls.slice(0, 3).map((i) => /* @__PURE__ */ e(n.Img, { src: i, alt: t.name }, i)) }) }),
|
|
36
|
+
/* @__PURE__ */ e(n.Header, { title: t.name, "data-testid": "asset-name" }),
|
|
37
|
+
/* @__PURE__ */ e(I, { "data-testid": "collection-asset-count", children: $(t.assetCount, o("{} asset"), o("{} assets")) })
|
|
38
38
|
]
|
|
39
39
|
}
|
|
40
40
|
) });
|
|
@@ -42,13 +42,13 @@ function P({ collection: e, fadeIn: d = !0, isSelected: r, style: l }) {
|
|
|
42
42
|
const w = s.div`
|
|
43
43
|
width: 224px;
|
|
44
44
|
position: relative;
|
|
45
|
-
margin: ${
|
|
45
|
+
margin: ${a.spacing3};
|
|
46
46
|
align-self: flex-start;
|
|
47
|
-
${(
|
|
47
|
+
${(t) => t.$fadeIn ? "animation: var(--fade-in-down);" : ""}
|
|
48
48
|
`, I = s.div`
|
|
49
|
-
padding: 0 0 ${
|
|
50
|
-
margin-top: -${
|
|
51
|
-
font-size: ${
|
|
49
|
+
padding: 0 0 ${a.spacing4} ${a.spacing5};
|
|
50
|
+
margin-top: -${a.spacing2};
|
|
51
|
+
font-size: ${a.fontSize75};
|
|
52
52
|
color: rgba(0, 34, 51, 0.5);
|
|
53
53
|
`;
|
|
54
54
|
export {
|
package/CollectionItem.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import { jsxs as m, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import e from "./styled-components.browser.esm.js";
|
|
3
|
-
import { IconCollection as a } from "./
|
|
3
|
+
import { IconCollection as a } from "./index3.js";
|
|
4
4
|
import { Thumbnail as l } from "./Thumbnail.js";
|
|
5
5
|
import { token as i } from "./token.js";
|
|
6
|
-
import { __ as
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
6
|
+
import { __ as r } from "./index2.js";
|
|
7
|
+
import { pluralize as s } from "./text.js";
|
|
8
|
+
import { SelectedItemContainer as p } from "./SelectedItemContainer.js";
|
|
9
|
+
import { useSelectionStore as c } from "./useSelectionStore.js";
|
|
10
10
|
function z({ collection: t }) {
|
|
11
|
-
const
|
|
11
|
+
const { toggleCollection: n } = c();
|
|
12
12
|
return /* @__PURE__ */ m(
|
|
13
|
-
|
|
13
|
+
p,
|
|
14
14
|
{
|
|
15
15
|
title: t.name,
|
|
16
|
-
onRemove: () =>
|
|
16
|
+
onRemove: () => n(t),
|
|
17
17
|
children: [
|
|
18
18
|
/* @__PURE__ */ o(f, { children: /* @__PURE__ */ o(l, { variant: "clean", icon: /* @__PURE__ */ o(a, {}) }) }),
|
|
19
19
|
/* @__PURE__ */ o(g, { children: t.name }),
|
|
20
|
-
/* @__PURE__ */ o(h, { children:
|
|
20
|
+
/* @__PURE__ */ o(h, { children: s(t.assetCount, r("{} asset"), r("{} assets")) })
|
|
21
21
|
]
|
|
22
22
|
}
|
|
23
23
|
);
|
package/CollectionList.js
CHANGED
|
@@ -7,11 +7,11 @@ import { CollectionCard as L } from "./CollectionCard.js";
|
|
|
7
7
|
import { useDimensions as x } from "./useDimensions.js";
|
|
8
8
|
import { InfiniteScroll as I } from "./InfiniteScroll.js";
|
|
9
9
|
import { NoResults as N } from "./NoResults.js";
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
10
|
+
import { nbsp as k } from "./text.js";
|
|
11
|
+
import { useSearchStore as w } from "./useSearchStore.js";
|
|
12
|
+
import { useSelectedCollectionIds as M } from "./useSelectionStore.js";
|
|
13
13
|
function E(l) {
|
|
14
|
-
const [d, a] = S(null), { dimensions: i } = x(d), c =
|
|
14
|
+
const [d, a] = S(null), { dimensions: i } = x(d), c = M(), { setSearch: m } = w(), { data: o, isLoading: f, loadMore: u, hasNextPage: p } = l.connection, n = i !== void 0 ? Math.ceil(i.height / 184) : 0, s = i !== void 0 ? Math.round((i.width - 32) / 204) : 0;
|
|
15
15
|
return /* @__PURE__ */ h(
|
|
16
16
|
"div",
|
|
17
17
|
{
|
|
@@ -26,7 +26,7 @@ function E(l) {
|
|
|
26
26
|
{
|
|
27
27
|
rows: n,
|
|
28
28
|
columns: s,
|
|
29
|
-
title: /* @__PURE__ */ t(R, { children:
|
|
29
|
+
title: /* @__PURE__ */ t(R, { children: k })
|
|
30
30
|
}
|
|
31
31
|
),
|
|
32
32
|
o.tag === "Loaded" && o.value?.collections.nodes.length === 0 && /* @__PURE__ */ t(N, { onReset: () => m("collections", "") }),
|