fix(sqlite,browser): resolve SQLite connection pool deadlock, disable stale SW cache, and update BRAIN.md
MindSift CI & Docker Release / Build, Test in Container & Push (push) Failing after 38s
MindSift CI & Docker Release / Build, Test in Container & Push (push) Failing after 38s
This commit is contained in:
1 parent
d6bc2976d9
commit
5c4e130862
8 files changed
+414
-231
No files matched your search
@@ -148,40 +148,46 @@ export const InstantCaptureBar: React.FC<InstantCaptureBarProps> = ({
|
||||
const effectiveTarget = overrideTarget || target;
|
||||
const effectiveListId =
|
||||
overrideListId || targetListId || (lists.length > 0 ? lists[0].id : '');
|
||||
const capturedPriority = priority;
|
||||
const capturedDueDate = dueDate;
|
||||
const capturedSource = isListening ? 'voice' : 'manual';
|
||||
|
||||
// Optimistically clear input immediately so the UI feels instant (<10ms) in all browsers
|
||||
setContent('');
|
||||
setPriority('normal');
|
||||
setDueDate('');
|
||||
setTarget('inbox');
|
||||
setShowOptions(false);
|
||||
setIsSubmitting(true);
|
||||
triggerHaptic(15);
|
||||
|
||||
const savedMsg =
|
||||
effectiveTarget === 'task'
|
||||
? 'Als Aufgabe!'
|
||||
: effectiveTarget === 'list_item'
|
||||
? 'Auf Liste!'
|
||||
: effectiveTarget === 'document'
|
||||
? 'Als Notiz!'
|
||||
: 'Im Dump!';
|
||||
setJustSavedLabel(savedMsg);
|
||||
setTimeout(() => setJustSavedLabel(null), 1600);
|
||||
inputRef.current?.focus();
|
||||
|
||||
try {
|
||||
const created = await api.captureThought(
|
||||
trimmed,
|
||||
priority,
|
||||
isListening ? 'voice' : 'manual',
|
||||
dueDate,
|
||||
capturedPriority,
|
||||
capturedSource,
|
||||
capturedDueDate,
|
||||
{
|
||||
target: effectiveTarget,
|
||||
targetListId: effectiveTarget === 'list_item' ? effectiveListId : '',
|
||||
}
|
||||
);
|
||||
setContent('');
|
||||
setPriority('normal');
|
||||
setDueDate('');
|
||||
setTarget('inbox');
|
||||
setShowOptions(false);
|
||||
|
||||
const savedMsg =
|
||||
effectiveTarget === 'task'
|
||||
? 'Als Aufgabe!'
|
||||
: effectiveTarget === 'list_item'
|
||||
? 'Auf Liste!'
|
||||
: effectiveTarget === 'document'
|
||||
? 'Als Notiz!'
|
||||
: 'Im Dump!';
|
||||
setJustSavedLabel(savedMsg);
|
||||
setTimeout(() => setJustSavedLabel(null), 1600);
|
||||
|
||||
onCaptured(created, effectiveTarget);
|
||||
inputRef.current?.focus();
|
||||
} catch {
|
||||
// Restore text if capture unexpectedly failed completely
|
||||
setContent(trimmed);
|
||||
} finally {
|
||||
setIsSubmitting(false);
|
||||
}
|
||||
@@ -221,6 +227,12 @@ export const InstantCaptureBar: React.FC<InstantCaptureBarProps> = ({
|
||||
type="text"
|
||||
value={content}
|
||||
onChange={(e) => setContent(e.target.value)}
|
||||
onKeyDown={(e) => {
|
||||
if (e.key === 'Enter' && !e.shiftKey) {
|
||||
e.preventDefault();
|
||||
executeCapture();
|
||||
}
|
||||
}}
|
||||
placeholder={
|
||||
isListening
|
||||
? 'Ich höre zu…'
|
||||
|
||||
Reference in new issue
Block a user