🐛 fix: add back a couple of major fixes (#5469)
This commit is contained in:
parent
64a7822cc8
commit
1dc9e47524
@ -101,9 +101,7 @@ const SortableItem = memo(({ thread }: { thread: Thread }) => {
|
|||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<div className="py-1 pr-2 truncate">
|
<div className="py-1 pr-2 truncate">
|
||||||
<span
|
<span>{thread.title || t('common:newThread')}</span>
|
||||||
dangerouslySetInnerHTML={{ __html: thread.title || t('common:newThread') }}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
<div className="flex items-center">
|
<div className="flex items-center">
|
||||||
<DropdownMenu
|
<DropdownMenu
|
||||||
|
|||||||
@ -374,33 +374,37 @@ function Hardware() {
|
|||||||
)}
|
)}
|
||||||
|
|
||||||
{/* GPU Information */}
|
{/* GPU Information */}
|
||||||
<Card title={t('settings:hardware.gpus')}>
|
{!IS_MACOS ? (
|
||||||
{hardwareData.gpus.length > 0 ? (
|
<Card title={t('settings:hardware.gpus')}>
|
||||||
<DndContext
|
{hardwareData.gpus.length > 0 ? (
|
||||||
sensors={sensors}
|
<DndContext
|
||||||
collisionDetection={closestCenter}
|
sensors={sensors}
|
||||||
onDragEnd={handleDragEnd}
|
collisionDetection={closestCenter}
|
||||||
>
|
onDragEnd={handleDragEnd}
|
||||||
<SortableContext
|
|
||||||
items={hardwareData.gpus.map((gpu) => gpu.id)}
|
|
||||||
strategy={verticalListSortingStrategy}
|
|
||||||
>
|
>
|
||||||
{hardwareData.gpus.map((gpu, index) => (
|
<SortableContext
|
||||||
<SortableGPUItem
|
items={hardwareData.gpus.map((gpu) => gpu.id)}
|
||||||
key={gpu.id || index}
|
strategy={verticalListSortingStrategy}
|
||||||
gpu={gpu}
|
>
|
||||||
index={index}
|
{hardwareData.gpus.map((gpu, index) => (
|
||||||
/>
|
<SortableGPUItem
|
||||||
))}
|
key={gpu.id || index}
|
||||||
</SortableContext>
|
gpu={gpu}
|
||||||
</DndContext>
|
index={index}
|
||||||
) : (
|
/>
|
||||||
<CardItem
|
))}
|
||||||
title={t('settings:hardware.noGpus')}
|
</SortableContext>
|
||||||
actions={<></>}
|
</DndContext>
|
||||||
/>
|
) : (
|
||||||
)}
|
<CardItem
|
||||||
</Card>
|
title={t('settings:hardware.noGpus')}
|
||||||
|
actions={<></>}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
|
</Card>
|
||||||
|
) : (
|
||||||
|
<></>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user