Commit Graph

405 Commits

Author SHA1 Message Date
Kiril Videlov
089af8e111
Merge pull request #4933 from gitbutlerapp/hunk-locking-design
HunkDiff: Display a lock if needed
2024-09-18 08:33:06 +02:00
Pavel Laptev
4f94be5439 refactor: Improve label for unapplying changes in BranchLaneContextMenu 2024-09-17 22:14:18 +02:00
estib
aecae8e2bf
fix: File section max line number & simplify hunk header calculation
- Fix a bug in which the max lines would not be taken into account when checking what the biggest line number in a hunk section.
- Simplify the calculation of the header width for the HunkDiff component
2024-09-17 17:15:09 +02:00
estib
cc6c8b9bec fix: Don't override the user settings
The user settings would not be correctly updated because multiple places were reloading it

This fixes the issue https://github.com/gitbutlerapp/gitbutler/issues/4931
2024-09-17 16:49:34 +02:00
Caleb Owens
69487faafa
Merge pull request #4935 from gitbutlerapp/Remove-BS-services
Remove BS services
2024-09-17 16:47:59 +02:00
Caleb Owens
beea22bcc3 Remove BS services 2024-09-17 16:46:08 +02:00
estib
8b2ea87ed5 HunkDiff: Display a lock if needed
Show a lock icon if the hunk in question is locked to this lane
2024-09-17 15:16:59 +02:00
Nico Domino
6476a1c754
feat: use new Tabs components to organise Preferences page (#4906) 2024-09-17 11:22:17 +02:00
Caleb Owens
b6a4f7cd35 Improve scrolling of update modal 2024-09-16 20:50:45 +02:00
estib
7dbadb13a9 Get the upstream name from the pushed virtual branch
Once the push of a virtual branch succeeded, return the ref name and the remote name in order to correctly determine which branch name to create a PR from.
2024-09-16 18:15:06 +02:00
Esteban Vega
5b34cc75bd
Merge pull request #4925 from gitbutlerapp/commit-context-menu
Add commit context menu
2024-09-16 17:31:59 +02:00
estib
a9c58aa35a fix: Extract the name from the remote ref correctly
Correctly extract the name of the remote branch, supporting branch names with nested paths

Also: Add tests
2024-09-16 16:05:12 +02:00
estib
d712fa88d1 Add commit context menu
Add a context menu to the commit card
2024-09-16 15:32:11 +02:00
estib
1398f6853b improvement: Default the selection of the project remote
The remote for a new project will default to the remote of the selected branch. It can be overwritten if needed.
2024-09-16 14:10:10 +02:00
estib
9772c02edc Base Branch Service: Type the remote branch information 2024-09-16 14:03:33 +02:00
estib
75defc2ae6 Array utils: unique items 2024-09-16 14:00:05 +02:00
estib
2dae466162 Branch Utils: enhance branch utilities with ranking functions
Add functions to determine the best branch and best remote. Implement a branch ranking system based on exact matches and suffix matches to better 
prioritize branches.
2024-09-16 13:59:17 +02:00
Nico Domino
a0b83556d2
feat: create 'Apperance' settings page and add highlight branchlane setting (#4921)
Co-authored-by: Pavel Laptev <pawellaptew@gmail.com>
2024-09-16 12:49:28 +02:00
Nico Domino
d7c00a0b9f
fix: rm effect.pre used only to avoid previous bug (#4919) 2024-09-16 12:20:34 +02:00
Mattias Granlund
02d6b6db9e Fix mistake in push failure error capature 2024-09-16 11:58:31 +02:00
estib
c9a5d7a75d Branch file list: Remove comments about actions 2024-09-16 11:42:04 +02:00
estib
08fb9effc4 Merge remote-tracking branch 'origin/master' into keyboard-shortcuts 2024-09-16 11:40:23 +02:00
estib
79e25de197 fix: actions initialization for CommitDragItem
Use a derived store to compute actions based on the branch and commit, 
removing the need for a side effect. This enhances readability and 
ensures that actions are updated reactively whenever dependencies change.
2024-09-16 10:33:16 +02:00
Mattias Granlund
97d117bb02 Improve push failed error analytics
- error message was not being included
2024-09-16 10:20:14 +02:00
Kiril Videlov
def3692df8
Merge pull request #4917 from gitbutlerapp/fix-pr-infinite-loop
fix: Don't update the state with the pre-effect
2024-09-16 10:10:00 +02:00
Esteban Vega
5faa0ac1b5
Merge pull request #4916 from gitbutlerapp/fix-file-selectability
fix: Only allow hunk selection in uncommited files
2024-09-16 10:08:35 +02:00
estib
3eadc2e743 fix: Don't update the state with the pre-effect
It seems like this would lead to an infinite loop in some cases
2024-09-16 10:03:29 +02:00
estib
2467b87fda fix: Only allow hunk selection in uncommited files
Files hunks from the commits should not be selectable
2024-09-16 09:50:59 +02:00
Pavel Laptev
8ec4fbdd67 few CSS fixes 2024-09-15 23:07:04 +02:00
estib
2bf882676f fix HunkDiff borders
The borders move with the hunk diffs
2024-09-15 10:49:47 +02:00
Pavel Laptev
1c70cdc3f4
Fixes scroll on drag (#4913)
* remove old tailwind CSS class

* fix `onDestroy` lifecycle error

* fix scroll glitch for changed files while dragging
2024-09-14 17:43:06 +02:00
Esteban Vega
1a47f5ec4d
Merge pull request #4850 from gitbutlerapp/ndom91/use-template-dropdown
fix: refactor pr template path input to pre-filled `Select` instead of `TextBox`
2024-09-13 17:25:58 +02:00
Caleb Owens
edd0cbe0e6 Rename unapplying 2024-09-13 16:58:42 +02:00
Nico Domino
c952ffee65
Merge branch 'master' into ndom91/use-template-dropdown 2024-09-13 16:28:58 +02:00
Caleb Owens
ce2aa91385 feat: Add onclick prop to DefaultTargetButton
Add onclick prop to DefaultTargetButton component to enable
button functionality. This change allows the component to handle
click events and perform specified actions when the button is
clicked.
2024-09-13 16:07:25 +02:00
ndom91
147a8aafcd fix: tweak copy 2024-09-13 12:56:08 +02:00
ndom91
d1d2e0c80b fix: cleanup pr template method names 2024-09-13 12:10:07 +02:00
ndom91
e8bb66c151 fix: use relativePath and get project basePath on rust side 2024-09-13 12:01:03 +02:00
ndom91
d14b6496b1 fix: rename githost form 2024-09-13 11:29:24 +02:00
ndom91
907bbe838d fix: more conflict clean up 2024-09-13 11:17:04 +02:00
ndom91
e842b282ae fix: merge conflicts 2024-09-13 11:15:06 +02:00
Mattias Granlund
eec288548a Remove displayed remoteRef from commit card 2024-09-12 18:38:09 +02:00
Mattias Granlund
8aafd8345d Show pr card for commit group if such exists 2024-09-12 18:38:09 +02:00
Mattias Granlund
1b175bb119 Re-use push button with snippet 2024-09-12 18:38:09 +02:00
Mattias Granlund
ab08bb9a47 Render one commit list per commit group 2024-09-12 18:38:09 +02:00
Mattias Granlund
5b3dff9634 Toggle feature by typing s t a c k 2024-09-12 18:38:09 +02:00
Mattias Granlund
bd7be6a759 Convert CommitList to svelte5 component 2024-09-12 18:38:09 +02:00
Mattias Granlund
6a7ae9dcb3 Add stack grouping function 2024-09-12 18:38:09 +02:00
Mattias Granlund
35b3991ab8 Use modified branch header whens stacking is enabled 2024-09-12 18:38:09 +02:00
estib
5395d00a1a Merged origin/master into keyboard-shortcuts 2024-09-12 14:47:17 +02:00
Caleb Owens
3c61856481
Merge pull request #4894 from gitbutlerapp/improve-topics
improve topics
2024-09-12 14:12:41 +02:00
Caleb Owens
bd1cc06af2 Use pagination API for querying labels 2024-09-12 14:06:12 +02:00
Caleb Owens
c78fe929d9 Improve topics just a tad 2024-09-12 13:56:18 +02:00
Nico Domino
3bc54fcad0
fix: rm unnecessary extra markdown wrapping class (#4893) 2024-09-12 11:38:50 +00:00
Caleb Owens
db992dedfa
Merge pull request #4869 from gitbutlerapp/update-api
Update api
2024-09-12 13:23:05 +02:00
Nico Domino
3a478b4f15
fix: reactive markdown rendering (#4888) 2024-09-12 09:53:21 +00:00
estib
5352eb1717 Merged origin/master into keyboard-shortcuts 2024-09-12 09:13:39 +02:00
Pavel Laptev
7c0a3766af usused CSS removed 2024-09-12 02:03:22 +02:00
Pavel Laptev
8723bd5c17 selected hunk colors update 2024-09-12 01:48:01 +02:00
Pavel Laptev
96d52014e0 Fix hunk header styles
- There was an issue with borders on scroll
- Fix the hunk header paddings
- replaced `box-shadow` with borders. Looks like it's not longer an issue
2024-09-12 01:29:28 +02:00
Pavel Laptev
e4df03aa50 remove unused code 2024-09-12 01:27:41 +02:00
Pavel Laptev
965118de7a Remove duplicated hunk inf and replace indicators with infomessages 2024-09-11 23:29:10 +02:00
Nico Domino
4700d5b2f1
fix: improve deeply nested token rendering (#4883) 2024-09-11 18:36:57 +02:00
estib
5137517650 BranchFilesList keybindings: Select all files
Select all files with meta-key + 'a'.
Also, `fileIdSelection` will make sure that the no duplicates are added to the selection
2024-09-11 17:31:33 +02:00
estib
d41827c9d1 BranchFilesList keybindings: Stage and unstage files
Stage or unstage the files by pressing the space-bar on the selected files.
Click enter to focus on the commit message input field
2024-09-11 17:20:56 +02:00
estib
f3b3649bca Merged origin/master into keyboard-shortcuts 2024-09-11 17:03:04 +02:00
Caleb Owens
d76d900a7e
Fix janky generics 2024-09-11 16:00:04 +02:00
estib
b8c60adc64 Merge branch 'master' into keyboard-shortcuts 2024-09-11 15:50:07 +02:00
estib
c3273c10fe Commit Input: Control focus behaviors
Add the ability to control externally when the commit message text input is focused.

Also:
Opent the commit input when a file is selected and the space bar is pressed
2024-09-11 15:43:38 +02:00
Esteban Vega
c4686bbf63
Merge pull request #4859 from gitbutlerapp/check-boxes-behavior
Improve the file list checkboxes behavior
2024-09-11 15:43:18 +02:00
estib
4c93b3632e Clean-up: Remove console log 2024-09-11 15:40:10 +02:00
Caleb Owens
aeea013ba0
Update base branch button feature flagged 2024-09-11 15:18:20 +02:00
estib
b08fb7d101 Commit Input: Close on 'Escape'
Pressing 'Escape' will close the commit input file
2024-09-11 14:30:29 +02:00
Esteban Vega
2d8b82309d
Merge pull request #4876 from gitbutlerapp/file-navigation
fix: File key navigation and selection
2024-09-11 14:28:43 +02:00
Nico Domino
0595319405
fix: rm unnecessary Space.svelte and add List/ListItem (#4874) 2024-09-11 13:59:08 +02:00
Nico Domino
a1ff2079db
fix: createPr arguments order (#4878) 2024-09-11 11:43:26 +00:00
estib
390119e009 fix: File key navigation and selection 2024-09-11 12:19:52 +02:00
Pavel Laptev
25c2f516fd
style: Updated box-shadow to use custom variable in ContextMenu and Select components (#4870) 2024-09-11 12:12:10 +02:00
Caleb Owens
191686ec4d
Ahhh, don't loose shit 2024-09-11 11:23:20 +02:00
Caleb Owens
f5477a502b
Issues 2024-09-10 22:35:02 +02:00
estib
aaae6e605c HunkDiff: Udpate the diff table style 2024-09-10 19:52:35 +02:00
ndom91
09b02feb78 fix: wire up prService template fns correctly 2024-09-10 19:29:24 +02:00
ndom91
b7a037b1dc fix: move new template methods to PRService 2024-09-10 19:18:42 +02:00
ndom91
781fbb5a13 fix: merge conflict 2024-09-10 18:55:45 +02:00
ndom91
f53b5b8f2e chore: more cleanup 2024-09-10 17:34:22 +02:00
ndom91
4aa9e96ced fix: use pullRequestPath as boolean 2024-09-10 17:24:51 +02:00
ndom91
eecea80884 fix: read pr tempalte from disk 2024-09-10 17:14:35 +02:00
ndom91
bfcc4abc26 chore: add notes to other githost types 2024-09-10 14:02:11 +02:00
ndom91
25bbe28411 fix: cleanup and pass absolute path from rust to FE 2024-09-10 13:55:18 +02:00
ndom91
e888025499 fix: move PrTemplate fns to gitHost 2024-09-10 12:22:02 +02:00
estib
ba021da232 PR service: Initialize it only with the base branch
Re-write the PR service interface in order to set the upstream branch when creating the PR, not the service.
2024-09-10 11:16:03 +02:00
estib
041344bab5 Utils: Create branch module
Add a branch utilities module with a function that retrieves the branch name from a reference
2024-09-10 11:09:20 +02:00
Pavel Laptev
85462206a4
Edit mode UI updates (#4862)
* Show full status tag only if file modified

* tooltip to the page added
2024-09-10 11:35:17 +02:00
ndom91
bfe299aa98 fix: cleanup and PR review 2024-09-10 10:37:15 +02:00
estib
94b4744c3f Move the error logging to the Branch controller 2024-09-10 09:19:33 +02:00
ndom91
a5fb400985 fix: simplify setting git_host default settings in projects.json 2024-09-09 15:35:15 +02:00
ndom91
22f71c2a58 fix: rename get_pr_templates fn to github specific 2024-09-09 15:22:05 +02:00
ndom91
e0c2bdfe14 fix: eslint BranchHeader import-order 2024-09-09 14:57:41 +02:00
ndom91
8efe6c7a71 fix: cleanup createPr arguments and types 2024-09-09 14:02:59 +02:00
estib
8c22b6c0d1 Update Ownership class
Rename the `Ownership` class to `SelectedOwnership`, as it is only used to determine the selected state of the files to add to a commit.

Renamed the methods as well to convey their actual purpose.

The `SelectedOwnership` class will be updated in a way that the selected is persisted across file/hunk ownership updates
2024-09-09 13:53:57 +02:00