Skip to content

Commit bb16b11

Browse files
committed
format: run prettier on changed files
1 parent fa0dff4 commit bb16b11

5 files changed

Lines changed: 65 additions & 43 deletions

File tree

src/lib/stores/migration.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,10 @@ export const resourcesToMigrationForm = (resources: MigrationResource[]): Migrat
179179
formData.users.root = true;
180180
}
181181
if (
182-
includesAll(resources, [MigrationResources.Team, MigrationResources.Membership] as MigrationResource[])
182+
includesAll(resources, [
183+
MigrationResources.Team,
184+
MigrationResources.Membership
185+
] as MigrationResource[])
183186
) {
184187
formData.users.teams = true;
185188
}
@@ -195,7 +198,12 @@ export const resourcesToMigrationForm = (resources: MigrationResource[]): Migrat
195198
) {
196199
formData.databases.rows = true;
197200
}
198-
if (includesAll(resources, [MigrationResources.Bucket, MigrationResources.File] as MigrationResource[])) {
201+
if (
202+
includesAll(resources, [
203+
MigrationResources.Bucket,
204+
MigrationResources.File
205+
] as MigrationResource[])
206+
) {
199207
formData.storage.root = true;
200208
}
201209
if (resources.includes(MigrationResources.Function)) {

src/routes/(console)/(migration-wizard)/resource-form.svelte

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,10 @@
9797
9898
const shouldRenderGroup = (groupKey: string): boolean => {
9999
if (groupKey === 'storage') {
100-
return resources.includes(MigrationResources.Bucket) && resources.includes(MigrationResources.File);
100+
return (
101+
resources.includes(MigrationResources.Bucket) &&
102+
resources.includes(MigrationResources.File)
103+
);
101104
}
102105
103106
if (groupKey === 'functions') {

src/routes/(console)/project-[region]-[project]/databases/database-[database]/(entity)/helpers/sdk.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,12 @@ import {
1313
toSupportiveIndex
1414
} from './terminology';
1515

16-
import type { Models, OrderBy, TablesDBIndexType, DocumentsDBIndexType } from '@appwrite.io/console';
16+
import type {
17+
Models,
18+
OrderBy,
19+
TablesDBIndexType,
20+
DocumentsDBIndexType
21+
} from '@appwrite.io/console';
1722

1823
export type DatabaseSdkResult = {
1924
create: (

src/routes/(console)/project-[region]-[project]/databases/database-[database]/(entity)/views/indexes/create.svelte

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,11 @@
9191
// and the field already is not spatial type
9292
$effect(() => {
9393
const firstField = entity.fields.find((field) => field.key === fieldList.at(0)?.value);
94-
if (selectedType === DatabasesIndexType.Spatial && firstField && !isSpatialType(firstField)) {
94+
if (
95+
selectedType === DatabasesIndexType.Spatial &&
96+
firstField &&
97+
!isSpatialType(firstField)
98+
) {
9599
fieldList = [{ value: '', order: null, length: null }];
96100
}
97101
});
@@ -153,7 +157,11 @@
153157
export async function create() {
154158
const fieldType = terminology.field.lower.singular;
155159
156-
if (!key || !selectedType || (selectedType !== DatabasesIndexType.Spatial && addFieldDisabled)) {
160+
if (
161+
!key ||
162+
!selectedType ||
163+
(selectedType !== DatabasesIndexType.Spatial && addFieldDisabled)
164+
) {
157165
addNotification({
158166
type: 'error',
159167
message: `Selected ${fieldType} key or type invalid`

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

Lines changed: 35 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -983,30 +983,28 @@
983983
{row.$id}
984984
</Id>
985985

986-
<Popover let:show let:hide portal padding="none">
987-
<button
988-
on:mouseenter={show}
989-
on:mouseleave={hide}>
990-
<Button.Button
991-
size="xs"
992-
icon
993-
variant="secondary"
994-
on:click={() => {
995-
hide();
996-
previouslyFocusedElement =
997-
document.activeElement;
998-
$databaseRowSheetOptions.autoFocus = false;
999-
onSelectSheetOption(
1000-
'update',
1001-
null,
1002-
null,
1003-
'row',
1004-
row
1005-
);
1006-
}}>
1007-
<Icon icon={IconArrowExpand} size="s" />
1008-
</Button.Button>
1009-
</button>
986+
<Popover let:show let:hide portal padding="none">
987+
<button on:mouseenter={show} on:mouseleave={hide}>
988+
<Button.Button
989+
size="xs"
990+
icon
991+
variant="secondary"
992+
on:click={() => {
993+
hide();
994+
previouslyFocusedElement =
995+
document.activeElement;
996+
$databaseRowSheetOptions.autoFocus = false;
997+
onSelectSheetOption(
998+
'update',
999+
null,
1000+
null,
1001+
'row',
1002+
row
1003+
);
1004+
}}>
1005+
<Icon icon={IconArrowExpand} size="s" />
1006+
</Button.Button>
1007+
</button>
10101008

10111009
<svelte:fragment slot="tooltip">
10121010
<Layout.Stack
@@ -1018,20 +1016,20 @@
10181016
style="padding: var(--gap-XS, 6px) var(--gap-S, 8px);">
10191017
Expand row
10201018

1021-
<Layout.Stack
1022-
inline
1023-
gap="xxxs"
1024-
direction="row"
1025-
alignItems="center"
1026-
alignContent="center">
1027-
<Keyboard key="" />
1028-
<Keyboard key={'Enter'} autoWidth />
1029-
</Layout.Stack>
1019+
<Layout.Stack
1020+
inline
1021+
gap="xxxs"
1022+
direction="row"
1023+
alignItems="center"
1024+
alignContent="center">
1025+
<Keyboard key="" />
1026+
<Keyboard key={'Enter'} autoWidth />
10301027
</Layout.Stack>
1031-
</svelte:fragment>
1032-
</Popover>
1033-
</Layout.Stack>
1034-
</Spreadsheet.Cell>
1028+
</Layout.Stack>
1029+
</svelte:fragment>
1030+
</Popover>
1031+
</Layout.Stack>
1032+
</Spreadsheet.Cell>
10351033
{:else}
10361034
<Spreadsheet.Cell {root} {isEditable} column={columnId}>
10371035
{#if columnId === '$createdAt' || columnId === '$updatedAt'}

0 commit comments

Comments
 (0)