Skip to content

Commit 6bd1695

Browse files
authored
fix(explorer): enable editing internal namespace tables (#3553)
1 parent f043309 commit 6bd1695

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.changeset/clean-crabs-pump.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@latticexyz/explorer": patch
3+
---
4+
5+
Tables under internal namespace are now editable.

packages/explorer/src/app/(explorer)/[chainName]/worlds/[worldAddress]/explore/TablesViewer.tsx

+1-3
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ import {
1313
getSortedRowModel,
1414
useReactTable,
1515
} from "@tanstack/react-table";
16-
import { internalNamespaces } from "../../../../../../common";
1716
import { Button } from "../../../../../../components/ui/Button";
1817
import { Input } from "../../../../../../components/ui/Input";
1918
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from "../../../../../../components/ui/Table";
@@ -67,10 +66,9 @@ export function TablesViewer({ table, query, isLiveQuery }: Props) {
6766
},
6867
sortingFn: (rowA, rowB, columnId) => typeSortingFn(rowA, rowB, columnId, type),
6968
cell: ({ row }) => {
70-
const namespace = table?.namespace;
7169
const keySchema = getKeySchema(table);
7270
const value = row.getValue(name);
73-
if (!table || Object.keys(keySchema).includes(name) || internalNamespaces.includes(namespace)) {
71+
if (!table || Object.keys(keySchema).includes(name)) {
7472
return value;
7573
}
7674

0 commit comments

Comments
 (0)