Skip to content

Commit d7e19c1

Browse files
committed
fix: missing spatial deep check.
1 parent ea56166 commit d7e19c1

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

src/routes/(console)/project-[region]-[project]/databases/database-[database]/table-[table]/rows/edit.svelte

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,15 @@
1010
import { invalidate } from '$app/navigation';
1111
import { table, type Columns, PROHIBITED_ROW_KEYS } from '../store';
1212
import ColumnItem from './columns/columnItem.svelte';
13-
import { buildWildcardColumnsQuery, isRelationship, isRelationshipToMany } from './store';
13+
import {
14+
buildWildcardColumnsQuery,
15+
isRelationship,
16+
isRelationshipToMany,
17+
isSpatialType
18+
} from './store';
1419
import { Layout, Skeleton } from '@appwrite.io/pink-svelte';
1520
import { deepClone } from '$lib/helpers/object';
21+
import deepEqual from 'deep-equal';
1622
1723
const tableId = page.params.table;
1824
const databaseId = page.params.database;
@@ -90,6 +96,10 @@
9096
const workColumn = $work?.[column.key];
9197
const currentColumn = $doc?.[column.key];
9298
99+
if (isSpatialType(column)) {
100+
return deepEqual(workColumn, currentColumn);
101+
}
102+
93103
if (column.array) {
94104
return !symmetricDifference(Array.from(workColumn), Array.from(currentColumn)).length;
95105
}

src/routes/(console)/project-[region]-[project]/databases/database-[database]/table-[table]/spreadsheet.svelte

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -804,6 +804,7 @@
804804
on:expandKbdShortcut={({ detail }) => {
805805
const focusedRowId = detail.rowId;
806806
const focusedRow = $paginatedRows.items.find((row) => row.$id === focusedRowId);
807+
807808
previouslyFocusedElement = document.activeElement;
808809
onSelectSheetOption('update', null, 'row', focusedRow);
809810
}}>

0 commit comments

Comments
 (0)