@pixerate/editor-react 0.78.1 → 0.79.0

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.
@@ -18,8 +18,8 @@ import {
18
18
  useImageEditor,
19
19
  useImageEffectsTools,
20
20
  useImageHistogram
21
- } from "../chunk-S5SSL3ZO.js";
22
- import "../chunk-7RMNM3KC.js";
21
+ } from "../chunk-BVP43EWA.js";
22
+ import "../chunk-WOQ3H7KA.js";
23
23
  import "../chunk-ZQZAKUUM.js";
24
24
  import "../chunk-MO354USR.js";
25
25
  export {
package/dist/index.cjs CHANGED
@@ -4914,7 +4914,7 @@ function EffectThumbnail({ provider, effect, width = 96, height = 54, className
4914
4914
  var import_react42 = require("react");
4915
4915
  var import_effects2 = require("@pixerate/editor/effects");
4916
4916
  var import_jsx_runtime24 = require("react/jsx-runtime");
4917
- function EffectsBrowser({ provider, uses, onPick, thumbnails = true, title = "Effects", className = "" }) {
4917
+ function EffectsBrowser({ provider, uses, kinds, onPick, thumbnails = true, title = "Effects", className = "" }) {
4918
4918
  const [all, setAll] = (0, import_react42.useState)([]);
4919
4919
  const [query, setQuery] = (0, import_react42.useState)("");
4920
4920
  const [category, setCategory] = (0, import_react42.useState)("");
@@ -4940,8 +4940,8 @@ function EffectsBrowser({ provider, uses, onPick, thumbnails = true, title = "Ef
4940
4940
  live = false;
4941
4941
  };
4942
4942
  }, [provider, query, category, use]);
4943
- const allowed = (e) => (uses ? e.kind !== "motion" || uses.includes("motion") : e.kind !== "motion") && (!uses || e.uses.some((u) => uses.includes(u)));
4944
- const categories = (0, import_react42.useMemo)(() => [...new Set(all.filter(allowed).map((e) => e.category))], [all, uses]);
4943
+ const allowed = (e) => (!kinds || kinds.includes(e.kind)) && (uses ? e.kind !== "motion" || uses.includes("motion") : e.kind !== "motion") && (!uses || e.uses.some((u) => uses.includes(u)));
4944
+ const categories = (0, import_react42.useMemo)(() => [...new Set(all.filter(allowed).map((e) => e.category))], [all, uses, kinds]);
4945
4945
  const shown = found.filter(allowed);
4946
4946
  if (!provider)
4947
4947
  return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: `rounded-md border border-dashed border-border p-3 text-xs text-muted-foreground ${className}`, "data-effects-browser": "", "data-effects-unavailable": "", children: "No effects provider is registered, so effects cannot be added. Effects already in the document are kept." });