Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wild behavior when SELECT is missing + other improvements in this vein #77

Merged
merged 4 commits into from
Feb 11, 2024

Conversation

hannahbast
Copy link
Member

@hannahbast hannahbast commented Feb 11, 2024

Some of the useful automatic features of the query editor went rogue under certain conditions. Three things are now fixed or at least better:

  1. When the query did not contain SELECT in all upper case and one of the existing prefixes was typed, each cursor movement would be followed by a reversal of that movement, which made the UI unusable. This is now fixed. In particular, this fixes Cursor jumps around while typing #57.

  2. So far, the query was "cleaned up" (blank lines removed, whitespace replaced by single spaces, etc.) after every cursor movement, which was not always desired. Now the query is only cleaned up in this way when the TAB key is pressed (which jumps between the different positions in the placeholder). In particular, this fixes New lines sometimes get deleted when moving the cursor immediately afterwards #63.

  3. Some REGEXes were only looking for a fully uppercase version of SPARQL keywords like WHERE, etc. Now they are case-insensitive.

Hannah Bast added 4 commits February 10, 2024 05:53
Without typing at least a few characters, it's more confusing than
helpful to suggest a subject AC query to the user. It is currently
hard-coded that at least 3 characters have to be typed, but this should
be a configurable parameter.
PR merged for testing, but is not part of this PR
Some of the useful automatic features of the query editor went rogue
under certain conditions. Two things are now fixed or at least better:

1. When the query did not contain `SELECT` in all upper case and one of
   the existing prefixes was typed, each cursor movement would be
   followed by a reveral of that movement, which made the UI unusable.
   This is now fixed.

2. So far, the query was "cleaned up" (blank lines removed, whitespace
   replaced by single spaces, etc.) after *every* cursor movement, which
   was not always desired. Now the query is only cleaned up in this way
   when the `TAB` key is pressed (which jumps between the different
   positions in the placeholder).

3. Some REGEXes were only looking for fully uppercases version of SPARQL
   keywords like WHERE, etc. Now the are case-insensitive.
@hannahbast hannahbast changed the title Fix wild cursor when select missing Fix wild behavior when SELECT is missing + more fixes Feb 11, 2024
@hannahbast hannahbast changed the title Fix wild behavior when SELECT is missing + more fixes Fix wild behavior when SELECT is missing + other improvements in this vein Feb 11, 2024
@hannahbast hannahbast merged commit 42af38b into master Feb 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant