mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
refactor: pr review
This commit is contained in:
1 parent
2c57014736
commit
fa22a49114
5 files changed
+16
-20
No files matched your search
@@ -70,14 +70,14 @@
|
||||
bind:value
|
||||
bind:this={element}
|
||||
on:invalid={handleInvalid} />
|
||||
<ul
|
||||
class="buttons-list u-cross-center u-gap-8 u-position-absolute u-inset-block-start-8 u-inset-block-end-8 u-inset-inline-end-12">
|
||||
{#if !required}
|
||||
{#if !required}
|
||||
<ul
|
||||
class="buttons-list u-cross-center u-gap-8 u-position-absolute u-inset-block-start-8 u-inset-block-end-8 u-inset-inline-end-12">
|
||||
<li class="buttons-list-item">
|
||||
<NullCheckbox checked={value === null} on:change={handleNullChange} />
|
||||
</li>
|
||||
{/if}
|
||||
</ul>
|
||||
</ul>
|
||||
{/if}
|
||||
</div>
|
||||
{#if error}
|
||||
<Helper type="warning">{error}</Helper>
|
||||
|
||||
+2
-2
@@ -59,9 +59,9 @@
|
||||
label="Default value"
|
||||
attribute={{
|
||||
key: data.key,
|
||||
type: 'enum',
|
||||
type: 'string',
|
||||
status: 'enabled',
|
||||
format: 'string',
|
||||
format: 'enum',
|
||||
elements: data.elements ?? [],
|
||||
required: data.required,
|
||||
default: data.default
|
||||
|
||||
-1
@@ -8,7 +8,6 @@
|
||||
key: string,
|
||||
data: Partial<Models.AttributeString>
|
||||
) {
|
||||
console.log(data.default, typeof data.default);
|
||||
await sdk.forProject.databases.createStringAttribute(
|
||||
databaseId,
|
||||
collectionId,
|
||||
|
||||
+8
-11
@@ -1,20 +1,19 @@
|
||||
<script lang="ts">
|
||||
import { Wizard } from '$lib/layout';
|
||||
import { beforeNavigate, invalidate } from '$app/navigation';
|
||||
import { attributes } from './store';
|
||||
import { sdk } from '$lib/stores/sdk';
|
||||
import { page } from '$app/stores';
|
||||
import { onDestroy, onMount } from 'svelte';
|
||||
import { Submit, trackError, trackEvent } from '$lib/actions/analytics';
|
||||
import { Dependencies } from '$lib/constants';
|
||||
import { Wizard } from '$lib/layout';
|
||||
import type { WizardStepsType } from '$lib/layout/wizard.svelte';
|
||||
import { addNotification } from '$lib/stores/notifications';
|
||||
import { sdk } from '$lib/stores/sdk';
|
||||
import { wizard } from '$lib/stores/wizard';
|
||||
import { ID } from '@appwrite.io/console';
|
||||
import { onDestroy, onMount } from 'svelte';
|
||||
import { attributes } from './store';
|
||||
import Step1 from './wizard/step1.svelte';
|
||||
import Step2 from './wizard/step2.svelte';
|
||||
import { createDocument } from './wizard/store';
|
||||
import type { WizardStepsType } from '$lib/layout/wizard.svelte';
|
||||
import { Dependencies } from '$lib/constants';
|
||||
import { Submit, trackEvent, trackError } from '$lib/actions/analytics';
|
||||
import { ID } from '@appwrite.io/console';
|
||||
import { log } from 'logrocket';
|
||||
|
||||
const databaseId = $page.params.database;
|
||||
const collectionId = $page.params.collection;
|
||||
@@ -33,8 +32,6 @@
|
||||
}
|
||||
|
||||
async function create() {
|
||||
console.log($createDocument.document);
|
||||
|
||||
try {
|
||||
await sdk.forProject.databases.createDocument(
|
||||
databaseId,
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@
|
||||
export let disabled = false;
|
||||
</script>
|
||||
|
||||
{#if attribute.size >= 52}
|
||||
{#if attribute.size >= 50}
|
||||
<InputTextarea
|
||||
{id}
|
||||
{label}
|
||||
|
||||
Reference in new issue
Block a user