Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CORS issues with Lite Component Demos #8623

Merged
merged 2 commits into from
Jun 26, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
fix erros
  • Loading branch information
aliabd committed Jun 26, 2024
commit 41dd55ebdb93db7215eff95ab5546615e0fe20f5
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ import numpy as np
import requests
from io import BytesIO
from PIL import Image
base_image = "https://gradio-builds.s3.amazonaws.com/demo-files/base.png"
building_image = requests.get("https://gradio-builds.s3.amazonaws.com/demo-files/buildings.png")
base_image = "https://gradio-docs-json.s3.us-west-2.amazonaws.com/base.png"
building_image = requests.get("https://gradio-docs-json.s3.us-west-2.amazonaws.com/buildings.png")
building_image = np.asarray(Image.open(BytesIO(building_image.content)))[:, :, -1] > 0
with gr.Blocks() as demo:
gr.AnnotatedImage(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ gradio.Audio(···)
<gradio-lite shared-worker>
import gradio as gr
with gr.Blocks() as demo:
gr.Audio("https://file-examples.com/storage/fe3cb26995666504a8d6180/2017/11/file_example_MP3_700KB.mp3")
gr.Audio("https://cdn.pixabay.com/download/audio/2022/03/09/audio_7e096b862f.mp3")
demo.launch()
</gradio-lite>
</div>
Expand Down