mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-15 19:37:47 +01:00
fix: resolve layout shift in knowledge items with long names (#19832)
Co-authored-by: Tim Baek <tim@openwebui.com>
This commit is contained in:
@@ -36,7 +36,7 @@
|
||||
|
||||
let filter = {};
|
||||
$: filter = {
|
||||
...(query ? { query } : {}),
|
||||
...(query ? { query: query } : {}),
|
||||
...(orderBy ? { order_by: orderBy } : {}),
|
||||
...(direction ? { direction } : {})
|
||||
};
|
||||
|
||||
@@ -121,6 +121,7 @@
|
||||
class=" w-full text-sm pr-4 py-1 rounded-r-xl outline-hidden bg-transparent"
|
||||
bind:value={query}
|
||||
placeholder={$i18n.t('Search Chats')}
|
||||
maxlength="500"
|
||||
/>
|
||||
|
||||
{#if query}
|
||||
|
||||
@@ -209,6 +209,7 @@
|
||||
class="w-full rounded-r-xl py-1.5 pl-2.5 text-sm bg-transparent dark:text-gray-300 outline-hidden"
|
||||
placeholder={placeholder ? placeholder : $i18n.t('Search')}
|
||||
autocomplete="off"
|
||||
maxlength="500"
|
||||
bind:value
|
||||
on:input={() => {
|
||||
dispatch('input');
|
||||
|
||||
@@ -68,13 +68,18 @@
|
||||
let models = null;
|
||||
let total = null;
|
||||
|
||||
let searchDebounceTimer;
|
||||
|
||||
$: if (
|
||||
page !== undefined &&
|
||||
query !== undefined &&
|
||||
selectedTag !== undefined &&
|
||||
viewOption !== undefined
|
||||
) {
|
||||
getModelList();
|
||||
clearTimeout(searchDebounceTimer);
|
||||
searchDebounceTimer = setTimeout(() => {
|
||||
getModelList();
|
||||
}, 300);
|
||||
}
|
||||
|
||||
const getModelList = async () => {
|
||||
@@ -381,6 +386,7 @@
|
||||
class=" w-full text-sm py-1 rounded-r-xl outline-hidden bg-transparent"
|
||||
bind:value={query}
|
||||
placeholder={$i18n.t('Search Models')}
|
||||
maxlength="500"
|
||||
/>
|
||||
|
||||
{#if query}
|
||||
|
||||
Reference in New Issue
Block a user