@gradio/multimodaltextbox 0.10.20 → 0.10.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @gradio/multimodaltextbox
2
2
 
3
+ ## 0.10.21
4
+
5
+ ### Fixes
6
+
7
+ - [#12019](https://github.com/gradio-app/gradio/pull/12019) [`81fc464`](https://github.com/gradio-app/gradio/commit/81fc4647cdc9ffd724b69ec7286f1d686571062a) - Fix MultimodalTextbox autofocus issue when file_types is specified. Thanks @freddyaboulton!
8
+
9
+ ## 0.10.20
10
+
11
+ ### Dependency updates
12
+
13
+ - @gradio/client@1.19.1
14
+
3
15
  ## 0.10.20
4
16
 
5
17
  ### Fixes
package/Index.svelte CHANGED
@@ -123,6 +123,8 @@
123
123
  | "upload,microphone"
124
124
  | "microphone"
125
125
  | "microphone,upload";
126
+
127
+ $: file_types_string = (file_types || []).join(",") || null;
126
128
  </script>
127
129
 
128
130
  <Block
@@ -149,7 +151,7 @@
149
151
  bind:value_is_output
150
152
  bind:dragging
151
153
  bind:active_source
152
- {file_types}
154
+ {file_types_string}
153
155
  {root}
154
156
  {label}
155
157
  {info}
package/dist/Index.svelte CHANGED
@@ -81,6 +81,7 @@ const upload_fn = (...args) => gradio.client.upload(...args);
81
81
  const i18n = (s) => gradio.i18n(s);
82
82
  const stream_handler_fn = (...args) => gradio.client.stream(...args);
83
83
  $: sources_string = sources.join(",");
84
+ $: file_types_string = (file_types || []).join(",") || null;
84
85
  </script>
85
86
 
86
87
  <Block
@@ -107,7 +108,7 @@ $: sources_string = sources.join(",");
107
108
  bind:value_is_output
108
109
  bind:dragging
109
110
  bind:active_source
110
- {file_types}
111
+ {file_types_string}
111
112
  {root}
112
113
  {label}
113
114
  {info}
@@ -40,7 +40,7 @@ export let autofocus = false;
40
40
  export let text_align = void 0;
41
41
  export let autoscroll = true;
42
42
  export let root;
43
- export let file_types = null;
43
+ export let file_types_string = null;
44
44
  export let max_file_size = null;
45
45
  export let upload;
46
46
  export let stream_handler;
@@ -63,6 +63,7 @@ let uploading = false;
63
63
  let oldValue = value?.text ?? "";
64
64
  let recording = false;
65
65
  $: sources = sources_string.split(",").map((s) => s.trim()).filter((s) => s === "upload" || s === "microphone");
66
+ $: file_types = file_types_string ? file_types_string.split(",").map((s) => s.trim()) : null;
66
67
  $: dispatch("drag", dragging);
67
68
  let mic_audio = null;
68
69
  let full_container;
@@ -25,7 +25,7 @@ declare const __propDef: {
25
25
  text_align?: "left" | "right" | undefined;
26
26
  autoscroll?: boolean;
27
27
  root: string;
28
- file_types?: string[] | null;
28
+ file_types_string?: string | null;
29
29
  max_file_size?: number | null;
30
30
  upload: Client["upload"];
31
31
  stream_handler: Client["stream"];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gradio/multimodaltextbox",
3
- "version": "0.10.20",
3
+ "version": "0.10.21",
4
4
  "description": "Gradio UI packages",
5
5
  "type": "module",
6
6
  "author": "",
@@ -25,11 +25,11 @@
25
25
  "@gradio/atoms": "^0.18.1",
26
26
  "@gradio/icons": "^0.14.0",
27
27
  "@gradio/utils": "^0.10.2",
28
+ "@gradio/statustracker": "^0.11.1",
28
29
  "@gradio/upload": "^0.17.1",
29
30
  "@gradio/image": "^0.23.1",
30
- "@gradio/statustracker": "^0.11.1",
31
31
  "@gradio/video": "^0.16.0",
32
- "@gradio/client": "^1.19.0"
32
+ "@gradio/client": "^1.19.1"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@gradio/preview": "^0.14.0"
@@ -48,7 +48,7 @@
48
48
  export let text_align: "left" | "right" | undefined = undefined;
49
49
  export let autoscroll = true;
50
50
  export let root: string;
51
- export let file_types: string[] | null = null;
51
+ export let file_types_string: string | null = null;
52
52
  export let max_file_size: number | null = null;
53
53
  export let upload: Client["upload"];
54
54
  export let stream_handler: Client["stream"];
@@ -84,6 +84,9 @@
84
84
  | "upload"
85
85
  | "microphone"
86
86
  )[];
87
+ $: file_types = file_types_string
88
+ ? file_types_string.split(",").map((s) => s.trim())
89
+ : null;
87
90
  $: dispatch("drag", dragging);
88
91
  let mic_audio: FileData | null = null;
89
92