gradio-pr-bot commited on
Commit
7ae45a0
·
verified ·
1 Parent(s): d9bd882

Upload folder using huggingface_hub

Browse files
6.3.1/multimodaltextbox/package.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "name": "@gradio/multimodaltextbox",
3
- "version": "0.11.3",
4
  "description": "Gradio UI packages",
5
  "type": "module",
6
  "author": "",
 
1
  {
2
  "name": "@gradio/multimodaltextbox",
3
+ "version": "0.11.4",
4
  "description": "Gradio UI packages",
5
  "type": "module",
6
  "author": "",
6.3.1/multimodaltextbox/shared/MultimodalTextbox.svelte CHANGED
@@ -438,7 +438,7 @@
438
  class="input-wrapper"
439
  class:has-files={value.files.length > 0 || uploading}
440
  >
441
- {#if value.files.length > 0 || uploading || show_upload}
442
  <div
443
  class="thumbnails"
444
  aria-label="Uploaded files"
@@ -496,6 +496,17 @@
496
  {/if}
497
 
498
  <div class="input-row">
 
 
 
 
 
 
 
 
 
 
 
499
  <textarea
500
  data-testid="textbox"
501
  use:text_area_resize={{
@@ -617,7 +628,7 @@
617
  gap: 0;
618
  background: var(--block-background-fill);
619
  border-radius: var(--radius-xl);
620
- padding: var(--spacing-sm);
621
  align-items: flex-start;
622
  min-height: auto;
623
  }
@@ -628,7 +639,7 @@
628
 
629
  .input-row {
630
  display: flex;
631
- align-items: flex-end;
632
  gap: var(--spacing-sm);
633
  width: 100%;
634
  }
@@ -724,7 +735,7 @@
724
  flex-grow: 1;
725
  outline: none !important;
726
  background: transparent;
727
- padding: 0;
728
  color: var(--body-text-color);
729
  font-weight: var(--input-text-weight);
730
  font-size: var(--input-text-size);
@@ -734,7 +745,6 @@
734
  position: relative;
735
  z-index: var(--layer-1);
736
  text-align: left;
737
- min-height: var(--size-9);
738
  }
739
 
740
  textarea:disabled {
@@ -754,7 +764,8 @@
754
  transform: scaleX(-1);
755
  }
756
 
757
- .microphone-button {
 
758
  color: var(--body-text-color);
759
  cursor: pointer;
760
  padding: var(--spacing-sm);
@@ -792,21 +803,25 @@
792
  height: var(--size-5);
793
  }
794
 
795
- .microphone-button {
 
796
  width: var(--size-9);
797
  height: var(--size-9);
798
  }
799
 
800
- .microphone-button:hover:not(:disabled) {
 
801
  background: var(--button-secondary-background-fill);
802
  }
803
 
804
- .microphone-button:disabled {
 
805
  opacity: 0.5;
806
  cursor: not-allowed;
807
  }
808
 
809
- .microphone-button :global(svg) {
 
810
  width: var(--size-5);
811
  height: var(--size-5);
812
  }
 
438
  class="input-wrapper"
439
  class:has-files={value.files.length > 0 || uploading}
440
  >
441
+ {#if value.files.length > 0 || uploading}
442
  <div
443
  class="thumbnails"
444
  aria-label="Uploaded files"
 
496
  {/if}
497
 
498
  <div class="input-row">
499
+ {#if show_upload && value.files.length === 0 && !uploading}
500
+ <button
501
+ data-testid="upload-button"
502
+ class="upload-button icon-button"
503
+ {disabled}
504
+ on:click={handle_upload_click}
505
+ aria-label="Upload a file"
506
+ >
507
+ <Paperclip />
508
+ </button>
509
+ {/if}
510
  <textarea
511
  data-testid="textbox"
512
  use:text_area_resize={{
 
628
  gap: 0;
629
  background: var(--block-background-fill);
630
  border-radius: var(--radius-xl);
631
+ padding: var(--spacing-sm) var(--spacing-sm) var(--spacing-sm) 0;
632
  align-items: flex-start;
633
  min-height: auto;
634
  }
 
639
 
640
  .input-row {
641
  display: flex;
642
+ align-items: flex-start;
643
  gap: var(--spacing-sm);
644
  width: 100%;
645
  }
 
735
  flex-grow: 1;
736
  outline: none !important;
737
  background: transparent;
738
+ padding: var(--spacing-sm) 0;
739
  color: var(--body-text-color);
740
  font-weight: var(--input-text-weight);
741
  font-size: var(--input-text-size);
 
745
  position: relative;
746
  z-index: var(--layer-1);
747
  text-align: left;
 
748
  }
749
 
750
  textarea:disabled {
 
764
  transform: scaleX(-1);
765
  }
766
 
767
+ .microphone-button,
768
+ .icon-button {
769
  color: var(--body-text-color);
770
  cursor: pointer;
771
  padding: var(--spacing-sm);
 
803
  height: var(--size-5);
804
  }
805
 
806
+ .microphone-button,
807
+ .icon-button {
808
  width: var(--size-9);
809
  height: var(--size-9);
810
  }
811
 
812
+ .microphone-button:hover:not(:disabled),
813
+ .icon-button:hover:not(:disabled) {
814
  background: var(--button-secondary-background-fill);
815
  }
816
 
817
+ .microphone-button:disabled,
818
+ .icon-button:disabled {
819
  opacity: 0.5;
820
  cursor: not-allowed;
821
  }
822
 
823
+ .microphone-button :global(svg),
824
+ .icon-button :global(svg) {
825
  width: var(--size-5);
826
  height: var(--size-5);
827
  }