Commit Graph

474 Commits

Author SHA1 Message Date
Kiril Videlov
0e6a88a236 🔨 Refactor project search page diffs
- Improve search feature in project pages
- Highlight search terms in diff lines
- Use `date-fns` to format dates

[src/routes/projects/[projectId]/search/+page.svelte]
- Add `formatDistanceToNow` from `date-fns`
- Add `getDiffHunksWithSearchTerm` and `processHunkLines` functions
- Change `diffParagraph` to `getDiffHunksWithSearchTerm`
- Change the layout of the diff lines to highlight the search term
- Remove `onMount` function and related code
2023-03-09 11:04:09 +01:00
Nikita Galaiko
6bb919b238
temporary fix for duplicated deltas issue 2023-03-09 09:51:38 +01:00
Nikita Galaiko
76773aec0b
drop difference 2023-03-08 17:22:42 +01:00
Nikita Galaiko
5b146d90f0
test multi char operations 2023-03-08 16:59:52 +01:00
Nikita Galaiko
ff1bd5f02f
pnpm format 2023-03-08 15:15:14 +01:00
Kiril Videlov
626d3bf755 🔨 Refactor search page to improve recordings, completions, and tests
- Update packages and add new features to the project search page
- Add 1000ms delay to search query
- Add functions to apply deltas to a text string and diff a paragraph with a query
- Add a code viewer with syntax highlighting for search results

[pnpm-lock.yaml]
- Add `diff` package (version 5.1.0)
- Update `date-fns` to version 2.29.3
- Update `@typescript-eslint/parser` to version 5.45.0
- Update `autoprefixer` to version 10.4.7
- Update `eslint` to version 8.28.0
- Update `eslint-config-prettier` to version
[package.json]
- Add `diff` package to `package.json`
[src/routes/projects/[projectId]/search/+page.svelte]
- Add 1000ms delay to search query
- Add a function to apply deltas to a text string
- Add a function to diff a paragraph with a query
- Add a timestamp to the file path in the search results
- Add a span to the file path with the date of the delta
- Add a code viewer with highlighting for the search results
- Add a pre tag with highlighting for the search results
2023-03-08 15:14:56 +01:00
Nikita Galaiko
f10cf6b251
re-render codeviewer when doc/filepath pair changes 2023-03-08 14:52:46 +01:00
Nikita Galaiko
5bcd1cdd4f
more natural timeline scaling 2023-03-08 14:27:04 +01:00
Nikita Galaiko
9f1e949e10
do not show outside of permitted ranges 2023-03-08 13:45:24 +01:00
Nikita Galaiko
6a0c235d9b
changing slider pos updates the player 2023-03-08 13:26:40 +01:00
Nikita Galaiko
a4b9ec57d9
pnpm format 2023-03-08 12:33:23 +01:00
Nikita Galaiko
53b7ce67df
base player timeline 2023-03-08 12:33:23 +01:00
Kiril Videlov
7a5ee73ea6 prevet eye bleeding 2023-03-08 10:30:45 +01:00
Nikita Galaiko
14d3d26cc9
minor adjust codeviewer colors 2023-03-08 09:30:15 +01:00
Nikita Galaiko
21b9c08299
less cpu intensive player 2023-03-08 09:15:38 +01:00
Kiril Videlov
2af1317fd2 search results: highlight changed location 2023-03-07 18:51:02 +01:00
Kiril Videlov
2ed305cb01 render search results results 2023-03-07 17:56:39 +01:00
Nikita Galaiko
33f1525b06
fix linter 2023-03-07 17:14:37 +01:00
Nikita Galaiko
6cfc25c2f2
split int & check actions 2023-03-07 17:11:49 +01:00
Nikita Galaiko
3ae62f29e0 fix tests 2023-03-07 17:10:48 +01:00
Nikita Galaiko
5dfde966ab replace diffing library 2023-03-07 17:10:48 +01:00
Nikita Galaiko
fcb45bb8a5 crude player page 2023-03-07 17:10:15 +01:00
Ian Donahue
e7341094b8 Merge branch 'master' into visual-design-updates 2023-03-07 13:37:00 +01:00
Kiril Videlov
a6b2430e3d
Merge pull request #28 from gitbutlerapp/index-by-full-diff
use full diff when indexing
2023-03-07 13:21:33 +01:00
Nikita Galaiko
b3c29abe00
use full diff when indexing 2023-03-07 13:11:03 +01:00
Nikita Galaiko
0a247e31ab
include prettier-plugin-tailwindcss into config 2023-03-07 11:53:11 +01:00
Nikita Galaiko
e49e3433ed
setup prettier-plugin-tailwindcss 2023-03-07 11:52:18 +01:00
Kiril Videlov
efc07705e4 release the lock when there are broken projects 2023-03-07 10:18:56 +01:00
Kiril Videlov
96e4f16703 dont panic on search error 2023-03-07 10:05:27 +01:00
Kiril Videlov
04734efcf4 lower the session related logging output 2023-03-07 09:46:17 +01:00
Nikita Galaiko
6b9c2db7a0 pnpm format 2023-03-06 15:41:11 +01:00
Nikita Galaiko
0aefc8be61 support time ranges 2023-03-06 15:41:11 +01:00
Nikita Galaiko
c6c3c3feb5 add limit & offset to the query 2023-03-06 15:41:11 +01:00
Nikita Galaiko
cfd151fcb9 sort results by timestamp 2023-03-06 15:41:11 +01:00
Nikita Galaiko
b1fc932a81 add test search page 2023-03-06 15:41:11 +01:00
Nikita Galaiko
41842ee356 expose search api 2023-03-06 15:41:11 +01:00
Nikita Galaiko
3f65a3e72f store all projects in the same index 2023-03-06 15:41:11 +01:00
Kiril Videlov
5ed947747b 🤦 2023-03-06 12:26:52 +01:00
Kiril Videlov
a300e1408f fix tauri build error 2023-03-06 10:15:36 +01:00
Nikita Galaiko
59eb1fd8a6 run indexing in a background 2023-03-06 08:23:15 +01:00
Nikita Galaiko
c0fd0bd729 implement reindexing 2023-03-06 08:23:15 +01:00
Nikita Galaiko
f78d5b104f check size when applying operations 2023-03-06 08:23:15 +01:00
Nikita Galaiko
887b676acb start recording new sessions 2023-03-06 08:23:15 +01:00
Nikita Galaiko
d962e2d7d1 rename git watcher -> session watcher 2023-03-06 08:23:15 +01:00
Nikita Galaiko
d85b40f472 make searcher non-project specific 2023-03-06 08:23:15 +01:00
Nikita Galaiko
d04df229d6 implmenet basic search 2023-03-06 08:23:15 +01:00
Nikita Galaiko
41824e2c85 add deltas index writer 2023-03-06 08:23:15 +01:00
Nikita Galaiko
895125c4f7
pnpm format 2023-03-06 08:22:26 +01:00
Ian Donahue
afe5e93ebb bordradius 2023-03-05 15:49:36 +01:00
Ian Donahue
05bcbc2712 Test commit 2023-03-05 15:40:13 +01:00