gradio/js/video
Abubakar Abid 8dd6f4bc19
Handle the case where examples is null for all components (#7192)
* handle null examples

* add changeset

* add changeset

* lint

* merge conflict

* fixes

* add changeset

* stories

* feedback

* examples

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
2024-01-29 16:51:22 -08:00
..
shared Allow download button for interactive Audio and Video components (#7104) 2024-01-23 11:33:59 +01:00
CHANGELOG.md chore: update versions (#7083) 2024-01-25 16:10:24 -08:00
Example.svelte Handle the case where examples is null for all components (#7192) 2024-01-29 16:51:22 -08:00
Index.svelte Allow download button for interactive Audio and Video components (#7104) 2024-01-23 11:33:59 +01:00
index.ts Version 4 development branch (#5498) 2023-10-31 04:46:02 +00:00
package.json chore: update versions (#7083) 2024-01-25 16:10:24 -08:00
README.md Version 4 development branch (#5498) 2023-10-31 04:46:02 +00:00
Video.stories.svelte Allow download button for interactive Audio and Video components (#7104) 2024-01-23 11:33:59 +01:00
Video.test.ts Version 4 development branch (#5498) 2023-10-31 04:46:02 +00:00

@gradio/video

<script>
	import { BaseInteractiveVideo, BaseStaticVideo, BasePlayer } from "@gradio/button";
	import type { FileData } from "@gradio/upload";
	import type { Gradio } from "@gradio/utils";
	export let _video: FileData;
</script>

<StaticVideo
	value={_video}
	{label}
	{show_label}
	{autoplay}
	{show_share_button}
	i18n={gradio.i18n}
/>

<Video
	value={_video}
	{label}
	{show_label}
	source={"upload"}
	{mirror_webcam}
	{include_audio}
	{autoplay}
	i18n={gradio.i18n}
>
	<p>Upload Video Here</p>
</Video>

<BasePlayer
	src={value.data}
	{autoplay}
	on:play
	on:pause
	on:stop
	on:end
	mirror={false}
	{label}
/>