From 484857c069fb64a78fce32de755eed175131bdd5 Mon Sep 17 00:00:00 2001 From: "@greweb" Date: Fri, 12 Jun 2026 23:19:03 +0200 Subject: [PATCH] fix: gl-react-blur tsc declaration build + run full build in PR CI The connectSize cast to React.ComponentType needs an unknown intermediate (TS2352), which broke tsc -b on master's Release run. PR CI didn't catch it because ci-tests only ran the babel loop, never tsc: it now runs the full pnpm build so type errors fail PRs, not the Release workflow. Co-Authored-By: Claude Fable 5 --- .github/workflows/ci-tests.yml | 7 +++---- packages/gl-react-blur/src/Blur.tsx | 2 +- packages/gl-react-blur/src/Blur1D.tsx | 2 +- packages/gl-react-blur/src/BlurV.tsx | 2 +- packages/gl-react-blur/src/BlurV1D.tsx | 2 +- 5 files changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-tests.yml b/.github/workflows/ci-tests.yml index e3e1cc9d..0e41001a 100644 --- a/.github/workflows/ci-tests.yml +++ b/.github/workflows/ci-tests.yml @@ -19,9 +19,8 @@ jobs: node-version: 24 cache: pnpm - run: pnpm install --frozen-lockfile + # Full build (babel + tsc -b declarations) so PRs catch type errors + # before the Release workflow does - name: Build gl-react packages - run: | - for d in packages/gl-react packages/gl-react-dom packages/gl-react-headless packages/gl-react-image packages/gl-react-blur; do - pnpm exec babel --root-mode upward --source-maps --extensions '.ts,.tsx' -d "$d/lib" "$d/src" - done + run: pnpm build - run: xvfb-run -s "-ac -screen 0 1280x1024x24" pnpm test diff --git a/packages/gl-react-blur/src/Blur.tsx b/packages/gl-react-blur/src/Blur.tsx index 2fa01ef5..7a8d1c7a 100644 --- a/packages/gl-react-blur/src/Blur.tsx +++ b/packages/gl-react-blur/src/Blur.tsx @@ -36,6 +36,6 @@ const Blur = connectSize( ); return rec(passes); } -) as React.ComponentType; +) as unknown as React.ComponentType; export default Blur; diff --git a/packages/gl-react-blur/src/Blur1D.tsx b/packages/gl-react-blur/src/Blur1D.tsx index 5756cb38..3b1fc514 100644 --- a/packages/gl-react-blur/src/Blur1D.tsx +++ b/packages/gl-react-blur/src/Blur1D.tsx @@ -43,6 +43,6 @@ const Blur1D = connectSize( uniforms={{ t, resolution: [width, height], direction }} /> ) -) as React.ComponentType; +) as unknown as React.ComponentType; export default Blur1D; diff --git a/packages/gl-react-blur/src/BlurV.tsx b/packages/gl-react-blur/src/BlurV.tsx index d43daf60..46c8ae74 100644 --- a/packages/gl-react-blur/src/BlurV.tsx +++ b/packages/gl-react-blur/src/BlurV.tsx @@ -39,6 +39,6 @@ const BlurV = connectSize( ); return rec(passes); } -) as React.ComponentType; +) as unknown as React.ComponentType; export default BlurV; diff --git a/packages/gl-react-blur/src/BlurV1D.tsx b/packages/gl-react-blur/src/BlurV1D.tsx index 2a50dc22..f0728b15 100644 --- a/packages/gl-react-blur/src/BlurV1D.tsx +++ b/packages/gl-react-blur/src/BlurV1D.tsx @@ -45,6 +45,6 @@ const BlurV1D = connectSize( uniforms={{ t, map, resolution: [width, height], direction }} /> ) -) as React.ComponentType; +) as unknown as React.ComponentType; export default BlurV1D;