mirror of
https://github.com/xtekky/gpt4free.git
synced 2025-12-06 02:30:41 -08:00
Add .har file support for OpenaiChat
Update model list of HuggingChat Update styles of scrollbar in gui Fix image upload in gui
This commit is contained in:
parent
bf82352a3b
commit
347d3f92da
9 changed files with 235 additions and 69 deletions
|
|
@ -135,6 +135,7 @@ class Api():
|
|||
camera.take_picture(filename=filename, on_complete=self.on_camera)
|
||||
|
||||
def on_image_selection(self, filename):
|
||||
filename = filename[0] if isinstance(filename, list) else filename
|
||||
if filename is not None and os.path.exists(filename):
|
||||
self.image = filename
|
||||
else:
|
||||
|
|
@ -152,7 +153,7 @@ class Api():
|
|||
window = webview.windows[0]
|
||||
if window is not None:
|
||||
window.evaluate_js(
|
||||
f"document.querySelector(`.file-label.selected`)?.classList.remove(`selected`);"
|
||||
f"document.querySelector(`.image-label.selected`)?.classList.remove(`selected`);"
|
||||
)
|
||||
if input_id is not None and input_id in ("image", "camera"):
|
||||
window.evaluate_js(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue