mirror of
https://github.com/open-webui/open-webui
synced 2025-04-02 20:11:18 +00:00
feat: import models
This commit is contained in:
parent
ea69087697
commit
fad07d2049
@ -259,9 +259,11 @@
|
||||
console.log(savedModels);
|
||||
|
||||
for (const model of savedModels) {
|
||||
await addNewModel(localStorage.token, model).catch((error) => {
|
||||
return null;
|
||||
});
|
||||
if (model?.info ?? false) {
|
||||
await addNewModel(localStorage.token, model.info).catch((error) => {
|
||||
return null;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
await models.set(await getModels(localStorage.token));
|
||||
|
@ -163,12 +163,12 @@
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class=" hidden lg:flex fixed bottom-0 right-0 px-3 py-3 z-10">
|
||||
<div class=" hidden lg:flex fixed bottom-0 right-0 px-2 py-2 z-10">
|
||||
<Tooltip content={$i18n.t('Help')} placement="left">
|
||||
<button
|
||||
id="show-shortcuts-button"
|
||||
bind:this={showShortcutsButtonElement}
|
||||
class="text-gray-600 dark:text-gray-300 bg-gray-300/20 w-6 h-6 flex items-center justify-center text-xs rounded-full"
|
||||
class="text-gray-600 dark:text-gray-300 bg-gray-300/20 size-5 flex items-center justify-center text-[0.7rem] rounded-full"
|
||||
on:click={() => {
|
||||
showShortcuts = !showShortcuts;
|
||||
}}
|
||||
|
@ -73,7 +73,6 @@
|
||||
}
|
||||
|
||||
if (info) {
|
||||
// TODO: if profile image url === null, set it to default image '/favicon.png'
|
||||
const res = await addNewModel(localStorage.token, {
|
||||
...info,
|
||||
meta: {
|
||||
|
Loading…
Reference in New Issue
Block a user