a tool for shared writing and social publishing

add blocking functionality for administrators

+9 -1
+1 -1
app/[leaflet_id]/page.tsx
··· 34 34 .eq("id", props.params.leaflet_id) 35 35 .single(); 36 36 let rootEntity = res.data?.root_entity; 37 - if (!rootEntity || !res.data) 37 + if (!rootEntity || !res.data || res.data.blocked_by_admin) 38 38 return ( 39 39 <div className="w-screen h-screen flex place-items-center bg-bg-leaflet"> 40 40 <div className="bg-bg-page mx-auto p-4 border border-border rounded-md flex flex-col text-center justify-centergap-1 w-fit">
+7
supabase/database.types.ts
··· 380 380 } 381 381 permission_tokens: { 382 382 Row: { 383 + blocked_by_admin: boolean | null 383 384 id: string 384 385 root_entity: string 385 386 } 386 387 Insert: { 388 + blocked_by_admin?: boolean | null 387 389 id?: string 388 390 root_entity: string 389 391 } 390 392 Update: { 393 + blocked_by_admin?: boolean | null 391 394 id?: string 392 395 root_entity?: string 393 396 } ··· 815 818 metadata: Json 816 819 updated_at: string 817 820 }[] 821 + } 822 + operation: { 823 + Args: Record<PropertyKey, never> 824 + Returns: string 818 825 } 819 826 search: { 820 827 Args: {
+1
supabase/migrations/20250219192237_add_blocked_by_admin_column_to_permission_tokens.sql
··· 1 + alter table "public"."permission_tokens" add column "blocked_by_admin" boolean;