gradio/js/image
Hannah 04b7d327ec
Allow drag and replace image in gr.Image and Multimodal textbox (#9031)
* allow dragging image over current image value in imageeditor

* add changeset

* add drag to image

* add changeset

* type fixes

* tweak

* tweak

* add test

* add changeset

* revert image editor changes (i.e. give up)

* add changeset

* add changeset

* tweak

* Ensure drag and drop functionality works in Multimodal textbox (#9125)

* allow uploading files via drag

* wrap tweak

* * fix input
* improve a11y
* fix thumbnail scrolling

* tweak

* add changeset

* add changeset

---------

Co-authored-by: pngwn <hello@pngwn.io>
Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>
2024-08-19 15:46:54 +01:00
..
shared Allow drag and replace image in gr.Image and Multimodal textbox (#9031) 2024-08-19 15:46:54 +01:00
CHANGELOG.md chore: update versions (#8960) 2024-08-08 11:20:08 +01:00
Example.svelte
Image.stories.svelte Add min/max-imize button to gr.Image and gr.Gallery (#8964) 2024-08-05 23:45:14 +01:00
Image.test.ts Initial SSR refactor (#9102) 2024-08-14 15:17:36 +01:00
ImageExample.stories.svelte
Index.svelte Allow drag and replace image in gr.Image and Multimodal textbox (#9031) 2024-08-19 15:46:54 +01:00
package.json setup npm-previews of all packages (#9118) 2024-08-15 12:56:17 +01:00
README.md

@gradio/image

<script>
	import { BaseImageUploader, BaseStaticImage, Webcam, BaseExample } from "@gradio/image";
</script>

BaseImageUploader

	export let sources: ("clipboard" | "webcam" | "upload")[] = [
		"upload",
		"clipboard",
		"webcam"
	];
	export let streaming = false;
	export let pending = false;
	export let mirror_webcam: boolean;
	export let selectable = false;
	export let root: string;
	export let i18n: I18nFormatter;

BaseStaticImage

	export let value: null | FileData;
	export let label: string | undefined = undefined;
	export let show_label: boolean;
	export let show_download_button = true;
	export let selectable = false;
	export let show_share_button = false;
	export let root: string;
	export let i18n: I18nFormatter;

Webcam

	export let streaming = false;
	export let pending = false;

	export let mode: "image" | "video" = "image";
	export let mirror_webcam: boolean;
	export let include_audio: boolean;
	export let i18n: I18nFormatter;

BaseExample

	export let value: string;
	export let samples_dir: string;
	export let type: "gallery" | "table";
	export let selected = false;