mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Merge pull request #393 from appwrite/fix-attributes-correct-inputs
fix: attributes user correct inputs
This commit is contained in:
3 files changed
+23
-3
No files matched your search
@@ -4,6 +4,7 @@
|
||||
import NullCheckbox from './nullCheckbox.svelte';
|
||||
|
||||
export let label: string;
|
||||
export let optionalText: string | undefined = undefined;
|
||||
export let showLabel = true;
|
||||
export let id: string;
|
||||
export let value = '';
|
||||
@@ -54,7 +55,7 @@
|
||||
</script>
|
||||
|
||||
<FormItem>
|
||||
<Label {required} hide={!showLabel} for={id}>
|
||||
<Label {required} {optionalText} hide={!showLabel} for={id}>
|
||||
{label}
|
||||
</Label>
|
||||
|
||||
|
||||
+2
-2
@@ -34,7 +34,7 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts">
|
||||
import { InputText, InputChoice } from '$lib/elements/forms';
|
||||
import { InputChoice, InputURL } from '$lib/elements/forms';
|
||||
|
||||
export let data: Partial<Models.AttributeUrl>;
|
||||
export let editing = false;
|
||||
@@ -44,7 +44,7 @@
|
||||
}
|
||||
</script>
|
||||
|
||||
<InputText
|
||||
<InputURL
|
||||
id="default"
|
||||
label="Default value"
|
||||
placeholder="Enter value"
|
||||
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
<script lang="ts">
|
||||
import InputEmail from '$lib/elements/forms/inputEmail.svelte';
|
||||
import type { Models } from '@appwrite.io/console';
|
||||
|
||||
export let id: string;
|
||||
export let label: string;
|
||||
export let value: string | null;
|
||||
export let optionalText: string | undefined = undefined;
|
||||
export let attribute: Models.AttributeUrl;
|
||||
</script>
|
||||
|
||||
<InputEmail
|
||||
{id}
|
||||
{label}
|
||||
{optionalText}
|
||||
placeholder="Enter URL"
|
||||
showLabel={!!label?.length}
|
||||
required={attribute.required}
|
||||
bind:value />
|
||||
Reference in new issue
Block a user