fix: api playground text overlap button and search hub model (#3833)
* fix: button api playground overlap button and search hub model * fix: update overlap text responsive tab and conditional render GPU menu
This commit is contained in:
parent
3df98b87a3
commit
d6891a5628
@ -35,6 +35,7 @@
|
||||
flex: 1;
|
||||
height: 38px;
|
||||
display: flex;
|
||||
white-space: nowrap;
|
||||
color: hsla(var(--text-secondary));
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
@ -96,17 +96,19 @@ const HubScreen = () => {
|
||||
{!filteredModels.length ? (
|
||||
<BlankState title="No search results found" />
|
||||
) : (
|
||||
<div className="mb-4 flex w-full justify-end">
|
||||
<Select
|
||||
value={sortSelected}
|
||||
onValueChange={(value) => {
|
||||
setSortSelected(value)
|
||||
}}
|
||||
options={sortMenus}
|
||||
/>
|
||||
</div>
|
||||
<>
|
||||
<div className="mb-4 flex w-full justify-end">
|
||||
<Select
|
||||
value={sortSelected}
|
||||
onValueChange={(value) => {
|
||||
setSortSelected(value)
|
||||
}}
|
||||
options={sortMenus}
|
||||
/>
|
||||
</div>
|
||||
<ModelList models={filteredModels} />
|
||||
</>
|
||||
)}
|
||||
<ModelList models={filteredModels} />
|
||||
</div>
|
||||
</ScrollArea>
|
||||
</CenterPanelContainer>
|
||||
|
||||
@ -127,9 +127,10 @@ const LocalServerLeftPanel = () => {
|
||||
{serverEnabled ? 'Stop' : 'Start'} Server
|
||||
</Button>
|
||||
{serverEnabled && (
|
||||
<Button variant="soft" asChild>
|
||||
<Button variant="soft" asChild className="whitespace-nowrap">
|
||||
<a href={`http://localhost:${port}`} target="_blank">
|
||||
API Playground <ExternalLinkIcon size={20} className="ml-2" />
|
||||
<span>API Playground</span>{' '}
|
||||
<ExternalLinkIcon size={20} className="ml-2" />
|
||||
</a>
|
||||
</Button>
|
||||
)}
|
||||
|
||||
@ -211,9 +211,6 @@ const Advanced = () => {
|
||||
saveSettings({ gpusInUse: updatedGpusInUse })
|
||||
}
|
||||
|
||||
const gpuSelectionPlaceHolder =
|
||||
gpuList.length > 0 ? 'Select GPU' : "You don't have any compatible GPU"
|
||||
|
||||
/**
|
||||
* Handle click outside
|
||||
*/
|
||||
@ -240,7 +237,7 @@ const Advanced = () => {
|
||||
</div>
|
||||
|
||||
{/* CPU / GPU switching */}
|
||||
{!isMac && (
|
||||
{!isMac && gpuList.length > 0 && (
|
||||
<div className="flex w-full flex-col items-start justify-between border-b border-[hsla(var(--app-border))] py-4 first:pt-0 last:border-none">
|
||||
<div className="flex w-full items-start justify-between">
|
||||
<div className="space-y-1">
|
||||
@ -326,7 +323,7 @@ const Advanced = () => {
|
||||
value={selectedGpu.join() || ''}
|
||||
className="w-full cursor-pointer"
|
||||
readOnly
|
||||
placeholder={gpuSelectionPlaceHolder}
|
||||
placeholder=""
|
||||
suffixIcon={
|
||||
<ChevronDownIcon
|
||||
size={14}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user