File tree Expand file tree Collapse file tree 3 files changed +22
-9
lines changed
onboarding/create-project
organization-[organization] Expand file tree Collapse file tree 3 files changed +22
-9
lines changed Original file line number Diff line number Diff line change 12
12
import { filterRegions } from ' $lib/helpers/regions' ;
13
13
import type { Snippet } from ' svelte' ;
14
14
15
- let projectName = $state (' ' );
16
- let id = $state (' ' );
17
- let regions = $state <Array <Models .ConsoleRegion >>([]);
18
- let region = $state (' ' );
19
- let showTitle = $state (true );
20
- let projects = $state <number | undefined >(undefined );
21
- let { submit }: { submit? : Snippet } = $props ();
15
+ let {
16
+ projectName = $bindable (' ' ),
17
+ id = $bindable (' ' ),
18
+ regions = [],
19
+ region = $bindable (' ' ),
20
+ showTitle = true ,
21
+ projects = undefined ,
22
+ submit,
23
+ onsubmit
24
+ }: {
25
+ projectName: string ;
26
+ id: string ;
27
+ regions: Array <Models .ConsoleRegion >;
28
+ region: string ;
29
+ showTitle: boolean ;
30
+ projects? : number ;
31
+ submit? : Snippet ;
32
+ onsubmit? : (event : Event ) => void ;
33
+ } = $props ();
22
34
23
35
let showCustomId = $state (false );
24
36
let projectsLimited = $derived (
35
47
<form
36
48
onsubmit ={(e ) => {
37
49
e .preventDefault ();
50
+ onsubmit ?.(e );
38
51
}}>
39
52
<Layout .Stack direction =" column" gap =" xxl" >
40
53
{#if showTitle }
Original file line number Diff line number Diff line change 99
99
bind:projectName
100
100
bind:id
101
101
bind:region
102
- on:submit ={createProject }>
102
+ showTitle ={true }
103
+ onsubmit ={createProject }>
103
104
<svelte:fragment slot =" submit" >
104
105
<Layout .Stack direction =" row" justifyContent =" flex-end" >
105
106
<Button .Button type =" submit" variant =" primary" size =" s" >
Original file line number Diff line number Diff line change 63
63
onSubmit ={create }
64
64
bind:error >
65
65
<CreateProject
66
- {projects }
67
66
showTitle ={false }
68
67
bind:id
69
68
bind:projectName ={name }
You can’t perform that action at this time.
0 commit comments