Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

Update text for RLS in table editor

Joshen Limebd559d9c9a7
diff --git a/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/TableEditor.tsx b/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/TableEditor.tsx
index 09928532ab9..6329a56ae4c 100644
--- a/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/TableEditor.tsx
+++ b/studio/components/interfaces/TableGridEditor/SidePanelEditor/TableEditor/TableEditor.tsx
@@ -17,6 +17,7 @@ import {
generateTableFieldFromPostgresTable,
formatImportedContentToColumnFields,
} from './TableEditor.utils'
+import InformationBox from 'components/ui/InformationBox'
interface Props {
table?: PostgresTable
@@ -215,9 +216,9 @@ const TableEditor: FC<Props> = ({
<p>
Restrict access to your table by enabling RLS and writing Postgres policies.
</p>
-
<p>
- If RLS is not enabled, anyone with the anon key can modify and delete your data.
+ RLS is secure by default - all normal access to this table must be allowed by a
+ policy.
</p>
{!tableFields.isRLSEnabled && (
<Alert
@@ -225,12 +226,10 @@ const TableEditor: FC<Props> = ({
variant="warning"
className="!px-4 !py-3 mt-3"
// @ts-ignore
- title={
- <span className="text-amber-1100 text-sm">
- Turning off RLS means that you are allowing anonymous access to your table
- </span>
- }
- />
+ title="Turning off RLS means that you are allowing anonymous access to your table"
+ >
+ As such, anyone with the anonymous key can modify or delete your data.
+ </Alert>
)}
</>
}
diff --git a/studio/pages/project/[ref]/auth/policies.tsx b/studio/pages/project/[ref]/auth/policies.tsx
index 14fc0d2a805..26a0ceb74ea 100644
--- a/studio/pages/project/[ref]/auth/policies.tsx
+++ b/studio/pages/project/[ref]/auth/policies.tsx
@@ -242,7 +242,7 @@ const AuthPoliciesTables: FC<AuthPoliciesTablesProps> = observer(({ tables, hasP
</p>
<p className="text-sm">
This is also known as Row-Level Security (RLS). Each policy is attached to a
- table, and the policy is executed everytime a time is accessed.
+ table, and the policy is executed each time its accessed.
</p>
</div>
}