Vendor the native UI kit as crates/ui
- crates/ui holds the theme, icons, components, data widgets, editor surfaces, layout, and utilities; cargo feature gates are gone. - One merged icon set of 154 SVGs where the app file wins every duplicate name, served by a single rust-embed Assets source. - IconRole grows the 25 app glyphs, so assets::CustomIconName and crates/assets are deleted. - ui::init owns the theme and key bindings that desktop used to bind in three calls. - docs/gpui-native-kit-gaps.md becomes docs/ui-gaps.md; the icon gap is closed.
This commit is contained in:
+1
-2
@@ -27,7 +27,6 @@ icons = [
|
||||
]
|
||||
|
||||
[dependencies]
|
||||
assets = { path = "../crates/assets" }
|
||||
metadata = { path = "../crates/metadata" }
|
||||
paths = { path = "../crates/paths" }
|
||||
settings = { path = "../crates/settings" }
|
||||
@@ -36,7 +35,7 @@ signed_state = { path = "../crates/signed_state" }
|
||||
|
||||
gpui.workspace = true
|
||||
gpui_platform.workspace = true
|
||||
gpui-native-kit.workspace = true
|
||||
ui = { path = "../crates/ui" }
|
||||
reqwest_client.workspace = true
|
||||
tracing.workspace = true
|
||||
tracing-subscriber.workspace = true
|
||||
|
||||
+3
-5
@@ -1,10 +1,10 @@
|
||||
use std::sync::Arc;
|
||||
|
||||
use assets::Assets;
|
||||
use gpui::*;
|
||||
use gpui_native_kit::theme::{ActiveTheme as _, Theme};
|
||||
use gpui_platform::application;
|
||||
use settings::SettingsStore;
|
||||
use ui::Assets;
|
||||
use ui::theme::{ActiveTheme as _, Theme};
|
||||
|
||||
actions!(signed, [Quit]);
|
||||
|
||||
@@ -15,9 +15,7 @@ fn main() {
|
||||
.with_assets(Assets)
|
||||
.with_http_client(Arc::new(reqwest_client::ReqwestClient::new()))
|
||||
.run(move |cx| {
|
||||
gpui_native_kit::init(cx);
|
||||
gpui_native_kit::editor::code::bind_code_view_keys(cx);
|
||||
gpui_native_kit::editor::markdown::bind_text_view_keys(cx);
|
||||
ui::init(cx);
|
||||
|
||||
cx.bind_keys([
|
||||
KeyBinding::new("cmd-q", Quit, None),
|
||||
|
||||
Reference in New Issue
Block a user