gradio/js
Dawood Khan 4795c6e9e9
Fix multimodal textbox styling for certain themes (#8369)
* fix css

* add changeset

* Add `--table-text-color` var to fix body text in `Examples` (#8364)

* add --table-text-color var

* add changeset

* format

* tweak

* add changeset

* fix

* add changeset

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* Include JS Client package in CI for PR testing (#8362)

* add js client pkg action

* test

* Revert "test"

This reverts commit 575bcfca1b.

* tweaks (#8374)

* chore: update docs.py (#8378)

* chore: update docs.py

Documention -> Documentation

* add changeset

* add changeset

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* Fix encoding error (#8381)

* Set orig_name in python client file uploads (#8371)

* Add code

* add changeset

* URL case

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Hannah <hannahblair@users.noreply.github.com>

* Include instructions on starting from someone else's custom component repository (#8386)

* Add guide

* add changeset

* Fix link

* add changeset

* Add code

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* Fix bug in reload mode equality check. Better equality conversion for state variables (#8385)

* Add code

* Add deep equality

* add changeset

* Add code

* add changeset

* Update gradio/utils.py

Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* Add code

* Add code

* add code

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* Change z-index of status tracker (#8372)

* change z-index of status tracker

* add changeset

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* Add CDN installation to JS docs (#8401)

* add cdn copy

* add changeset

* tweak

* tweak

* add changeset

* Update guides/08_gradio-clients-and-lite/02_getting-started-with-the-js-client.md

Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* remove version from cdn link

* tweak

* tweak

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* Improve rendering (#8398)

* changes

* add changeset

* changes

* changes

* changes

* changes

* changes

* changes

* changeas

* changes

* add changeset

* changes

* add changeset

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* changes

* cganges

* changes

* changes

* changes

* changes

* add changeset

* changes

* chagnes

* changes

* changes

* changes

* changes

* changes

* js

* remove console log

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* changes

* chnages

* changes

* cnages

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* Add `state.change` listener (#8297)

* state changes

* changes

---------

Co-authored-by: Ali Abid <aliabid94@gmail.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* changes

* changes

* add changeset

* changes

* changes

* changes

* changes

* changes

* changes

* updates

* changes

* add changeset

* changes

* changes

* add changeset

* fix

* changes

* changes

* changes

* changes

* changes

* changes

* add changeset

* changes

---------

Co-authored-by: Ali Abid <aliabid94@gmail.com>
Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>

* Render decorator documentation (#8409)

* changes

* changes

* add changeset

* fix dependency loop and documentation group

* add changeset

* changes

* fix numbered list

* changes

* changes

---------

Co-authored-by: Ali Abid <aliabid94@gmail.com>
Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: aliabd <ali.si3luwa@gmail.com>

* Connect heartbeat if state created in render. Also fix config cleanup bug #8407 (#8408)

* Add code

* add changeset

* add changeset

* lint

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* Model3D right-handed coordinate system (#8376)

* changes (#8411)

Co-authored-by: Ali Abid <aliabid94@gmail.com>

* Editable Docs (#8403)

* docs intro page and guides

* python library docs and js client

* reorg

* changes

* add better hovering

* fix broken version routing

* add redirects and remove duplicate pages

* fix build issues

* fix issues

* formatting

* add changeset

* working templates for all components

* add other pages

* merge

* merge

* changes

* changes

* working from templates

* changes

* refactoring

* changes

* build working

* formatting

* importing meta globs

* add uploading templates to ci

* fixes

* add changeset

* remove fake version

* fix

* ignore

* formatting

* adding render page to docs

* add changeset

* formatting fix

* typo

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>

* chore: update versions (#8348)

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: Hannah <hannahblair@users.noreply.github.com>
Co-authored-by: Ikko Eltociear Ashimine <eltociear@gmail.com>
Co-authored-by: Xu Song <xusong.vip@gmail.com>
Co-authored-by: Freddy Boulton <alfonsoboulton@gmail.com>
Co-authored-by: Abubakar Abid <abubakar@huggingface.co>
Co-authored-by: aliabid94 <aabid94@gmail.com>
Co-authored-by: Ali Abid <aliabid94@gmail.com>
Co-authored-by: aliabd <ali.si3luwa@gmail.com>
Co-authored-by: Dylan Ebert <dylan@huggingface.co>
Co-authored-by: pngwn <hello@pngwn.io>
2024-06-03 12:53:59 -04:00
..
_cdn-test chore(deps): update dependency iframe-resizer to v5 (#8347) 2024-05-22 11:06:07 +01:00
_spaces-test chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
_website chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
accordion chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
annotatedimage chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
app chore: update versions (#8433) 2024-06-01 17:47:41 +00:00
atoms chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
audio chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
box chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
button chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
chatbot chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
checkbox chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
checkboxgroup chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
code chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
colorpicker chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
column chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
dataframe chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
dataset chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
downloadbutton chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
dropdown chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
fallback chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
file chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
fileexplorer chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
form chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
gallery chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
group chore: update versions (#8069) 2024-04-25 23:08:27 +00:00
highlightedtext chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
html chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
icons chore: update versions (#8225) 2024-05-10 19:31:04 +01:00
image chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
imageeditor chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
json chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
label chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
lite chore: update versions (#8433) 2024-06-01 17:47:41 +00:00
markdown chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
model3D chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
multimodaltextbox Fix multimodal textbox styling for certain themes (#8369) 2024-06-03 12:53:59 -04:00
number chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
paramviewer chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
plot chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
preview chore: update versions (#8172) 2024-05-03 19:06:05 +01:00
radio chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
row chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
simpledropdown chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
simpleimage chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
simpletextbox chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
slider chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
state chore: update versions (#6039) 2023-10-31 13:20:18 +00:00
statustracker chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
storybook chore: update versions (#8172) 2024-05-03 19:06:05 +01:00
tabitem chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
tabs chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
textbox chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
theme chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
tooltip chore: update versions (#6039) 2023-10-31 13:20:18 +00:00
tootils chore: update versions (#8348) 2024-05-30 00:00:00 +01:00
upload chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
uploadbutton chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
utils chore: update versions (#8335) 2024-05-21 21:01:35 +00:00
video chore: update versions (#8420) 2024-05-30 14:55:23 -07:00
wasm chore: update versions (#8172) 2024-05-03 19:06:05 +01:00
.npmrc move files (#3605) 2023-03-27 16:12:58 -07:00
jsx.d.ts update deps + fix tests (#4675) 2023-06-28 22:40:53 +01:00
README.md Updated CI info in contributing docs (#4415) 2023-06-06 08:52:29 -04:00

gradio-ui

This folder contains all of the Gradio UI and component source code.

setup

This folder is managed as 'monorepo' a multi-package repository which make dependency management very simple. In order to do this we use pnpm as our package manager.

Make sure pnpm is installed by following the installation instructions for your system.

You will also need node which you probably already have

running the application

Install all dependencies:

pnpm i

This will install the dependencies for all packages and link any local packages

local development

To develop locally, open two terminal tabs from the root of the repository.

Run the python test server, from the root directory:

cd demo/kitchen_sink
python run.py

This will start a development server on port 7860 that the web app is expecting.

Run the web app:

pnpm dev

building for production

Run the build:

pnpm build

This will create the necessary files in js/app/public and also in gradio/templates/frontend.

quality checks

The repos currently has two quality checks that can be run locally and are run in CI.

formatting

Formatting is handled by prettier to ensure consistent formatting and prevent style-focused conversations. Formatting failures will fails CI and should be reoslve before merging.

To check formatting:

pnpm format:check

If you have formatting failures then you can run the following command to fix them:

pnpm format:write

type checking

We use TypeScript to provide static types to javascript code. These checks are also run in CI.

to typecheck the code:

pnpm ts:check

ci checks

Currently the following checks are run in CI:

static checks

  • Format check (pnpm format:check)
  • Build css (pnpm css)
  • Build client (pnpm build)
  • Type check (pnpm ts:check)
  • Unit tests (pnpm test:run)

functional test

pip install -r demo/outbreak_forecast/requirements.txt
pnpm exec playwright install chromium
pnpm exec playwright install-deps chromium
pnpm test:browser:full