Increase user prompt history capacity and dropdown height
• History limit: 8 → 12 items • Dropdown height: max-h-60 → max-h-96 • Better visibility for longer prompts • Improved user experience
This commit is contained in:
parent
683bbe9364
commit
d5fe6bb33e
2 changed files with 4 additions and 4 deletions
|
|
@ -165,7 +165,7 @@ export default function UserPromptInputWithHistory({
|
||||||
|
|
||||||
{/* Dropdown */}
|
{/* Dropdown */}
|
||||||
{isOpen && history.length > 0 && (
|
{isOpen && history.length > 0 && (
|
||||||
<div className="absolute top-full left-0 right-0 z-50 mt-0.5 bg-gray-100 dark:bg-gray-900 border border-gray-300 dark:border-gray-700 rounded-md shadow-lg max-h-60 overflow-auto min-w-0">
|
<div className="absolute top-full left-0 right-0 z-50 mt-0.5 bg-gray-100 dark:bg-gray-900 border border-gray-300 dark:border-gray-700 rounded-md shadow-lg max-h-96 overflow-auto min-w-0">
|
||||||
{history.map((prompt, index) => (
|
{history.map((prompt, index) => (
|
||||||
<div
|
<div
|
||||||
key={index}
|
key={index}
|
||||||
|
|
|
||||||
|
|
@ -220,9 +220,9 @@ const useSettingsStoreBase = create<SettingsState>()(
|
||||||
// Add to beginning
|
// Add to beginning
|
||||||
newHistory.unshift(prompt)
|
newHistory.unshift(prompt)
|
||||||
|
|
||||||
// Keep only last 8 items
|
// Keep only last 12 items
|
||||||
if (newHistory.length > 8) {
|
if (newHistory.length > 12) {
|
||||||
newHistory.splice(8)
|
newHistory.splice(12)
|
||||||
}
|
}
|
||||||
|
|
||||||
return { userPromptHistory: newHistory }
|
return { userPromptHistory: newHistory }
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue