From bc92c0d66162d7b3b08a7f550c711c2be3342d5d Mon Sep 17 00:00:00 2001 From: Osama Alfakhouri Date: Mon, 25 Sep 2023 19:53:46 +0300 Subject: [PATCH 1/2] RAI-16086 fix string quotes auto closing after doc/raw keywords --- dist/index.cjs | 5 ++++- dist/index.js | 5 ++++- src/index.ts | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/dist/index.cjs b/dist/index.cjs index 0cedd42..c6c59bd 100644 --- a/dist/index.cjs +++ b/dist/index.cjs @@ -223,7 +223,10 @@ const relLanguage = language.LRLanguage.define({ ] }), languageData: { - closeBrackets: { brackets: ["(", "[", "{", "'", '"', "`", '"""'] }, + closeBrackets: { + brackets: ["(", "[", "{", "'", '"', "`", '"""'], + stringPrefixes: ["doc", "raw"] + }, commentTokens: { line: "//", block: { open: "/*", close: "*/" } }, } }); diff --git a/dist/index.js b/dist/index.js index a72c211..3d93ca5 100644 --- a/dist/index.js +++ b/dist/index.js @@ -219,7 +219,10 @@ const relLanguage = LRLanguage.define({ ] }), languageData: { - closeBrackets: { brackets: ["(", "[", "{", "'", '"', "`", '"""'] }, + closeBrackets: { + brackets: ["(", "[", "{", "'", '"', "`", '"""'], + stringPrefixes: ["doc", "raw"] + }, commentTokens: { line: "//", block: { open: "/*", close: "*/" } }, } }); diff --git a/src/index.ts b/src/index.ts index c57b5b7..79c10a6 100644 --- a/src/index.ts +++ b/src/index.ts @@ -54,7 +54,10 @@ export const relLanguage = LRLanguage.define({ ] }), languageData: { - closeBrackets: {brackets: ["(", "[", "{", "'", '"', "`", '"""']}, + closeBrackets: { + brackets: ["(", "[", "{", "'", '"', "`", '"""'], + stringPrefixes: ["doc", "raw"] + }, commentTokens: {line: "//", block: {open: "/*", close: "*/"}}, } }) From 4c990d089ed73c09d023ec87dbcb62c081d2676e Mon Sep 17 00:00:00 2001 From: Osama Alfakhouri Date: Mon, 25 Sep 2023 19:58:05 +0300 Subject: [PATCH 2/2] bump version --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index a410733..9dfae93 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@relationalai/codemirror-lang-rel", - "version": "0.2.14", + "version": "0.2.15", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@relationalai/codemirror-lang-rel", - "version": "0.2.14", + "version": "0.2.15", "license": "MIT", "dependencies": { "@codemirror/language": "^6.0.0", diff --git a/package.json b/package.json index 255ef93..911e767 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@relationalai/codemirror-lang-rel", - "version": "0.2.14", + "version": "0.2.15", "description": "CodeMirror 6 language support for Rel", "scripts": { "test": "mocha test/test.js",