fix(completion): stop offering status once its quote is closed
The pattern's trailing optional quote let a complete `status = "x"` match, so the popup reopened after the closing quote. Drop it so the match ends with the value, while still typing remains supported.
This commit is contained in:
@@ -66,6 +66,10 @@ describe("completion context", () => {
|
||||
expect(labelsAt('[[feature]]\nstatus = "o|')).toEqual(["on-track", "off-track"])
|
||||
})
|
||||
|
||||
it("offers nothing once the status value's quote is closed", () => {
|
||||
expect(getCompletions(...atCaret('[[feature]]\nstatus = "on-track"|'))).toBeNull()
|
||||
})
|
||||
|
||||
it("suggests feature names inside a milestone requires array", () => {
|
||||
const source = '[[feature]]\nname = "Payments"\n\n[[milestone]]\nrequires = ["|'
|
||||
expect(labelsAt(source)).toEqual(["Payments"])
|
||||
|
||||
Reference in New Issue
Block a user