update more tests

pull/1864/head
Rich Harris 7 years ago
parent 780c6803a5
commit 48a0a911fe

@ -13,7 +13,7 @@
} }
</script> </script>
<select bind:value="selected.letter"> <select bind:value={selected.letter}>
{#each uppercase as letter} {#each uppercase as letter}
<option value="{letter}">{letter}</option> <option value="{letter}">{letter}</option>
{/each} {/each}

@ -5,7 +5,7 @@
</select> </select>
<label> <label>
<input type='checkbox' bind:checked='selected.done'> {selected.description} <input type='checkbox' bind:checked={selected.done}> {selected.description}
</label> </label>
<h2>Pending tasks</h2> <h2>Pending tasks</h2>

@ -7,7 +7,7 @@
</script> </script>
{#each items as item} {#each items as item}
<div><input type='checkbox' bind:checked='item.completed'><p>{item.description}</p></div> <div><input type='checkbox' bind:checked={item.completed}><p>{item.description}</p></div>
{/each} {/each}
<p>{numCompleted()} completed</p> <p>{numCompleted()} completed</p>

@ -7,5 +7,5 @@
</script> </script>
{#each cats as cat (cat.name)} {#each cats as cat (cat.name)}
<input type="checkbox" bind:checked="cat.checked" on:change="{someCheck}"> <input type="checkbox" bind:checked={cat.checked} on:change="{someCheck}">
{/each} {/each}

@ -1,2 +1,2 @@
<h1>Hello {component.name}!</h1> <h1>Hello {component.name}!</h1>
<input bind:value="component.name"/> <input bind:value={component.name}/>

@ -1,3 +1,3 @@
{#each items as item} {#each items as item}
<div><input bind:value='item.description'><p>{item.description}</p></div> <div><input bind:value={item.description}><p>{item.description}</p></div>
{/each} {/each}

@ -1,4 +1,6 @@
export default { export default {
solo: 1,
props: { props: {
user: { user: {
name: 'alice', name: 'alice',

@ -1,2 +1,2 @@
<input bind:value='user.name'> <input bind:value={user.name}>
<p>hello {user.name}</p> <p>hello {user.name}</p>

@ -1,5 +1,5 @@
{#each items as item} {#each items as item}
<select bind:value="item.value"> <select bind:value={item.value}>
<option value="hullo">Hullo</option> <option value="hullo">Hullo</option>
<option value="world">World</option> <option value="world">World</option>
</select> </select>

@ -8,5 +8,5 @@
</script> </script>
{#if x} {#if x}
<Widget bind:foo='bar.baz'/> <Widget bind:foo={bar.baz}/>
{/if} {/if}

@ -30,7 +30,7 @@
</script> </script>
<ComponentSelector {components} bind:selectedComponent/> <ComponentSelector {components} bind:selectedComponent/>
<Editor bind:code='selectedComponent.source' /> <Editor bind:code={selectedComponent.source} />
<pre> <pre>
{compiled} {compiled}

@ -6,6 +6,6 @@
}; };
</script> </script>
<Widget bind:value='deep.name'/> <Widget bind:value={deep.name}/>
<p>{deep.name}</p> <p>{deep.name}</p>

@ -6,7 +6,7 @@
</script> </script>
{#each a as x} {#each a as x}
<Widget bind:value='x.name'/> <Widget bind:value={x.name}/>
{/each} {/each}
<p>{a.map(getName).join(', ')}</p> <p>{a.map(getName).join(', ')}</p>

@ -9,6 +9,6 @@
}; };
</script> </script>
<Nested ref:nested bind:field1="myObject.field1" bind:field2="myObject.field2" /> <Nested ref:nested bind:field1={myObject.field1} bind:field2={myObject.field2} />
<p>field1: {myObject.field1}</p> <p>field1: {myObject.field1}</p>
<p>field2: {myObject.field2}</p> <p>field2: {myObject.field2}</p>

@ -1,5 +1,5 @@
{#each items as item} {#each items as item}
<select bind:value="item.id"> <select bind:value={item.id}>
<option value='a'>a</option> <option value='a'>a</option>
<option value='b'>b</option> <option value='b'>b</option>
</select> </select>

@ -1 +1 @@
<input bind:value='foo.bar.baz'> <input bind:value={foo.bar.baz}>

@ -1 +1 @@
<svelte:window bind:innerWidth='foo.bar.baz'/> <svelte:window bind:innerWidth={foo.bar.baz}/>
Loading…
Cancel
Save