Skip to content

Commit 416df4a

Browse files
authored
chore: respect catalog version for postgrest-js (supabase#39837)
1 parent 45713e2 commit 416df4a

File tree

5 files changed

+21
-12
lines changed

5 files changed

+21
-12
lines changed

.github/workflows/update-js-libs.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ jobs:
4848
# Update @supabase/realtime-js
4949
sed -i "s/'@supabase\/realtime-js': .*/'@supabase\/realtime-js': ${{ github.event.inputs.version }}/" pnpm-workspace.yaml
5050
51+
# Update @supabase/postgrest-js
52+
sed -i "s/'@supabase\/postgrest-js': .*/'@supabase\/postgrest-js': ${{ github.event.inputs.version }}/" pnpm-workspace.yaml
53+
5154
echo "Updated pnpm-workspace.yaml:"
5255
cat pnpm-workspace.yaml
5356
@@ -69,6 +72,7 @@ jobs:
6972
- Updated @supabase/supabase-js to ${{ github.event.inputs.version }}
7073
- Updated @supabase/auth-js to ${{ github.event.inputs.version }}
7174
- Updated @supabase/realtime-js to ${{ github.event.inputs.version }}
75+
- Updated @supabase/postgest-js to ${{ github.event.inputs.version }}
7276
- Refreshed pnpm-lock.yaml
7377
7478
This PR was created automatically.

apps/ui-library/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
"@radix-ui/react-toggle-group": "*",
4848
"@radix-ui/react-tooltip": "*",
4949
"@react-router/fs-routes": "^7.4.0",
50-
"@supabase/postgrest-js": "*",
50+
"@supabase/postgrest-js": "catalog:",
5151
"@supabase/supa-mdx-lint": "0.2.6-alpha",
5252
"@tanstack/react-query": "^5.83.0",
5353
"@supabase/vue-blocks": "workspace:*",

apps/ui-library/registry/default/blocks/infinite-query-hook/hooks/use-infinite-query.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
'use client'
22

33
import { createClient } from '@/registry/default/fixtures/lib/supabase/client'
4-
import { PostgrestQueryBuilder } from '@supabase/postgrest-js'
4+
import { PostgrestQueryBuilder, type PostgrestClientOptions } from '@supabase/postgrest-js'
55
import { type SupabaseClient } from '@supabase/supabase-js'
66
import { useEffect, useRef, useSyncExternalStore } from 'react'
77

@@ -44,8 +44,16 @@ type SupabaseTableName = keyof DatabaseSchema['Tables']
4444
// Extracts the table definition from the database type
4545
type SupabaseTableData<T extends SupabaseTableName> = DatabaseSchema['Tables'][T]['Row']
4646

47+
// Default client options for PostgrestQueryBuilder
48+
type DefaultClientOptions = PostgrestClientOptions
49+
4750
type SupabaseSelectBuilder<T extends SupabaseTableName> = ReturnType<
48-
PostgrestQueryBuilder<DatabaseSchema, DatabaseSchema['Tables'][T], T>['select']
51+
PostgrestQueryBuilder<
52+
DefaultClientOptions,
53+
DatabaseSchema,
54+
DatabaseSchema['Tables'][T],
55+
T
56+
>['select']
4957
>
5058

5159
// A function that modifies the query. Can be used to sort, filter, etc. If .range is used, it will be overwritten.

pnpm-lock.yaml

Lines changed: 5 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pnpm-workspace.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ catalog:
88
'@supabase/auth-js': 2.75.1
99
'@supabase/realtime-js': 2.75.1
1010
'@supabase/supabase-js': 2.75.1
11+
'@supabase/postgrest-js': 2.75.1
1112
'@types/node': ^22.0.0
1213
'@types/react': ^18.3.0
1314
'@types/react-dom': ^18.3.0

0 commit comments

Comments
 (0)