fix: remove remote model from shortcut models dialog

This commit is contained in:
Faisal Amir 2023-12-20 18:04:53 +07:00
parent 994c6e8acc
commit c723fb6866

View File

@ -1,5 +1,6 @@
import { Fragment, useState, useEffect } from 'react' import { Fragment, useState, useEffect } from 'react'
import { InferenceEngine } from '@janhq/core'
import { import {
CommandModal, CommandModal,
CommandEmpty, CommandEmpty,
@ -57,7 +58,11 @@ export default function CommandListDownloadedModel() {
<CommandEmpty>No Model found.</CommandEmpty> <CommandEmpty>No Model found.</CommandEmpty>
{!isNotDownloadedModel && ( {!isNotDownloadedModel && (
<CommandGroup heading="Your Model"> <CommandGroup heading="Your Model">
{downloadedModels.map((model, i) => { {downloadedModels
.filter((model) => {
return model.engine === InferenceEngine.nitro
})
.map((model, i) => {
return ( return (
<CommandItem <CommandItem
key={i} key={i}