GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(web): a full prompt stash no longer discards your oldest prompt (… · patroza/t3code@e75534b

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • apps/web/src
    • components/chat
      • useComposerStash.ts
    • i18n/translations
      • de.json
      • en.json
      • es.json
      • fr.json
      • ja.json
      • ko.json
      • pt-BR.json
      • ru.json
      • sv.json
      • zh.json
    • promptStashStore.test.ts
    • promptStashStore.ts
  • docs/user
    • composer.md
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎apps/web/src/components/chat/useComposerStash.ts‎

Copy file name to clipboardExpand all lines: apps/web/src/components/chat/useComposerStash.ts
+16-24Lines changed: 16 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ export function useComposerStash(input: {
603603
// crash or closed tab mid-encode still leaves the prompt recoverable,
604604
// while clearing before the async image work means edits typed during
605605
// encoding are not wiped.
606-
const { evicted, written, durable } = stashEntryToQueue({
606+
const { full, written, durable } = stashEntryToQueue({
607607
id: entryId,
608608
createdAt: new Date().toISOString(),
609609
prompt,
@@ -615,9 +615,21 @@ export function useComposerStash(input: {
615615
...(stashedRecords.length > 0 ? { records: stashedRecords } : {}),
616616
});
617617

618-
// If it was rejected (quota) the store has already rolled itself back,
619-
// so leave the composer untouched rather than making it the second
620-
// casualty of a reload.
618+
// A full or rejected write kept nothing, so leave the composer untouched.
619+
if (full) {
620+
toastManager.add({
621+
type: "warning",
622+
title: m(msg("Stash is full")),
623+
description: m(
624+
msg(
625+
"The stash holds {max} prompts. Restore or delete one to make room; the composer was left as-is.",
626+
{ max: MAX_STASH_ENTRIES },
627+
),
628+
),
629+
data: { hideCopyButton: true },
630+
});
631+
return;
632+
}
621633
if (!written) {
622634
toastManager.add({
623635
type: "error",
@@ -665,26 +677,6 @@ export function useComposerStash(input: {
665677
setComposerTrigger(null);
666678
pulseStashBadge();
667679

668-
if (evicted) {
669-
for (const file of evicted.files ?? []) {
670-
releasePersistedAttachmentUpload({
671-
id: file.id,
672-
environmentId: file.environmentId,
673-
attachmentId: file.attachmentId,
674-
});
675-
}
676-
toastManager.add({
677-
type: "warning",
678-
title: m(msg("Oldest stashed prompt discarded")),
679-
description: m(
680-
msg("The stash holds {max} prompts; the oldest was removed to make room.", {
681-
max: MAX_STASH_ENTRIES,
682-
}),
683-
),
684-
data: { hideCopyButton: true },
685-
});
686-
}
687-
688680
// Images are re-encoded for the stash rather than stored verbatim: the
689681
// composer allows up to 10MB per image, but localStorage gives the whole
690682
// origin ~5MB.
Collapse file

‎apps/web/src/i18n/translations/de.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/de.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4939,8 +4939,6 @@
49394939
"3f5c37167aa5034f": "Der Browserspeicher hat das Schreiben abgelehnt, daher wurde das Eingabefeld unverändert gelassen. Gib Websitedaten frei und versuche es erneut.",
49404940
"41ba6c0b5c5e8b22": "Abgelegter Prompt übersteht kein Neuladen",
49414941
"94d7f150b3f7b291": "Der Browserspeicher ist nicht verfügbar, daher wird diese Ablage nur für diese Sitzung im Arbeitsspeicher gehalten.",
4942-
"f421c24666cd8c71": "Ältester abgelegter Prompt verworfen",
4943-
"1123f816ea2a6e3e": "Die Ablage fasst {max} Prompts; der älteste wurde entfernt, um Platz zu schaffen.",
49444942
"c3a8f9b1b2e7d588": "Abgelegte Bilder wurden nicht gespeichert",
49454943
"fc3feba263971bce": "Der Prompt wurde abgelegt, aber der Browserspeicher hat seine Bilder abgelehnt. Sie fehlen, wenn du neu lädst.",
49464944
"9e36559d0fa0cca8": "Abgelegte Bilder wurden nicht angehängt",
@@ -12990,5 +12988,7 @@
1299012988
"99451a5d2d40440f": "Zurückgezogen von {by}.",
1299112989
"3ee30a50b70fffab": "Zurückgezogen von {by}: {reason}",
1299212990
"92e129bf413a1220": "zurückgezogen",
12993-
"800966eb58181745": "Prüfe, welche Sprachen das Modell unterstützt…"
12991+
"800966eb58181745": "Prüfe, welche Sprachen das Modell unterstützt…",
12992+
"410dded6e21c280d": "Ablage ist voll",
12993+
"1af8d12ac21cb183": "Die Ablage fasst {max} Prompts. Stelle einen wieder her oder lösche einen, um Platz zu schaffen; das Eingabefeld wurde unverändert gelassen."
1299412994
}
Collapse file

‎apps/web/src/i18n/translations/en.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/en.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4938,8 +4938,6 @@
49384938
"3f5c37167aa5034f": "Browser storage rejected the write, so the composer was left as-is. Free up site data and try again.",
49394939
"41ba6c0b5c5e8b22": "Stashed prompt will not survive a reload",
49404940
"94d7f150b3f7b291": "Browser storage is unavailable, so this stash is kept in memory only for this session.",
4941-
"f421c24666cd8c71": "Oldest stashed prompt discarded",
4942-
"1123f816ea2a6e3e": "The stash holds {max} prompts; the oldest was removed to make room.",
49434941
"c3a8f9b1b2e7d588": "Stashed images were not saved",
49444942
"fc3feba263971bce": "The prompt was stashed, but browser storage rejected its images. They will be missing if you reload.",
49454943
"9e36559d0fa0cca8": "Stashed images did not attach",
@@ -12999,5 +12997,7 @@
1299912997
"99451a5d2d40440f": "Withdrawn by {by}.",
1300012998
"3ee30a50b70fffab": "Withdrawn by {by}: {reason}",
1300112999
"92e129bf413a1220": "withdrawn",
13002-
"800966eb58181745": "Checking which languages the model supports…"
13000+
"800966eb58181745": "Checking which languages the model supports…",
13001+
"410dded6e21c280d": "Stash is full",
13002+
"1af8d12ac21cb183": "The stash holds {max} prompts. Restore or delete one to make room; the composer was left as-is."
1300313003
}
Collapse file

‎apps/web/src/i18n/translations/es.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/es.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4936,8 +4936,6 @@
49364936
"3f5c37167aa5034f": "El almacenamiento del navegador rechazó la escritura, así que el cuadro de mensaje se quedó como estaba. Libera datos del sitio y vuelve a intentarlo.",
49374937
"41ba6c0b5c5e8b22": "El prompt del stash no sobrevivirá a una recarga",
49384938
"94d7f150b3f7b291": "El almacenamiento del navegador no está disponible, así que este stash solo se guarda en memoria durante esta sesión.",
4939-
"f421c24666cd8c71": "Se descartó el prompt más antiguo del stash",
4940-
"1123f816ea2a6e3e": "El stash admite {max} prompts; se quitó el más antiguo para hacer sitio.",
49414939
"c3a8f9b1b2e7d588": "Las imágenes del stash no se guardaron",
49424940
"fc3feba263971bce": "El prompt se guardó en el stash, pero el almacenamiento del navegador rechazó sus imágenes. Faltarán si recargas.",
49434941
"9e36559d0fa0cca8": "Las imágenes del stash no se adjuntaron",
@@ -12985,5 +12983,7 @@
1298512983
"99451a5d2d40440f": "Retirada por {by}.",
1298612984
"3ee30a50b70fffab": "Retirada por {by}: {reason}",
1298712985
"92e129bf413a1220": "retirada",
12988-
"800966eb58181745": "Comprobando qué idiomas admite el modelo…"
12986+
"800966eb58181745": "Comprobando qué idiomas admite el modelo…",
12987+
"410dded6e21c280d": "El stash está lleno",
12988+
"1af8d12ac21cb183": "El stash admite {max} prompts. Restaura o elimina uno para hacer sitio; el campo de texto se dejó como estaba."
1298912989
}
Collapse file

‎apps/web/src/i18n/translations/fr.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/fr.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4937,8 +4937,6 @@
49374937
"3f5c37167aa5034f": "Le stockage du navigateur a refusé l’écriture ; la zone de saisie a donc été laissée telle quelle. Libérez des données de site et réessayez.",
49384938
"41ba6c0b5c5e8b22": "Le prompt mis de côté ne survivra pas à un rechargement",
49394939
"94d7f150b3f7b291": "Le stockage du navigateur est indisponible ; cette réserve est donc gardée en mémoire pour cette session uniquement.",
4940-
"f421c24666cd8c71": "Le plus ancien prompt mis de côté a été supprimé",
4941-
"1123f816ea2a6e3e": "La réserve contient {max} prompts ; le plus ancien a été supprimé pour faire de la place.",
49424940
"c3a8f9b1b2e7d588": "Les images mises de côté n’ont pas été enregistrées",
49434941
"fc3feba263971bce": "Le prompt a été mis de côté, mais le stockage du navigateur a refusé ses images. Elles manqueront si vous rechargez.",
49444942
"9e36559d0fa0cca8": "Les images mises de côté n’ont pas été jointes",
@@ -12990,5 +12988,7 @@
1299012988
"99451a5d2d40440f": "Retirée par {by}.",
1299112989
"3ee30a50b70fffab": "Retirée par {by} : {reason}",
1299212990
"92e129bf413a1220": "retirée",
12993-
"800966eb58181745": "Vérification des langues prises en charge par le modèle…"
12991+
"800966eb58181745": "Vérification des langues prises en charge par le modèle…",
12992+
"410dded6e21c280d": "La réserve est pleine",
12993+
"1af8d12ac21cb183": "La réserve contient {max} prompts. Restaurez-en ou supprimez-en un pour faire de la place ; la zone de saisie a été laissée telle quelle."
1299412994
}
Collapse file

‎apps/web/src/i18n/translations/ja.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/ja.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4925,8 +4925,6 @@
49254925
"3f5c37167aa5034f": "ブラウザーのストレージが書き込みを拒否したため、入力欄はそのままです。サイトのデータを空けて、もう一度お試しください。",
49264926
"41ba6c0b5c5e8b22": "退避したプロンプトは再読み込みすると失われます",
49274927
"94d7f150b3f7b291": "ブラウザーのストレージを利用できないため、この退避はこのセッションの間だけメモリに保持されます。",
4928-
"f421c24666cd8c71": "最も古い退避したプロンプトを破棄しました",
4929-
"1123f816ea2a6e3e": "退避できるプロンプトは {max} 件までです。空きを作るため、最も古いものを削除しました。",
49304928
"c3a8f9b1b2e7d588": "退避した画像は保存されませんでした",
49314929
"fc3feba263971bce": "プロンプトは退避されましたが、ブラウザーのストレージが画像を拒否しました。再読み込みすると画像は失われます。",
49324930
"9e36559d0fa0cca8": "退避した画像は添付されませんでした",
@@ -12926,5 +12924,7 @@
1292612924
"99451a5d2d40440f": "{by} が取り下げました。",
1292712925
"3ee30a50b70fffab": "{by} が取り下げました: {reason}",
1292812926
"92e129bf413a1220": "取り下げ済み",
12929-
"800966eb58181745": "モデルが対応している言語を確認しています…"
12927+
"800966eb58181745": "モデルが対応している言語を確認しています…",
12928+
"410dded6e21c280d": "退避がいっぱいです",
12929+
"1af8d12ac21cb183": "退避できるプロンプトは {max} 件までです。空きを作るには、どれかを復元するか削除してください。入力欄はそのままにしてあります。"
1293012930
}
Collapse file

‎apps/web/src/i18n/translations/ko.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/ko.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4922,8 +4922,6 @@
49224922
"3f5c37167aa5034f": "브라우저 저장소가 쓰기를 거부해서 입력창을 그대로 두었습니다. 사이트 데이터를 정리한 후 다시 시도하세요.",
49234923
"41ba6c0b5c5e8b22": "임시 저장한 프롬프트는 새로 고치면 사라집니다",
49244924
"94d7f150b3f7b291": "브라우저 저장소를 사용할 수 없어 이 임시 저장함은 이번 세션 동안 메모리에만 유지됩니다.",
4925-
"f421c24666cd8c71": "가장 오래된 임시 저장 프롬프트 삭제됨",
4926-
"1123f816ea2a6e3e": "임시 저장함에는 프롬프트를 {max}개까지 저장할 수 있어 가장 오래된 항목을 삭제했습니다.",
49274925
"c3a8f9b1b2e7d588": "임시 저장한 이미지가 저장되지 않았습니다",
49284926
"fc3feba263971bce": "프롬프트는 임시 저장되었지만 브라우저 저장소가 이미지를 거부했습니다. 새로 고치면 이미지가 사라집니다.",
49294927
"9e36559d0fa0cca8": "임시 저장한 이미지가 첨부되지 않았습니다",
@@ -12923,5 +12921,7 @@
1292312921
"99451a5d2d40440f": "{by}에서 철회했습니다.",
1292412922
"3ee30a50b70fffab": "{by}에서 철회했습니다: {reason}",
1292512923
"92e129bf413a1220": "철회됨",
12926-
"800966eb58181745": "모델이 지원하는 언어를 확인하는 중…"
12924+
"800966eb58181745": "모델이 지원하는 언어를 확인하는 중…",
12925+
"410dded6e21c280d": "임시 저장함이 가득 찼습니다",
12926+
"1af8d12ac21cb183": "임시 저장함에는 프롬프트를 {max}개까지 저장할 수 있습니다. 공간을 만들려면 하나를 복원하거나 삭제하세요. 입력란은 그대로 두었습니다."
1292712927
}
Collapse file

‎apps/web/src/i18n/translations/pt-BR.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/pt-BR.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4936,8 +4936,6 @@
49364936
"3f5c37167aa5034f": "O armazenamento do navegador rejeitou a gravação, então o editor de mensagens ficou como estava. Libere dados do site e tente novamente.",
49374937
"41ba6c0b5c5e8b22": "O prompt guardado não vai sobreviver a uma recarga",
49384938
"94d7f150b3f7b291": "O armazenamento do navegador não está disponível, então estes guardados ficam só na memória durante esta sessão.",
4939-
"f421c24666cd8c71": "Prompt guardado mais antigo descartado",
4940-
"1123f816ea2a6e3e": "Os guardados comportam {max} prompts; o mais antigo foi removido para abrir espaço.",
49414939
"c3a8f9b1b2e7d588": "As imagens guardadas não foram salvas",
49424940
"fc3feba263971bce": "O prompt foi guardado, mas o armazenamento do navegador rejeitou as imagens. Elas vão faltar se você recarregar.",
49434941
"9e36559d0fa0cca8": "As imagens guardadas não foram anexadas",
@@ -12990,5 +12988,7 @@
1299012988
"99451a5d2d40440f": "Retirada por {by}.",
1299112989
"3ee30a50b70fffab": "Retirada por {by}: {reason}",
1299212990
"92e129bf413a1220": "retirada",
12993-
"800966eb58181745": "Verificando quais idiomas o modelo suporta…"
12991+
"800966eb58181745": "Verificando quais idiomas o modelo suporta…",
12992+
"410dded6e21c280d": "Os guardados estão cheios",
12993+
"1af8d12ac21cb183": "Os guardados comportam {max} prompts. Restaure ou exclua um para abrir espaço; o campo de texto ficou como estava."
1299412994
}
Collapse file

‎apps/web/src/i18n/translations/ru.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/ru.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4936,8 +4936,6 @@
49364936
"3f5c37167aa5034f": "Хранилище браузера отклонило запись, поэтому поле ввода не изменилось. Освободите данные сайта и повторите попытку.",
49374937
"41ba6c0b5c5e8b22": "Спрятанный промпт не сохранится после перезагрузки",
49384938
"94d7f150b3f7b291": "Хранилище браузера недоступно, поэтому тайник хранится в памяти только в этом сеансе.",
4939-
"f421c24666cd8c71": "Самый старый спрятанный промпт удалён",
4940-
"1123f816ea2a6e3e": "В тайнике помещается промптов: {max}; самый старый удалён, чтобы освободить место.",
49414939
"c3a8f9b1b2e7d588": "Спрятанные изображения не сохранены",
49424940
"fc3feba263971bce": "Промпт спрятан, но хранилище браузера отклонило его изображения. После перезагрузки их не будет.",
49434941
"9e36559d0fa0cca8": "Спрятанные изображения не прикрепились",
@@ -12990,5 +12988,7 @@
1299012988
"99451a5d2d40440f": "Отозван: {by}.",
1299112989
"3ee30a50b70fffab": "Отозван ({by}): {reason}",
1299212990
"92e129bf413a1220": "отозван",
12993-
"800966eb58181745": "Проверяем, какие языки поддерживает модель…"
12991+
"800966eb58181745": "Проверяем, какие языки поддерживает модель…",
12992+
"410dded6e21c280d": "Тайник заполнен",
12993+
"1af8d12ac21cb183": "В тайнике помещается промптов: {max}. Восстановите или удалите один, чтобы освободить место; поле ввода осталось без изменений."
1299412994
}
Collapse file

‎apps/web/src/i18n/translations/sv.json‎

Copy file name to clipboardExpand all lines: apps/web/src/i18n/translations/sv.json
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4937,8 +4937,6 @@
49374937
"3f5c37167aa5034f": "Webbläsarens lagring avvisade skrivningen, så inmatningsfältet lämnades som det var. Frigör webbplatsdata och försök igen.",
49384938
"41ba6c0b5c5e8b22": "Den undanlagda prompten överlever inte en omladdning",
49394939
"94d7f150b3f7b291": "Webbläsarens lagring är inte tillgänglig, så undanlagda promptar finns bara i minnet under den här sessionen.",
4940-
"f421c24666cd8c71": "Den äldsta undanlagda prompten kastades",
4941-
"1123f816ea2a6e3e": "Du kan lägga undan högst {max} promptar; den äldsta togs bort för att göra plats.",
49424940
"c3a8f9b1b2e7d588": "Undanlagda bilder sparades inte",
49434941
"fc3feba263971bce": "Prompten lades undan, men webbläsarens lagring avvisade dess bilder. De saknas om du laddar om.",
49444942
"9e36559d0fa0cca8": "Undanlagda bilder bifogades inte",
@@ -12997,5 +12995,7 @@
1299712995
"99451a5d2d40440f": "Återkallad av {by}.",
1299812996
"3ee30a50b70fffab": "Återkallad av {by}: {reason}",
1299912997
"92e129bf413a1220": "återkallad",
13000-
"800966eb58181745": "Kontrollerar vilka språk modellen stöder…"
12998+
"800966eb58181745": "Kontrollerar vilka språk modellen stöder…",
12999+
"410dded6e21c280d": "Undanlagringen är full",
13000+
"1af8d12ac21cb183": "Du kan lägga undan högst {max} promptar. Återställ eller ta bort en för att göra plats; inmatningsfältet lämnades som det var."
1300113001
}

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.