mirror of https://github.com/sveltejs/svelte
* move `is_readonly` into the common `Binding` AST class * prevents the following bindings from being emitted into the SSR code: * `bind:clientWidth` * `bind:clientHeight` * `bind:offsetWidth` * `bind:offsetHeight` * `bind:duration` * `bind:buffered` * `bind:seekable` * `bind:played` * `bind:value` (only for `input` with `type=file`)pull/2877/head
parent
04af24916a
commit
f0831202d9
@ -0,0 +1,4 @@
|
|||||||
|
<div></div>
|
||||||
|
<audio></audio>
|
||||||
|
<video></video>
|
||||||
|
<input type="file">
|
@ -0,0 +1,44 @@
|
|||||||
|
<script>
|
||||||
|
export let clientWidth = 1;
|
||||||
|
export let clientHeight = 2;
|
||||||
|
export let offsetHeight = 3;
|
||||||
|
export let offsetWidth = 4;
|
||||||
|
|
||||||
|
export let audioDuration = 5;
|
||||||
|
export let audioBuffered = 6;
|
||||||
|
export let audioSeekable = 7;
|
||||||
|
export let audioPlayed = 8;
|
||||||
|
|
||||||
|
export let videoDuration = 9;
|
||||||
|
export let videoBuffered = 10;
|
||||||
|
export let videoSeekable = 11;
|
||||||
|
export let videoPlayed = 12;
|
||||||
|
|
||||||
|
export let value = '/some/file';
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<div
|
||||||
|
bind:clientWidth
|
||||||
|
bind:clientHeight
|
||||||
|
bind:offsetWidth
|
||||||
|
bind:offsetHeight
|
||||||
|
></div>
|
||||||
|
|
||||||
|
<audio
|
||||||
|
bind:duration="{audioDuration}"
|
||||||
|
bind:buffered="{audioBuffered}"
|
||||||
|
bind:seekable="{audioSeekable}"
|
||||||
|
bind:played="{audioPlayed}"
|
||||||
|
></audio>
|
||||||
|
|
||||||
|
<video
|
||||||
|
bind:duration="{videoDuration}"
|
||||||
|
bind:buffered="{videoBuffered}"
|
||||||
|
bind:seekable="{videoSeekable}"
|
||||||
|
bind:played="{videoPlayed}"
|
||||||
|
></video>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
bind:value
|
||||||
|
/>
|
Loading…
Reference in new issue