Commit graph

10499 commits

Author SHA1 Message Date
Antonio Scandurra
0dfa3c60b7 Remove some todos 2023-11-03 10:50:30 +01:00
Antonio Scandurra
11feda01e3 Uncomment Editor::new 2023-11-03 10:38:28 +01:00
Antonio Scandurra
2fccde5ab6 Remove unused code 2023-11-03 10:11:13 +01:00
Antonio Scandurra
efa27cf9b8 Uncomment more editor code 2023-11-03 10:09:00 +01:00
Kirill Bulatov
09346fb9f1 Port changes to zed2 2023-11-03 11:02:50 +02:00
Kirill Bulatov
24dd1c5812 Properly order default prettier installations and startups 2023-11-03 11:02:50 +02:00
Kirill Bulatov
244c693968 Reuse already running default prettiers 2023-11-03 11:02:50 +02:00
Kirill Bulatov
cf95f9b082 Make it more clear that missing prettier is to blame 2023-11-03 11:02:50 +02:00
Kirill Bulatov
369b5140fb Restore LSP names for prettier servers 2023-11-03 11:02:50 +02:00
Kirill Bulatov
b75d8a60a8 Simplify 2023-11-03 11:02:50 +02:00
Kirill Bulatov
ff144def63 Fix the bugs 2023-11-03 11:02:50 +02:00
Kirill Bulatov
6bbb79a9f5 Rework prettier installation and start 2023-11-03 11:02:50 +02:00
Kirill Bulatov
d673efebd2 Add prettier workspace resolution test 2023-11-03 11:02:50 +02:00
Antonio Scandurra
cdc82d01f7 Call editor::init 2023-11-03 09:06:25 +01:00
Antonio Scandurra
800c2685ea Remove dependency from gpui from editor2 2023-11-03 09:05:58 +01:00
Nathan Sobo
fbee6b5352 Get editor2 compiling with a ton of code commented out 2023-11-02 23:35:20 -06:00
Nathan Sobo
f3b8a9d8c2 WIP 2023-11-02 22:56:04 -06:00
Nathan Sobo
a731f8fb1e WIP 2023-11-02 21:28:56 -06:00
Nathan Sobo
dfc7c81500 WIP 2023-11-02 21:03:29 -06:00
Nathan Sobo
72b9dc8216 Merge remote-tracking branch 'origin/main' into editor2 2023-11-02 20:47:09 -06:00
Nathan Sobo
6a89f7ce4f
rich text2 (#3220)
- git -> git3
- Add rich_text2

[[PR Description]]

Release Notes:

N/A
2023-11-02 20:46:45 -06:00
Nathan Sobo
2a12e8f307 Merge remote-tracking branch 'origin/rich_text2' into editor2 2023-11-02 20:34:52 -06:00
Nate Butler
383d9129f4 [Not compiling] Continue working on VSCode import 2023-11-02 21:49:26 -04:00
Conrad Irwin
0b3932f38c Convert rich_text2 2023-11-02 19:30:33 -06:00
Conrad Irwin
6ecb4805f7 Add rich_text2 2023-11-02 19:19:18 -06:00
Conrad Irwin
cbd902658c git -> git3
This is needed for the editor.
2023-11-02 19:18:01 -06:00
Conrad Irwin
0aabb19a45 Into the woods 2023-11-02 18:52:08 -06:00
Nate Butler
b4e2368943 Merge branch 'main' into import-theme 2023-11-02 20:16:09 -04:00
Nate Butler
0d0b6db24f Update theme importer 2023-11-02 20:15:51 -04:00
Nate Butler
2b0c959137 Add terminal colors to ThemeColors, add _background to some color names. 2023-11-02 19:53:52 -04:00
Nathan Sobo
9052b48949
Use correct color values in quad fragment shader (#3217)
Previously, when using rounded corners, the borders would get wider.
Looks like we weren't using the input color values consistently in the
fragment shader. The quad values are raw HSLA and are converted in the
vertex shader.

Release Notes:

- N/A
2023-11-02 17:49:56 -06:00
Marshall Bowers
95a0827517 Clean up unused code 2023-11-02 19:20:21 -04:00
Marshall Bowers
152ac6927f Add themes2/src/themes directory 2023-11-02 19:17:39 -04:00
Marshall Bowers
d1636bf16b Finish up theme printer 2023-11-02 19:14:51 -04:00
Marshall Bowers
fc376287e0 Start work on theme printer 2023-11-02 18:57:13 -04:00
Nathan Sobo
7b712ac68f WIP 2023-11-02 16:47:14 -06:00
Marshall Bowers
0bc51382b2 Add basic VsCodeThemeConverter 2023-11-02 18:24:38 -04:00
Marshall Bowers
e48332c81f Parse VSCode theme files 2023-11-02 18:00:55 -04:00
Conrad Irwin
583c36e24b WIP 2023-11-02 15:27:49 -06:00
Nate Butler
058981350c Scaffold out new theme-importer crate
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-02 17:21:11 -04:00
Conrad Irwin
09efa017d4 Editor2 2023-11-02 14:36:42 -06:00
Conrad Irwin
9e5275cc18 Fix error handling of open_path
Co-Authored-By: Nathan <nathan@zed.dev>
2023-11-02 14:34:43 -06:00
Nate Butler
972f076b4d Deserialize theme metadata 2023-11-02 16:31:22 -04:00
Nate Butler
58ac7f2926 [Broken] Load a src theme in test 2023-11-02 16:26:27 -04:00
Marshall Bowers
54969877a4
Make the Zed2 window movable (#3218)
This PR makes the Zed2 window movable and fixes a crash related to a
`todo!()` that wasn't necessary.

Release Notes:

- N/A
2023-11-02 16:17:31 -04:00
Conrad Irwin
8283909dfd Disable selective warnings to make cargo check happy 2023-11-02 13:28:58 -06:00
Nathan Sobo
91f3e9707a Use correct color values in quad fragment shader
Co-Authored-By: Julia Risley <julia@zed.dev>
2023-11-02 13:18:20 -06:00
Conrad Irwin
269a72464d Merge remote-tracking branch 'origin/main' into zed2-workspace 2023-11-02 13:16:24 -06:00
Mikayla Maki
85f0959548
Remove the 2s from source code (#3216)
Release Notes:

- N/A
2023-11-02 12:11:16 -07:00
Marshall Bowers
9c8220d04e Remove commented-out label code 2023-11-02 15:04:52 -04:00
Nate Butler
809d8786f1 WIP 2023-11-02 14:54:53 -04:00
Marshall Bowers
3605afc163 Render active item in pane 2023-11-02 14:40:34 -04:00
Marshall Bowers
8b1b7a2f80 Checkpoint: Basic tab bar structure 2023-11-02 14:34:48 -04:00
Nathan Sobo
29d8390743 Fix formatting 2023-11-02 12:28:58 -06:00
Nathan Sobo
1dd20d4c0a Merge remote-tracking branch 'origin/main' into gpui2-image-reborrow 2023-11-02 12:25:06 -06:00
Nate Butler
004c5d309b WIP 2023-11-02 14:23:43 -04:00
Nathan Sobo
04a8ee222b Enforce a Send bound on next frame callbacks
This required using mpsc channels to invoke frame callbacks on the
main thread and send the receiver to the platform display link.

Co-Authored-By: Julia Risley <julia@zed.dev>
2023-11-02 12:01:22 -06:00
Mikayla
d11ff14b57
Remove the 2s from source code 2023-11-02 10:55:02 -07:00
Conrad Irwin
5a41eed120 WIP 2023-11-02 11:34:31 -06:00
Marshall Bowers
1e7a216d55 WIP 2023-11-02 13:21:28 -04:00
Conrad Irwin
8f0f5a9ba1 Render status bar
Co-Authored-By: Antonio <me@as-cii.com>
2023-11-02 11:18:11 -06:00
Conrad Irwin
803d2b6710 Add double click to zoom the window
Co-Authored-By: Antonio <me@as-cii.com>
2023-11-02 10:58:46 -06:00
Marshall Bowers
0e1d2fdf21 Checkpoint: Narrow down error 2023-11-02 12:47:06 -04:00
Marshall Bowers
66e4d75e6f Checkpoint: Reproduction with Avatar story 2023-11-02 12:34:40 -04:00
Conrad Irwin
bd54bfa4e1 Render titlebar
Co-Authored-By: Mikayla <mikayla@zed.dev>
2023-11-02 10:31:18 -06:00
Conrad Irwin
634aba89d2 Add back some window events for workspace
Co-Authored-By: Antonio <me@as-cii.com>
2023-11-02 10:03:03 -06:00
Nate Butler
a3565225ad
Document format_distance (#3214)
Adds docs for `ui2::util::format_distance`:
- distance_in_seconds
- distance_string
- naive_format_distance
- naive_format_distance_from_now

These are ports of
[`date-fns`](https://date-fns.org/v2.30.0/docs/formatDistance)'s format
distance utilities

[[PR Description]]

Release Notes:

- N/A
2023-11-02 11:58:45 -04:00
Julia
17ff881e7a
Uncomment lsp2 tests (#3213)
Release Notes:

- N/A
2023-11-02 11:54:06 -04:00
Nate Butler
6f41a77a25 Document format_distance
Adds docs for:
- distance_in_seconds
- distance_string
- naive_format_distance
- naive_format_distance_from_now
2023-11-02 11:53:20 -04:00
Conrad Irwin
0bab1a92df Merge remote-tracking branch 'origin/main' into zed2-workspace 2023-11-02 09:44:38 -06:00
Antonio Scandurra
fd81d838fe
Introduce ViewContext::observe_window_{activation,bounds} (#3212)
Release Notes:

- N/A
2023-11-02 16:44:26 +01:00
Julia
b7efab8a55 Uncomment lsp2 tests 2023-11-02 11:42:48 -04:00
Marshall Bowers
ec0cff0e1a
Add map method to Components (#3210)
This PR adds a `map` method to the `Component` trait.

`map` is a fully-generalized form of `when`, as `when` can be expressed
in terms of `map`:

```rs
div().map(|this| if condition { then(this) } else { this })
```

This allows us to take advantage of Rust's pattern matching when
building up conditions:

```rs
// Before
div()
    .when(self.current_side == PanelSide::Left, |this| this.border_r())
    .when(self.current_side == PanelSide::Right, |this| {
        this.border_l()
    })
    .when(self.current_side == PanelSide::Bottom, |this| {
        this.border_b().w_full().h(current_size)
    })

// After
div()
    .map(|this| match self.current_side {
        PanelSide::Left => this.border_r(),
        PanelSide::Right => this.border_l(),
        PanelSide::Bottom => this.border_b().w_full().h(current_size),
    })
```

Release Notes:

- N/A
2023-11-02 11:39:40 -04:00
Antonio Scandurra
ec4f0d7bca Implement ViewContext::observe_window_activation
Co-Authored-By: Conrad Irwin <conrad@zed.dev>
2023-11-02 16:37:57 +01:00
Antonio Scandurra
3a824e468f Subsume observe_fullscreen into observe_window_bounds
Co-Authored-By: Conrad Irwin <conrad@zed.dev>
2023-11-02 16:31:27 +01:00
Nate Butler
5e12b48ae0
Work on default theme, Notifications, Add ListHeader meta (#3203)
Work on default theme, Notifications, Add ListHeader `meta`

Also adds `naive_format_distance` & `naive_format_distance_from_now`

Release Notes:

- N/A
2023-11-02 11:19:48 -04:00
Antonio Scandurra
de80974a1d Add ViewContext::observe_fullscreen
Co-Authored-By: Conrad Irwin <conrad@zed.dev>
2023-11-02 16:11:52 +01:00
Nate Butler
d4db7a14b3 Remove unused import 2023-11-02 11:04:04 -04:00
Nate Butler
3b91a76159 Merge branch 'main' into n/t2 2023-11-02 11:02:55 -04:00
Nate Butler
d48ec7d58e Remove unused import 2023-11-02 11:02:46 -04:00
Nate Butler
6d562aaa6f Use naive_format_distance_from_now in Notifications 2023-11-02 11:02:17 -04:00
Julia
46e81da4e1 Uncomment db2 tests 2023-11-02 11:01:38 -04:00
Nate Butler
b76c117979 Update naive_format_distance and tests 2023-11-02 10:37:33 -04:00
Kyle Caverly
5ee2b01102
authenticate with completion provider on new inline assists (#3209)
authenticate with completion provider on new inline assists

Release Notes:

- Fixed bug which lead the inline assist functionality to never
authenticate
2023-11-02 10:14:52 -04:00
Nate Butler
cde7b244bc Checkpoint - impl format_distance 2023-11-02 10:11:25 -04:00
KCaverly
d5b6300fd7 moved from Boxes to Arcs for shared access of completion providers across the assistant panel and inline assistant 2023-11-02 10:08:47 -04:00
Nathan Sobo
52e195b47c WIP 2023-11-02 07:46:49 -06:00
KCaverly
b5fe0d72ee authenticate with completion provider on new inline assists 2023-11-02 09:34:18 -04:00
Joseph T. Lyons
5412f20e35 Fix missing commit (collab version bump) 2023-11-02 09:22:12 -04:00
Antonio Scandurra
d4e199cab1 WIP 2023-11-02 13:58:42 +01:00
Antonio Scandurra
c1ca7ad41d Implement WindowContext::remove_window 2023-11-02 13:37:55 +01:00
Antonio Scandurra
089bf58934 Implement AppState::test 2023-11-02 13:34:21 +01:00
Antonio Scandurra
32dded551c Checkpoint 2023-11-02 11:05:24 +01:00
Antonio Scandurra
72156bf502 Merge remote-tracking branch 'origin/main' into zed2-workspace 2023-11-02 11:04:47 +01:00
Antonio Scandurra
76c675a63b 💄 2023-11-02 10:57:29 +01:00
Antonio Scandurra
32db64a049 Introduce more GPUI2 APIs needed for transitioning the workspace 2023-11-02 10:54:33 +01:00
Antonio Scandurra
51338d785c WIP 2023-11-02 10:09:08 +01:00
Antonio Scandurra
bda43ca1fe Merge remote-tracking branch 'origin/main' into zed2-workspace 2023-11-02 10:06:05 +01:00
Antonio Scandurra
9c7b45f38b Add back Send and Sync to AssetSource 2023-11-02 09:58:53 +01:00
Antonio Scandurra
d5f0e91faa Remove stray todo 2023-11-02 09:56:45 +01:00
Antonio Scandurra
5e50430299 Fix compile errors 2023-11-02 09:47:21 +01:00
Antonio Scandurra
64ad8943ba Remove more Send bounds and simplify view rendering 2023-11-02 09:44:16 +01:00
Antonio Scandurra
2fb4c04fc3 Remove more Send bounds and remove EraseViewState 2023-11-02 09:39:06 +01:00
Antonio Scandurra
b2c7ddc41f Remove some stray Send bounds 2023-11-02 09:18:16 +01:00
Antonio Scandurra
18fcb41292 Simplify contexts 2023-11-02 09:15:14 +01:00
Antonio Scandurra
ff27700913 Fix outstanding errors in gpui2 2023-11-02 09:08:47 +01:00
Nathan Sobo
3e7df82977 WIP: Merge branch 'main' into zed2-workspace 2023-11-01 22:35:02 -06:00
Nathan Sobo
64ee1bb7a5 Fix prod compile error 2023-11-01 21:19:06 -06:00
Nathan Sobo
2079cd641e Fix post-merge compile errors 2023-11-01 21:16:41 -06:00
Nathan Sobo
db9ccd7f34 Merge remote-tracking branch 'origin/main' into gpui2-no-send 2023-11-01 21:10:31 -06:00
Nathan Sobo
57dfc50687 Get language2 tests passing by not blocking on a foreground task 2023-11-01 21:04:17 -06:00
Nathan Sobo
53066df522 Get project2 tests green 2023-11-01 20:14:40 -06:00
Marshall Bowers
aa14552fee Remove unneeded .intos 2023-11-01 22:01:59 -04:00
Marshall Bowers
b9ac1e43cd Update scale accessors 2023-11-01 22:00:16 -04:00
Marshall Bowers
bd4bff47a0 Merge branch 'main' into n/t2 2023-11-01 21:54:10 -04:00
Marshall Bowers
72d060108d
Make indexing into ColorScales safe (#3205)
This PR makes indexing into `ColorScale`s safe by constraining the
`ColorScaleStep`s to a set of known values.

Release Notes:

- N/A
2023-11-01 21:52:42 -04:00
Marshall Bowers
220228c183 Fix underflow when indexing into ColorScales 2023-11-01 21:15:06 -04:00
Marshall Bowers
115bd65344 Merge branch 'main' into n/t2 2023-11-01 21:11:26 -04:00
Marshall Bowers
69aafe9ff6
Adjust ColorScale representation (#3204)
This PR adjusts the representations of `ColorScale`s to allow us to
remove an unsafe `From` impl when converting from the statically-defined
representation of the scale.

Release Notes:

- N/A
2023-11-01 21:10:50 -04:00
Max Brunsfeld
401ddc6f49 WIP - flush_fs_events 2023-11-01 17:45:38 -07:00
Max Brunsfeld
6ee93125d0 Fix hangs in new dispatcher
Co-authored-by: Nathan Sobo <nathan@zed.dev>
2023-11-01 17:11:42 -07:00
Conrad Irwin
90facc051a beautiful diff 2023-11-01 15:31:37 -06:00
Nate Butler
d0975aacac Merge branch 'main' into n/t2 2023-11-01 16:52:43 -04:00
Nate Butler
229ba0744e Add additional notifications and style tweaks
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-01 16:50:59 -04:00
Nate Butler
be3cc6458c Implement Notifications
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-01 16:34:42 -04:00
Conrad Irwin
f415a37a3d
Uncomment project2 tests (#3200) 2023-11-01 20:27:53 +00:00
Conrad Irwin
cd10ba9e06 Use run_until_parked instead of blocked in tests 2023-11-01 14:27:25 -06:00
Nate Butler
3f74f75dee WIP 2023-11-01 16:19:49 -04:00
KCaverly
77dbb15aa3 port text2 to zed2 2023-11-01 16:13:53 -04:00
Nathan Sobo
3f34a8e7ec Checkpoint 2023-11-01 14:00:26 -06:00
Nathan Sobo
11b6d9e33a Split out a foreground and background executor 2023-11-01 13:53:45 -06:00
Max Brunsfeld
dd1a2a9e44 wip 2023-11-01 13:53:45 -06:00
Max Brunsfeld
57ffa8201e Start removing the Send impl for App
Co-authored-by: Antonio <antonio@zed.dev>
Co-authored-by: Nathan <nathan@zed.dev>
2023-11-01 13:53:45 -06:00
Conrad Irwin
ea7fdef417 And more unused imports 2023-11-01 13:51:42 -06:00
Conrad Irwin
a5d37d3510 Remove two more hanging tests 2023-11-01 13:26:12 -06:00
Mikayla
6f38eb3252
Finish main merge 2023-11-01 11:52:14 -07:00
Joseph T. Lyons
51ecf8e6b4 collab 0.28.0 2023-11-01 14:50:29 -04:00
Mikayla
e82d8eb5b8
Merge branch 'main' into zed2-workspace 2023-11-01 11:46:28 -07:00
Mikayla
1c1b53ecf6
WIP 2023-11-01 11:45:31 -07:00
Mikayla
6aaeb23157
Rename live kit bridge to 2 2023-11-01 10:52:15 -07:00
Conrad Irwin
cfe0ddc61a More unused imports 2023-11-01 11:43:06 -06:00
Max Brunsfeld
c467fa955b Comment out hanging project2 tests
Co-authored-by: Conrad <conrad@zed.dev>
2023-11-01 10:38:47 -07:00
Antonio Scandurra
337a79e35f WIP 2023-11-01 18:34:51 +01:00
Marshall Bowers
b910bbf002
Add ui_font_size setting (#3199)
This PR adds a new `ui_font_size` setting that can be used to control
the scale of the entire UI.

We use the value in this setting to set the base rem size of the window.

Release Notes:

- N/A
2023-11-01 13:11:12 -04:00
Nate Butler
8dafd5f1f3 Allow ListHeader to take a meta 2023-11-01 12:43:25 -04:00
Mikayla Maki
bd61d71018
Finish port of livekit client and call2 (#3198) 2023-11-01 09:37:40 -07:00
Joseph T. Lyons
7d300d3f5b v0.112.x dev 2023-11-01 12:34:26 -04:00
Mikayla
1568ecbe1e
Add back room code to call2 2023-11-01 09:29:54 -07:00
Antonio Scandurra
c3a8bab4d2 WIP 2023-11-01 17:21:58 +01:00
Mikayla
51fa80ef06
ported example app, live_kit_client2 is done 2023-11-01 09:19:32 -07:00