Skip to content

Commit d98bf09

Browse files
AndreasArvidssonphillcopre-commit-ci-lite[bot]
authored
Collection item scope provider (#2683)
Fixes #1059 Related #1052 ## Checklist - [x] I have added [tests](https://www.cursorless.org/docs/contributing/test-case-recorder/) - [/] I have updated the [docs](https://github.com/cursorless-dev/cursorless/tree/main/docs) and [cheatsheet](https://github.com/cursorless-dev/cursorless/tree/main/cursorless-talon/src/cheatsheet) - [/] I have not broken the cheatsheet --------- Co-authored-by: Phil Cohen <[email protected]> Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
1 parent 071739d commit d98bf09

File tree

81 files changed

+1693
-1052
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+1693
-1052
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
tags: [enhancement]
3+
pullRequest: 2683
4+
---
5+
6+
At long last, collection items have been migrated to our next generation scope framework! This means, within a list of items, you can now use relative navigation (`previous item`), absolute navigation via ordinals (`fifth item`), multiple selection (`two items`, optionally preceded with `previous` or `next`), and lastly, requesting multiple items to be individually selected via `every` (`every two items`)!

data/fixtures/recorded/itemTextual/chuckItem4.yml

-31
This file was deleted.

data/fixtures/recorded/itemTextual/clearEveryItemToken.yml

-25
This file was deleted.

data/fixtures/recorded/itemTextual/clearItem10.yml

-23
This file was deleted.

data/fixtures/recorded/itemTextual/clearItem11.yml

-23
This file was deleted.

data/fixtures/recorded/itemTextual/clearItem13.yml

-23
This file was deleted.

data/fixtures/recorded/itemTextual/clearItem14.yml

-23
This file was deleted.

data/fixtures/recorded/itemTextual/clearItem6.yml

-23
This file was deleted.

data/fixtures/recorded/itemTextual/clearItemDrip.yml

-27
This file was deleted.

data/fixtures/recorded/languages/clojure/chuckItemZip.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@ finalState:
2929
documentContents: |-
3030
{
3131
:foo "bar",
32-
;; hello
33-
,
3432
}
3533
selections:
36-
- anchor: {line: 4, character: 1}
37-
active: {line: 4, character: 1}
34+
- anchor: {line: 2, character: 1}
35+
active: {line: 2, character: 1}

data/fixtures/recorded/languages/clojure/clearEveryItem.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,10 @@ finalState:
2727
2828
{
2929
,
30-
;; hello
3130
,
3231
}
3332
selections:
3433
- anchor: {line: 2, character: 4}
3534
active: {line: 2, character: 4}
36-
- anchor: {line: 4, character: 4}
37-
active: {line: 4, character: 4}
35+
- anchor: {line: 3, character: 4}
36+
active: {line: 3, character: 4}

data/fixtures/recorded/languages/clojure/clearItem.yml

+6-3
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,11 @@ initialState:
2626
finalState:
2727
documentContents: |-
2828
{
29-
29+
:bongo {
30+
:foo "bar",
31+
,
32+
}
3033
}
3134
selections:
32-
- anchor: {line: 1, character: 4}
33-
active: {line: 1, character: 4}
35+
- anchor: {line: 3, character: 8}
36+
active: {line: 3, character: 8}

data/fixtures/recorded/languages/clojure/clearItemFine.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ initialState:
2121
start: {line: 0, character: 2}
2222
end: {line: 0, character: 5}
2323
finalState:
24-
documentContents: "{ :baz \"whatever\"}"
24+
documentContents: "{}"
2525
selections:
2626
- anchor: {line: 0, character: 1}
2727
active: {line: 0, character: 1}

data/fixtures/recorded/languages/rust/changeItemOne.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ initialState:
2323
end: {line: 0, character: 21}
2424
finalState:
2525
documentContents: |
26-
let x = [None, ];
26+
let x = [None, Some()];
2727
selections:
28-
- anchor: {line: 0, character: 15}
29-
active: {line: 0, character: 15}
28+
- anchor: {line: 0, character: 20}
29+
active: {line: 0, character: 20}

data/fixtures/recorded/languages/typescript/takeItem4.yml

-27
This file was deleted.

data/fixtures/recorded/languages/typescript/takeItemComma.yml

-31
This file was deleted.

0 commit comments

Comments
 (0)