aboutsummaryrefslogtreecommitdiffstats
path: root/subprojects/frontend/src/editor/EditorStore.ts
diff options
context:
space:
mode:
Diffstat (limited to 'subprojects/frontend/src/editor/EditorStore.ts')
-rw-r--r--subprojects/frontend/src/editor/EditorStore.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/subprojects/frontend/src/editor/EditorStore.ts b/subprojects/frontend/src/editor/EditorStore.ts
index c74e732f..d13f644c 100644
--- a/subprojects/frontend/src/editor/EditorStore.ts
+++ b/subprojects/frontend/src/editor/EditorStore.ts
@@ -255,6 +255,10 @@ export default class EditorStore {
255 log.debug('Show line numbers', this.showLineNumbers); 255 log.debug('Show line numbers', this.showLineNumbers);
256 } 256 }
257 257
258 get hasSelection(): boolean {
259 return this.state.selection.ranges.some(({ from, to }) => from !== to);
260 }
261
258 formatText(): boolean { 262 formatText(): boolean {
259 this.client.formatText(); 263 this.client.formatText();
260 return true; 264 return true;