Skip to content

Commit e2826fb

Browse files
feat: autocomplete with single " (#502)
- [x] fix policy completions – seem to be broken given `select | from public.users "u"` or `select | from public.users u`… - autocomplete with single `"` -> results in `"u"."email"` or `"email"` - autocomplete within double `""` -> results in `"u"."email"` or `"email"` - recognize aliases regardless of whether they are quoted or not: - `"u".|` and `u.|` will both suggest `email` - `"u"."|` and `u."|` and `"u"."|"` and `u."|"` will all suggest `"email"` - *This does not yet work for tables -> separate PR* - existing behavior without quotes is unaffected
1 parent 4e2cafd commit e2826fb

File tree

18 files changed

+778
-180
lines changed

18 files changed

+778
-180
lines changed

crates/pgt_completions/src/builder.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ use crate::{
66

77
use pgt_treesitter::TreesitterContext;
88

9+
#[derive(Debug)]
910
pub(crate) struct PossibleCompletionItem<'a> {
1011
pub label: String,
1112
pub description: String,

0 commit comments

Comments
 (0)