{"version":"2.1.246","anchor":"a-single-store-now-owns-chat-input-state","canonical_anchor":"a-single-store-now-owns-chat-input-state","heading":"A single store now owns chat input state","tier":"internal","area":"Prompt Input","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.246\/e\/a-single-store-now-owns-chat-input-state","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.246","markdown":"### A single store now owns chat input state\n\nOne store now owns everything about your chat input, notifying listeners only on real changes.\n\n**What**\n\nA new class holds the prompt value, cursor offset, mode, pasted content, stashed prompt, ownership of the escape key and vim state, and submit subscriptions, notifying listeners only when a fixed list of keys actually changes.\n\n**Details**\n\n- It tracks whether the value was changed from outside the editor, and debounces a \"typing\" flag on a scheduled timeout.\n- Stash and pop restore the prompt including a launch warning that was showing at the time.\n- Submitting a chat message now reads the text from this store rather than a ref.\n\n**Evidence**\n\n`inputOwnsEscape`\n\n- Area: Prompt Input\n- Tier: Under the hood\n- Useful: 1\/5\n- Signal: 1\/5"}