Changesets · Branches · Tags · Compare
| Changeset | 9aac2b5c28a40c054e6bbae1e37c8544554f1d8ace38711ba259caa7be4a8283 |
|---|---|
| Author | Aditya Mitra <61635505+uinstinct@users.noreply.github.com> · 2025-07-18 21:03 +05:30 |
| Committer | GitHub <noreply@github.com> · 2025-07-18 08:33 -07:00 |
| Parents | ad83f3cc5301 |
1 file changed
modified gui/src/components/mainInput/TipTapEditor/extensions/SlashCommand.ts +3 −0
| @@ -15,6 +15,9 @@ | ||
| 15 | 15 | addOptions() { |
| 16 | 16 | return { |
| 17 | 17 | suggestion: { |
| 18 | + allow: ({ editor }) => | |
| 19 | + // the first character is "/". we want to avoid slash commands when there is a space after it | |
| 20 | + editor.getText().at(1) !== " ", | |
| 18 | 21 | char: "/", |
| 19 | 22 | pluginKey: new PluginKey(this.name), |
| 20 | 23 | startOfLine: true, |