Commit Graph
13962 Commits
Author SHA1 Message Date
Marshall Bowers 9e4142a6e9 Remove theme.txt 2023-11-03 17:52:19 -04:00
Marshall Bowers 49922ece21 ui2: Reorganize components (#3228)
This PR reorganizes the components in the `ui2` crate.

The distinction between "elements" and "components" is now gone, with
all of the reusable components living under `components/`.

The components that we built while prototyping but will eventually live
in other crates currently reside in the `to_extract/` module.

Release Notes:

- N/A
2023-11-03 17:34:11 -04:00
Marshall Bowers f81e3f4dab Allow deriving Serialize and Deserialize on generated refinement (#3227)
This PR adds support for deriving `Serialize` and `Deserialize` on the
refinement type generated by `#[derive(Refineable)]`.

Release Notes:

- N/A
2023-11-03 17:21:00 -04:00
Kirill Bulatov 1e24f68814 Refresh diagnostics inside the tab (#3225)
r-a now has 2 different types of diagnostics: 
* "disk-based" ones that come from `cargo check` and related, that emit
`project::Event::DiskBasedDiagnosticsStarted` and
`DiskBasedDiagnosticsFinished`
* "flycheck" diagnostics from r-a itself, that it tries to dynamically
apply to every buffer open, that come with `DiagnosticsUpdated` event.

Latter diagnostics update frequently, on every file close and open, but
`diagnostics.rs` logic had never polled for new diagnostics after
registering the `DiagnosticsUpdated` event, so the only way we could
have newer diagnostics was to re-open the whole panel.
The PR fixes that, and also adds more debug logging to the module.
The logic of the fix looks very familiar to previous related fix:
https://github.com/zed-industries/zed/pull/3128

One notable thing after the fix: "flycheck" diagnostics stay forever if
the diagnostics panel is opened: excerpts in that panel do not allow the
buffer to get dropped (hence, closed in terms of r-a) and get the
updated, zero diagnostics.
If the diagnostics panel is opened and closed multiple times, those
errors gradually disappear.

Release Notes:

- Fixed diagnostics panel not refreshing its contents properly
2023-11-03 22:03:05 +02:00
Kirill Bulatov 1ed9260477 Fix the test 2023-11-03 21:51:12 +02:00
Kirill Bulatov 2996ff6c1b Fix a compilation error 2023-11-03 21:51:12 +02:00
Kirill Bulatov 3592b98e8f Refresh diagnostics inside the tab 2023-11-03 21:51:12 +02:00
Marshall Bowers 9e7f83068a Remove Default impl for ThemeColors` (#3226)
This PR removes the `Default` impl for `ThemeColors`.

Since we need default light and dark variants for `ThemeColors`, we
can't use a single `Default` impl.

Release Notes:

- N/A
2023-11-03 15:40:50 -04:00
Mikayla Maki 197e076487 WIP: Port channel crate to gpui2 (#3192) 2023-11-03 12:32:47 -07:00
a1e9f0f311 Fix double borrow in synchronous tests that take AppContext
Co-authored-by: Mikayla <mikayla@zed.dev>
Co-authored-by: Antonio <antonio@zed.dev>
2023-11-03 12:10:11 -07:00
Mikayla 3a4d70b212 WIP 2023-11-03 12:04:24 -07:00
Mikayla b4c926ad13 Update to latest patterns for porting work 2023-11-03 10:46:47 -07:00
Max BrunsfeldandMarshall eeaa7c7685 Add channel2 crate
Co-authored-by: Marshall <marshall@zed.dev>
2023-11-03 10:41:41 -07:00
Kyle Caverly e216233676 added workspace event for WorkspaceCreated (#3222)
added workspace2 event for WorkspaceCreated

Release Notes:

- NA
2023-11-03 11:06:11 -04:00
Antonio Scandurra dde2856685 Start on editor2 (#3223)
Opening this pull request early on, as I added a bunch of APIs to
`gpui2` and uncommented code that might be useful to others in
`workspace2`.

Release Notes:

- N/A
2023-11-03 15:37:48 +01:00
Antonio Scandurra 327a700c80 Don't depend on gpui2 in text 2023-11-03 14:53:08 +01:00
Antonio Scandurra 305c7b29a2 Merge remote-tracking branch 'origin/main' into editor2 2023-11-03 14:47:49 +01:00
Antonio Scandurra c4c9ce9be2 Remove more todos 2023-11-03 14:42:26 +01:00
Antonio Scandurra 53077fe80b Add ViewContext::window_context 2023-11-03 14:41:37 +01:00
KCaverly a378036917 added workspace event for WorkspaceCreated 2023-11-03 08:52:18 -04:00
Kirill Bulatov 51d45973f8 Uncomment more gpui2 (#3221)
Release Notes:

- N/A
2023-11-03 13:45:35 +02:00
Kirill Bulatov 574176ae6d Remove and add more todosmerge . 2023-11-03 13:22:11 +02:00
Antonio Scandurra 82306268bf WIP 2023-11-03 12:10:15 +01:00
Kirill Bulatov 5b401b32e9 Move journal2 to workspace2 2023-11-03 12:55:06 +02:00
Kirill Bulatov 24a215e4fd Uncomment persistence tests 2023-11-03 12:38:09 +02:00
Antonio Scandurra 5bf492fa8c Fix a todo in workspace 2023-11-03 11:36:39 +01:00
Antonio Scandurra 12809e819d Allow converting from a WeakView<V> to an AnyWeakView 2023-11-03 11:36:18 +01:00
Antonio Scandurra 0de4fb1925 Expose a focus handle from workspace::Item 2023-11-03 11:00:57 +01:00
Antonio Scandurra a5b53ca825 Uncomment Editor::report_editor_event 2023-11-03 10:53:55 +01:00
Antonio Scandurra 5e7251d6aa Remove some todos 2023-11-03 10:50:30 +01:00
Antonio Scandurra 34b322b1e1 Uncomment Editor::new 2023-11-03 10:38:28 +01:00
Kirill Bulatov 814ca2bf9e Detect prettier in npm workspaces correctly (#3219)
Deals with https://github.com/zed-industries/community/issues/2016

Also refactored project code to spawn less default prettiers.

Release Notes:

- Fixed prettier not working in npm workspaces
2023-11-03 11:14:45 +02:00
Antonio Scandurra 2a74c3967f Remove unused code 2023-11-03 10:11:13 +01:00
Antonio Scandurra 252bac2e2e Uncomment more editor code 2023-11-03 10:09:00 +01:00
Kirill Bulatov 6704b219bc Port changes to zed2 2023-11-03 11:02:50 +02:00
Kirill Bulatov 29a0071ff1 Properly order default prettier installations and startups 2023-11-03 11:02:50 +02:00
Kirill Bulatov bd0a4f1417 Reuse already running default prettiers 2023-11-03 11:02:50 +02:00
Kirill Bulatov ec09c85a45 Make it more clear that missing prettier is to blame 2023-11-03 11:02:50 +02:00
Kirill Bulatov ffc2668513 Restore LSP names for prettier servers 2023-11-03 11:02:50 +02:00
Kirill Bulatov 30d75dde86 Simplify 2023-11-03 11:02:50 +02:00
Kirill Bulatov 4a1059b0ba Fix the bugs 2023-11-03 11:02:50 +02:00
Kirill Bulatov f58cd0b999 Rework prettier installation and start 2023-11-03 11:02:50 +02:00
Kirill Bulatov f104a3a48a Add prettier workspace resolution test 2023-11-03 11:02:50 +02:00
Antonio Scandurra f2d987c0ee Call editor::init 2023-11-03 09:06:25 +01:00
Antonio Scandurra 595ccad409 Remove dependency from gpui from editor2 2023-11-03 09:05:58 +01:00
Nathan Sobo 0e80125a44 Get editor2 compiling with a ton of code commented out 2023-11-02 23:35:20 -06:00
Nathan Sobo b7dfb4eeb4 WIP 2023-11-02 22:56:04 -06:00
Nathan Sobo 60e79c763a WIP 2023-11-02 21:28:56 -06:00
Nathan Sobo 7c2b802283 WIP 2023-11-02 21:03:29 -06:00
Nathan Sobo 4f755afb22 Merge remote-tracking branch 'origin/main' into editor2 2023-11-02 20:47:09 -06:00