@react-three/postprocessing 2.14.11 → 2.14.12

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.
@@ -1,14 +1,13 @@
1
- import React from 'react';
1
+ /// <reference types="react" />
2
2
  import { ChromaticAberrationEffect } from 'postprocessing';
3
- import { ReactThreeFiber } from '@react-three/fiber';
4
- export type ChromaticAberrationProps = ConstructorParameters<typeof ChromaticAberrationEffect>[0] & Partial<{
5
- offset: ReactThreeFiber.Vector2;
6
- }>;
7
- export declare const ChromaticAberration: React.ForwardRefExoticComponent<{
3
+ import { type EffectProps } from '../util';
4
+ export type ChromaticAberrationProps = EffectProps<typeof ChromaticAberrationEffect>;
5
+ export declare const ChromaticAberration: import("react").ForwardRefExoticComponent<Omit<import("@react-three/fiber").ExtendedColors<import("@react-three/fiber").Overwrite<Partial<ChromaticAberrationEffect>, import("@react-three/fiber").NodeProps<ChromaticAberrationEffect, typeof ChromaticAberrationEffect>>> & {
8
6
  blendFunction?: import("postprocessing").BlendFunction | undefined;
9
7
  offset?: import("three").Vector2 | undefined;
10
8
  radialModulation: boolean;
11
9
  modulationOffset: number;
12
- } & Partial<{
13
- offset: ReactThreeFiber.Vector2;
14
- }> & React.RefAttributes<ChromaticAberrationEffect>>;
10
+ } & {
11
+ blendFunction?: import("postprocessing").BlendFunction | undefined;
12
+ opacity?: number | undefined;
13
+ }, "ref"> & import("react").RefAttributes<typeof ChromaticAberrationEffect>>;
package/dist/index.cjs CHANGED
@@ -328,11 +328,7 @@ const Bloom = wrapEffect(postprocessing.BloomEffect, {
328
328
  blendFunction: postprocessing.BlendFunction.ADD
329
329
  });
330
330
  const BrightnessContrast = wrapEffect(postprocessing.BrightnessContrastEffect);
331
- const ChromaticAberration = React.forwardRef(function ChromaticAberration2(props, ref) {
332
- const offset = useVector2(props, "offset");
333
- const effect = React.useMemo(() => new postprocessing.ChromaticAberrationEffect({ ...props, offset }), [offset, props]);
334
- return /* @__PURE__ */ jsxRuntime.jsx("primitive", { ref, object: effect, dispose: null });
335
- });
331
+ const ChromaticAberration = wrapEffect(postprocessing.ChromaticAberrationEffect);
336
332
  const ColorAverage = React.forwardRef(function ColorAverage2({ blendFunction = postprocessing.BlendFunction.NORMAL }, ref) {
337
333
  const effect = React.useMemo(() => new postprocessing.ColorAverageEffect(blendFunction), [blendFunction]);
338
334
  return /* @__PURE__ */ jsxRuntime.jsx("primitive", { ref, object: effect, dispose: null });