feat: some moving around
This commit is contained in:
@ -1,7 +0,0 @@
|
||||
import { describe, it, expect } from 'vitest';
|
||||
|
||||
describe('sum test', () => {
|
||||
it('adds 1 + 2 to equal 3', () => {
|
||||
expect(1 + 2).toBe(3);
|
||||
});
|
||||
});
|
@ -8,14 +8,15 @@
|
||||
|
||||
export let input: NodeInput;
|
||||
export let value: any;
|
||||
export let id: string;
|
||||
</script>
|
||||
|
||||
{#if input.type === "float"}
|
||||
<Float bind:value />
|
||||
<Float {id} bind:value />
|
||||
{:else if input.type === "integer"}
|
||||
<Integer bind:value />
|
||||
<Integer {id} bind:value />
|
||||
{:else if input.type === "boolean"}
|
||||
<Checkbox bind:value />
|
||||
<Checkbox {id} bind:value />
|
||||
{:else if input.type === "select"}
|
||||
<Select bind:value labels={input.labels} />
|
||||
<Select {id} bind:value labels={input.labels} />
|
||||
{/if}
|
||||
|
@ -1,8 +1,10 @@
|
||||
<script lang="ts">
|
||||
export let value: boolean;
|
||||
|
||||
export let id: string;
|
||||
</script>
|
||||
|
||||
<input type="checkbox" bind:checked={value} />
|
||||
<input {id} type="checkbox" bind:checked={value} />
|
||||
|
||||
<style>
|
||||
input[type="checkbox"] {
|
||||
|
@ -3,9 +3,10 @@
|
||||
export let min = 0;
|
||||
export let max = 10;
|
||||
export let step = 0.1;
|
||||
export let id: string;
|
||||
</script>
|
||||
|
||||
<input type="number" bind:value {min} {max} {step} />
|
||||
<input {id} type="number" bind:value {min} {max} {step} />
|
||||
|
||||
<style>
|
||||
input {
|
||||
|
@ -3,9 +3,10 @@
|
||||
export let min = 0;
|
||||
export let max = 10;
|
||||
export let step = 1;
|
||||
export let id: string;
|
||||
</script>
|
||||
|
||||
<input type="number" bind:value {min} {max} {step} />
|
||||
<input {id} type="number" bind:value {min} {max} {step} />
|
||||
|
||||
<style>
|
||||
input {
|
||||
|
@ -1,9 +1,10 @@
|
||||
<script lang="ts">
|
||||
export let labels: string[] = [];
|
||||
export let value: number = 0;
|
||||
export let id: string;
|
||||
</script>
|
||||
|
||||
<select bind:value>
|
||||
<select {id} bind:value>
|
||||
{#each labels as label, i}
|
||||
<option value={i}>{label}</option>
|
||||
{/each}
|
||||
|
Reference in New Issue
Block a user