@proveanything/smartlinks-utils-ui 1.13.1 → 1.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-HKL24TFC.js → chunk-AWWWHHLL.js} +261 -103
- package/dist/chunk-AWWWHHLL.js.map +1 -0
- package/dist/components/AssetPicker/index.css +2 -16
- package/dist/components/AssetPicker/index.css.map +1 -1
- package/dist/components/AssetPicker/index.d.ts +1 -1
- package/dist/components/AssetPicker/index.js +1 -1
- package/dist/components/ConditionsEditor/index.css +2 -16
- package/dist/components/ConditionsEditor/index.css.map +1 -1
- package/dist/components/FontPicker/index.css +2 -16
- package/dist/components/FontPicker/index.css.map +1 -1
- package/dist/components/IconPicker/index.css +2 -16
- package/dist/components/IconPicker/index.css.map +1 -1
- package/dist/components/LinkPicker/index.css +2 -16
- package/dist/components/LinkPicker/index.css.map +1 -1
- package/dist/components/RecordsAdmin/index.css +2 -16
- package/dist/components/RecordsAdmin/index.css.map +1 -1
- package/dist/index.css +2 -16
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/{useAssets-tRkW00zx.d.ts → useAssets-Cs0OJs-x.d.ts} +6 -2
- package/package.json +1 -1
- package/dist/chunk-HKL24TFC.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { g as ASSET_MIME_FILTERS, A as AssetItem, h as AssetMimeFilter, a as AssetPicker, b as AssetPickerMode, c as AssetPickerProps, d as AssetPickerSelection, e as AssetScope, f as AssetViewMode, u as useAssets } from './useAssets-
|
|
1
|
+
export { g as ASSET_MIME_FILTERS, A as AssetItem, h as AssetMimeFilter, a as AssetPicker, b as AssetPickerMode, c as AssetPickerProps, d as AssetPickerSelection, e as AssetScope, f as AssetViewMode, u as useAssets } from './useAssets-Cs0OJs-x.js';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { ReactNode } from 'react';
|
|
4
4
|
export { ConditionsEditor } from './components/ConditionsEditor/index.js';
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { ASSET_MIME_FILTERS, AssetPicker, useAssets } from './chunk-
|
|
1
|
+
export { ASSET_MIME_FILTERS, AssetPicker, useAssets } from './chunk-AWWWHHLL.js';
|
|
2
2
|
export { ConditionsEditor } from './chunk-7UBXTFZQ.js';
|
|
3
3
|
export { IconPicker } from './chunk-JQPS5XPJ.js';
|
|
4
4
|
export { CATEGORY_FALLBACKS, CATEGORY_LABELS, FontPicker, GOOGLE_FONTS_CATALOG, getGoogleFontUrl } from './chunk-OTJV62XV.js';
|
|
@@ -228,8 +228,11 @@ interface UseAssetsReturn {
|
|
|
228
228
|
loading: boolean;
|
|
229
229
|
error: string | null;
|
|
230
230
|
refresh: () => Promise<void>;
|
|
231
|
-
|
|
232
|
-
|
|
231
|
+
/** Optional `scopeOverride` lets callers upload to a wider/narrower scope
|
|
232
|
+
* than the hook's default (e.g. "make global" toggles upload to collection
|
|
233
|
+
* even when the picker is showing the product tab). */
|
|
234
|
+
upload: (file: File, onProgress?: (pct: number) => void, scopeOverride?: AssetScope) => Promise<AssetItem | null>;
|
|
235
|
+
uploadFromUrl: (url: string, name?: string, scopeOverride?: AssetScope) => Promise<AssetItem | null>;
|
|
233
236
|
/**
|
|
234
237
|
* Server-side ingest — the SmartLinks backend fetches the URL directly and
|
|
235
238
|
* stores it in the CDN. Use for AI-generated images, stock photos, or any
|
|
@@ -238,6 +241,7 @@ interface UseAssetsReturn {
|
|
|
238
241
|
uploadFromRemoteUrl: (url: string, opts?: {
|
|
239
242
|
name?: string;
|
|
240
243
|
metadata?: Record<string, any>;
|
|
244
|
+
scopeOverride?: AssetScope;
|
|
241
245
|
}) => Promise<AssetItem | null>;
|
|
242
246
|
/**
|
|
243
247
|
* Soft-delete via `asset.deleteAdmin` (recoverable for `graceDays`, default 30).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@proveanything/smartlinks-utils-ui",
|
|
3
|
-
"version": "1.13.
|
|
3
|
+
"version": "1.13.2",
|
|
4
4
|
"description": "Reusable React components for SmartLinks microapps — Asset Picker, Conditions Editor, Icon Picker, and more.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|