Cargo.lock π
@@ -1440,7 +1440,7 @@ dependencies = [
[[package]]
name = "collab"
-version = "0.28.0"
+version = "0.33.0"
dependencies = [
"anyhow",
"async-trait",
Antonio Scandurra created
Cargo.lock | 2
assets/icons/arrow_circle.svg | 1
assets/icons/at_sign.svg | 2
assets/icons/bell_off.svg | 0
assets/icons/bell_ring.svg | 0
assets/icons/delete.svg | 5
assets/icons/escape.svg | 1
assets/icons/magic_wand.svg | 0
assets/icons/mail_open.svg | 0
assets/icons/mic_mute.svg | 0
assets/icons/page_down.svg | 2
assets/icons/page_up.svg | 2
assets/icons/return.svg | 4
assets/icons/select_all.svg | 0
assets/icons/space.svg | 1
assets/icons/speaker_loud.svg | 0
assets/icons/speaker_off.svg | 0
assets/icons/tab.svg | 1
crates/assistant/src/assistant_panel.rs | 14 -
crates/call/src/call.rs | 9
crates/client/src/telemetry.rs | 62 +++-----
crates/collab/Cargo.toml | 2
crates/collab_ui/src/collab_panel/channel_modal.rs | 10 +
crates/collab_ui/src/collab_titlebar_item.rs | 43 ++++-
crates/diagnostics/src/items.rs | 21 ++
crates/editor/src/editor.rs | 24 +-
crates/editor/src/element.rs | 5
crates/gpui/src/elements/list.rs | 24 +-
crates/gpui/src/platform/mac/shaders.metal | 30 ++--
crates/journal/src/journal.rs | 43 ++--
crates/notifications/Cargo.toml | 2
crates/notifications/src/notification_store.rs | 0
crates/project_panel/src/project_panel.rs | 15 +
crates/theme/src/themes/andromeda.rs | 6
crates/theme/src/themes/atelier.rs | 120 ++++++++--------
crates/theme/src/themes/ayu.rs | 18 +-
crates/theme/src/themes/gruvbox.rs | 36 ++--
crates/theme/src/themes/one.rs | 12
crates/theme/src/themes/rose_pine.rs | 18 +-
crates/theme/src/themes/sandcastle.rs | 6
crates/theme/src/themes/solarized.rs | 12
crates/theme/src/themes/summercamp.rs | 6
crates/theme_importer/src/main.rs | 2
crates/theme_importer/src/zed1/converter.rs | 10
crates/theme_selector/src/theme_selector.rs | 7
crates/ui/docs/todo.md | 25 ---
crates/ui/src/components/button/button.rs | 27 ++
crates/ui/src/components/icon.rs | 84 ++++++----
crates/ui/src/components/keybinding.rs | 19 +
crates/ui/src/ui.rs | 7
crates/workspace/src/workspace.rs | 33 ++--
crates/zed/src/main.rs | 13 -
crates/zed/src/zed.rs | 36 ++--
53 files changed, 423 insertions(+), 399 deletions(-)
@@ -1440,7 +1440,7 @@ dependencies = [
[[package]]
name = "collab"
-version = "0.28.0"
+version = "0.33.0"
dependencies = [
"anyhow",
"async-trait",
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-refresh-cw"><path d="M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"/><path d="M21 3v5h-5"/><path d="M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"/><path d="M8 16H3v5"/></svg>
@@ -1 +1 @@
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-at-sign"><circle cx="12" cy="12" r="4"/><path d="M16 8v5a3 3 0 0 0 6 0v-1a10 10 0 1 0-4 8"/></svg>
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-at-sign"><circle cx="12" cy="12" r="4"/><path d="M16 8v5a3 3 0 0 0 6 0v-1a10 10 0 1 0-4 8"/></svg>
@@ -1,4 +1 @@
-<svg width="15" height="11" viewBox="0 0 15 11" fill="none" xmlns="http://www.w3.org/2000/svg">
-<path d="M0.272727 11V0.818182H9.77841L14.8395 5.90909L9.77841 11H0.272727ZM4.03125 8.89205L3.3054 8.15625L8.54545 2.92614L9.27131 3.66193L4.03125 8.89205ZM8.54545 8.89205L3.3054 3.66193L4.03125 2.92614L9.27131 8.15625L8.54545 8.89205ZM1.34659 9.90625H9.34091L13.3182 5.90909L9.34091 1.91193H1.34659V9.90625Z" fill="black"/>
-</svg>
-
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-delete"><path d="M20 5H9l-7 7 7 7h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2Z"/><line x1="18" x2="12" y1="9" y2="15"/><line x1="12" x2="18" y1="9" y2="15"/></svg>
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-up-left-from-circle"><path d="M2 8V2h6"/><path d="m2 2 10 10"/><path d="M12 2A10 10 0 1 1 2 12"/></svg>
@@ -0,0 +1,6 @@
+<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M9.19131 16V8.53964H10.6313L13.2953 14.3455C13.2553 13.8719 13.2153 13.4016 13.1753 12.9347C13.1353 12.4677 13.1153 11.9975 13.1153 11.5238V8.53964H14.3993V16H12.9593L10.2953 10.1941C10.3353 10.6678 10.3753 11.1381 10.4153 11.605C10.4553 12.0719 10.4753 12.5422 10.4753 13.0159V16H9.19131Z" fill="black"/>
@@ -0,0 +1,13 @@
+<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g clip-path="url(#clip0_1650_1657)">
@@ -1,3 +1 @@
-<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
-<path fill-rule="evenodd" clip-rule="evenodd" d="M8.375 1.63C8.375 1.28482 8.65482 1.005 9 1.005H12.375C13.8247 1.005 15 2.18025 15 3.63V7.625C15 9.07474 13.8247 10.25 12.375 10.25H3.13388L6.07194 13.1881C6.31602 13.4321 6.31602 13.8279 6.07194 14.0719C5.82786 14.316 5.43214 14.316 5.18806 14.0719L1.18306 10.0669C0.938981 9.82286 0.938981 9.42714 1.18306 9.18306L5.18306 5.18306C5.42714 4.93898 5.82286 4.93898 6.06694 5.18306C6.31102 5.42714 6.31102 5.82286 6.06694 6.06694L3.13388 9H12.375C13.1344 9 13.75 8.38439 13.75 7.625V3.63C13.75 2.87061 13.1344 2.255 12.375 2.255H9C8.65482 2.255 8.375 1.97518 8.375 1.63Z" fill="black"/>
-</svg>
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-corner-down-left"><polyline points="9 10 4 15 9 20"/><path d="M20 4v7a4 4 0 0 1-4 4H4"/></svg>
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-space"><path d="M22 17v1c0 .5-.5 1-1 1H3c-.5 0-1-.5-1-1v-1"/></svg>
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right-to-line"><path d="M17 12H3"/><path d="m11 18 6-6-6-6"/><path d="M21 5v14"/></svg>
@@ -16,7 +16,7 @@ use ai::{
use ai::prompts::repository_context::PromptCodeSnippet;
use anyhow::{anyhow, Result};
use chrono::{DateTime, Local};
-use client::{telemetry::AssistantKind, TelemetrySettings};
+use client::telemetry::AssistantKind;
use collections::{hash_map, HashMap, HashSet, VecDeque};
use editor::{
display_map::{
@@ -1125,8 +1125,6 @@ impl Render for AssistantPanel {
.child(Label::new(
"Click on the Z button in the status bar to close this panel."
))
- .border()
- .border_color(gpui::red())
} else {
let header = TabBar::new("assistant_header")
.start_child(
@@ -1159,6 +1157,7 @@ impl Render for AssistantPanel {
});
v_stack()
+ .key_context("AssistantPanel")
.size_full()
.on_action(cx.listener(|this, _: &workspace::NewFile, cx| {
this.new_conversation(cx);
@@ -3529,12 +3528,5 @@ fn report_assistant_event(
.default_open_ai_model
.clone();
- let telemetry_settings = TelemetrySettings::get_global(cx).clone();
-
- telemetry.report_assistant_event(
- telemetry_settings,
- conversation_id,
- assistant_kind,
- model.full_name(),
- )
+ telemetry.report_assistant_event(conversation_id, assistant_kind, model.full_name(), cx)
}
@@ -5,7 +5,7 @@ pub mod room;
use anyhow::{anyhow, Result};
use audio::Audio;
use call_settings::CallSettings;
-use client::{proto, Client, TelemetrySettings, TypedEnvelope, User, UserStore, ZED_ALWAYS_ACTIVE};
+use client::{proto, Client, TypedEnvelope, User, UserStore, ZED_ALWAYS_ACTIVE};
use collections::HashSet;
use futures::{channel::oneshot, future::Shared, Future, FutureExt};
use gpui::{
@@ -480,9 +480,8 @@ pub fn report_call_event_for_room(
cx: &mut AppContext,
) {
let telemetry = client.telemetry();
- let telemetry_settings = *TelemetrySettings::get_global(cx);
- telemetry.report_call_event(telemetry_settings, operation, Some(room_id), channel_id)
+ telemetry.report_call_event(operation, Some(room_id), channel_id, cx)
}
pub fn report_call_event_for_channel(
@@ -495,13 +494,11 @@ pub fn report_call_event_for_channel(
let telemetry = client.telemetry();
- let telemetry_settings = *TelemetrySettings::get_global(cx);
-
telemetry.report_call_event(
- telemetry_settings,
operation,
room.map(|r| r.read(cx).id()),
Some(channel_id),
+ cx,
)
}
@@ -177,8 +177,7 @@ impl Telemetry {
// TestAppContext ends up calling this function on shutdown and it panics when trying to find the TelemetrySettings
#[cfg(not(any(test, feature = "test-support")))]
fn shutdown_telemetry(self: &Arc<Self>, cx: &mut AppContext) -> impl Future<Output = ()> {
- let telemetry_settings = TelemetrySettings::get_global(cx).clone();
- self.report_app_event(telemetry_settings, "close", true);
+ self.report_app_event("close", true, cx);
Task::ready(())
}
@@ -227,24 +226,11 @@ impl Telemetry {
return;
};
- let telemetry_settings = if let Ok(telemetry_settings) =
- cx.update(|cx| *TelemetrySettings::get_global(cx))
- {
- telemetry_settings
- } else {
- break;
- };
-
- this.report_memory_event(
- telemetry_settings,
- process.memory(),
- process.virtual_memory(),
- );
- this.report_cpu_event(
- telemetry_settings,
- process.cpu_usage(),
- system.cpus().len() as u32,
- );
+ cx.update(|cx| {
+ this.report_memory_event(process.memory(), process.virtual_memory(), cx);
+ this.report_cpu_event(process.cpu_usage(), system.cpus().len() as u32, cx);
+ })
+ .ok();
}
})
.detach();
@@ -269,12 +255,12 @@ impl Telemetry {
pub fn report_editor_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
file_extension: Option<String>,
vim_mode: bool,
operation: &'static str,
copilot_enabled: bool,
copilot_enabled_for_language: bool,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Editor {
file_extension,
@@ -285,15 +271,15 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_copilot_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
suggestion_id: Option<String>,
suggestion_accepted: bool,
file_extension: Option<String>,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Copilot {
suggestion_id,
@@ -302,15 +288,15 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_assistant_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
conversation_id: Option<String>,
kind: AssistantKind,
model: &'static str,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Assistant {
conversation_id,
@@ -319,15 +305,15 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_call_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
operation: &'static str,
room_id: Option<u64>,
channel_id: Option<u64>,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Call {
operation,
@@ -336,14 +322,14 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_cpu_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
usage_as_percentage: f32,
core_count: u32,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Cpu {
usage_as_percentage,
@@ -351,14 +337,14 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_memory_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
memory_in_bytes: u64,
virtual_memory_in_bytes: u64,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Memory {
memory_in_bytes,
@@ -366,28 +352,28 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
pub fn report_app_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
operation: &'static str,
immediate_flush: bool,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::App {
operation,
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, immediate_flush)
+ self.report_clickhouse_event(event, immediate_flush, cx)
}
pub fn report_setting_event(
self: &Arc<Self>,
- telemetry_settings: TelemetrySettings,
setting: &'static str,
value: String,
+ cx: &AppContext,
) {
let event = ClickhouseEvent::Setting {
setting,
@@ -395,7 +381,7 @@ impl Telemetry {
milliseconds_since_first_event: self.milliseconds_since_first_event(),
};
- self.report_clickhouse_event(event, telemetry_settings, false)
+ self.report_clickhouse_event(event, false, cx)
}
fn milliseconds_since_first_event(&self) -> i64 {
@@ -415,10 +401,10 @@ impl Telemetry {
fn report_clickhouse_event(
self: &Arc<Self>,
event: ClickhouseEvent,
- telemetry_settings: TelemetrySettings,
immediate_flush: bool,
+ cx: &AppContext,
) {
- if !telemetry_settings.metrics {
+ if !TelemetrySettings::get_global(cx).metrics {
return;
}
@@ -3,7 +3,7 @@ authors = ["Nathan Sobo <nathan@zed.dev>"]
default-run = "collab"
edition = "2021"
name = "collab"
-version = "0.28.0"
+version = "0.33.0"
publish = false
[[bin]]
@@ -164,8 +164,14 @@ impl Render for ChannelModal {
.py_1()
.rounded_t(px(8.))
.bg(cx.theme().colors().element_background)
- .child(IconElement::new(Icon::Hash).size(IconSize::Medium))
- .child(Label::new(channel_name))
+ .child(
+ h_stack()
+ .w_px()
+ .flex_1()
+ .gap_1()
+ .child(IconElement::new(Icon::Hash).size(IconSize::Medium))
+ .child(Label::new(channel_name)),
+ )
.child(
h_stack()
.w_full()
@@ -110,6 +110,7 @@ impl Render for CollabTitlebarItem {
&room,
project_id,
¤t_user,
+ cx,
))
.children(
remote_participants.iter().filter_map(|collaborator| {
@@ -127,6 +128,7 @@ impl Render for CollabTitlebarItem {
&room,
project_id,
¤t_user,
+ cx,
)?;
Some(
@@ -303,22 +305,38 @@ impl CollabTitlebarItem {
// resolve if you are in a room -> render_project_owner
// render_project_owner -> resolve if you are in a room -> Option<foo>
- pub fn render_project_host(&self, cx: &mut ViewContext<Self>) -> Option<impl Element> {
+ pub fn render_project_host(&self, cx: &mut ViewContext<Self>) -> Option<impl IntoElement> {
let host = self.project.read(cx).host()?;
- let host = self.user_store.read(cx).get_cached_user(host.user_id)?;
+ let host_user = self.user_store.read(cx).get_cached_user(host.user_id)?;
let participant_index = self
.user_store
.read(cx)
.participant_indices()
- .get(&host.id)?;
+ .get(&host_user.id)?;
Some(
- div().border().border_color(gpui::red()).child(
- Button::new("project_owner_trigger", host.github_login.clone())
- .color(Color::Player(participant_index.0))
- .style(ButtonStyle::Subtle)
- .label_size(LabelSize::Small)
- .tooltip(move |cx| Tooltip::text("Toggle following", cx)),
- ),
+ Button::new("project_owner_trigger", host_user.github_login.clone())
+ .color(Color::Player(participant_index.0))
+ .style(ButtonStyle::Subtle)
+ .label_size(LabelSize::Small)
+ .tooltip(move |cx| {
+ Tooltip::text(
+ format!(
+ "{} is sharing this project. Click to follow.",
+ host_user.github_login.clone()
+ ),
+ cx,
+ )
+ })
+ .on_click({
+ let host_peer_id = host.peer_id.clone();
+ cx.listener(move |this, _, cx| {
+ this.workspace
+ .update(cx, |workspace, cx| {
+ workspace.follow(host_peer_id, cx);
+ })
+ .log_err();
+ })
+ }),
)
}
@@ -389,6 +407,7 @@ impl CollabTitlebarItem {
room: &Room,
project_id: Option<u64>,
current_user: &Arc<User>,
+ cx: &ViewContext<Self>,
) -> Option<FacePile> {
let followers = project_id.map_or(&[] as &[_], |id| room.followers_for(peer_id, id));
@@ -397,9 +416,9 @@ impl CollabTitlebarItem {
Avatar::new(user.avatar_uri.clone())
.grayscale(!is_present)
.border_color(if is_speaking {
- gpui::blue()
+ cx.theme().status().info_border
} else if is_muted {
- gpui::red()
+ cx.theme().status().error_border
} else {
Hsla::default()
}),
@@ -23,11 +23,21 @@ pub struct DiagnosticIndicator {
impl Render for DiagnosticIndicator {
fn render(&mut self, cx: &mut ViewContext<Self>) -> impl IntoElement {
let diagnostic_indicator = match (self.summary.error_count, self.summary.warning_count) {
- (0, 0) => h_stack().child(
- IconElement::new(Icon::Check)
- .size(IconSize::Small)
- .color(Color::Success),
- ),
+ (0, 0) => h_stack().map(|this| {
+ if !self.in_progress_checks.is_empty() {
+ this.child(
+ IconElement::new(Icon::ArrowCircle)
+ .size(IconSize::Small)
+ .color(Color::Muted),
+ )
+ } else {
+ this.child(
+ IconElement::new(Icon::Check)
+ .size(IconSize::Small)
+ .color(Color::Default),
+ )
+ }
+ }),
(0, warning_count) => h_stack()
.gap_1()
.child(
@@ -64,6 +74,7 @@ impl Render for DiagnosticIndicator {
Some(
Label::new("Checkingβ¦")
.size(LabelSize::Small)
+ .color(Color::Muted)
.into_any_element(),
)
} else if let Some(diagnostic) = &self.current_diagnostic {
@@ -24,7 +24,7 @@ use ::git::diff::DiffHunk;
use aho_corasick::AhoCorasick;
use anyhow::{anyhow, Context as _, Result};
use blink_manager::BlinkManager;
-use client::{Client, Collaborator, ParticipantIndex, TelemetrySettings};
+use client::{Client, Collaborator, ParticipantIndex};
use clock::ReplicaId;
use collections::{BTreeMap, Bound, HashMap, HashSet, VecDeque};
use convert_case::{Case, Casing};
@@ -99,9 +99,9 @@ use sum_tree::TreeMap;
use text::{OffsetUtf16, Rope};
use theme::{ActiveTheme, PlayerColor, StatusColors, SyntaxTheme, ThemeColors, ThemeSettings};
use ui::{
- h_stack, ButtonSize, ButtonStyle, Icon, IconButton, ListItem, ListItemSpacing, Popover, Tooltip,
+ h_stack, prelude::*, ButtonSize, ButtonStyle, Icon, IconButton, IconSize, ListItem, Popover,
+ Tooltip,
};
-use ui::{prelude::*, IconSize};
use util::{post_inc, RangeExt, ResultExt, TryFutureExt};
use workspace::{searchable::SearchEvent, ItemNavHistory, Pane, SplitDirection, ViewId, Workspace};
@@ -1259,7 +1259,6 @@ impl CompletionsMenu {
div().min_w(px(220.)).max_w(px(540.)).child(
ListItem::new(mat.candidate_id)
.inset(true)
- .spacing(ListItemSpacing::Sparse)
.selected(item_ix == selected_item)
.on_click(cx.listener(move |editor, _event, cx| {
cx.stop_propagation();
@@ -8449,6 +8448,12 @@ impl Editor {
})
}
+ pub fn has_background_highlights<T: 'static>(&self) -> bool {
+ self.background_highlights
+ .get(&TypeId::of::<T>())
+ .map_or(false, |(_, highlights)| !highlights.is_empty())
+ }
+
pub fn background_highlights_in_range(
&self,
search_range: Range<Anchor>,
@@ -8865,14 +8870,8 @@ impl Editor {
.map(|a| a.to_string());
let telemetry = project.read(cx).client().telemetry().clone();
- let telemetry_settings = *TelemetrySettings::get_global(cx);
- telemetry.report_copilot_event(
- telemetry_settings,
- suggestion_id,
- suggestion_accepted,
- file_extension,
- )
+ telemetry.report_copilot_event(suggestion_id, suggestion_accepted, file_extension, cx)
}
#[cfg(any(test, feature = "test-support"))]
@@ -8910,7 +8909,6 @@ impl Editor {
.raw_user_settings()
.get("vim_mode")
== Some(&serde_json::Value::Bool(true));
- let telemetry_settings = *TelemetrySettings::get_global(cx);
let copilot_enabled = all_language_settings(file, cx).copilot_enabled(None, None);
let copilot_enabled_for_language = self
.buffer
@@ -8920,12 +8918,12 @@ impl Editor {
let telemetry = project.read(cx).client().telemetry().clone();
telemetry.report_editor_event(
- telemetry_settings,
file_extension,
vim_mode,
operation,
copilot_enabled,
copilot_enabled_for_language,
+ cx,
)
}
@@ -8,6 +8,7 @@ use crate::{
hover_popover::{
self, hover_at, HOVER_POPOVER_GAP, MIN_POPOVER_CHARACTER_WIDTH, MIN_POPOVER_LINE_HEIGHT,
},
+ items::BufferSearchHighlights,
link_go_to_definition::{
go_to_fetched_definition, go_to_fetched_type_definition, show_link_definition,
update_go_to_definition_link, update_inlay_link_and_hover_points, GoToDefinitionTrigger,
@@ -1275,7 +1276,7 @@ impl EditorElement {
let background_ranges = self
.editor
.read(cx)
- .background_highlight_row_ranges::<crate::items::BufferSearchHighlights>(
+ .background_highlight_row_ranges::<BufferSearchHighlights>(
start_anchor..end_anchor,
&layout.position_map.snapshot,
50000,
@@ -1966,7 +1967,7 @@ impl EditorElement {
(is_singleton && scrollbar_settings.git_diff && snapshot.buffer_snapshot.has_git_diffs())
||
// Selections
- (is_singleton && scrollbar_settings.selections && !highlighted_ranges.is_empty())
+ (is_singleton && scrollbar_settings.selections && editor.has_background_highlights::<BufferSearchHighlights>())
// Scrollmanager
|| editor.scroll_manager.scrollbars_visible()
}
@@ -1,7 +1,7 @@
use crate::{
- point, px, AnyElement, AvailableSpace, BorrowAppContext, Bounds, DispatchPhase, Element,
- IntoElement, Pixels, Point, ScrollWheelEvent, Size, Style, StyleRefinement, Styled,
- WindowContext,
+ point, px, AnyElement, AvailableSpace, BorrowAppContext, BorrowWindow, Bounds, ContentMask,
+ DispatchPhase, Element, IntoElement, Pixels, Point, ScrollWheelEvent, Size, Style,
+ StyleRefinement, Styled, WindowContext,
};
use collections::VecDeque;
use refineable::Refineable as _;
@@ -317,7 +317,7 @@ impl Element for List {
fn paint(
&mut self,
- bounds: crate::Bounds<crate::Pixels>,
+ bounds: Bounds<crate::Pixels>,
_state: &mut Self::State,
cx: &mut crate::WindowContext,
) {
@@ -444,13 +444,15 @@ impl Element for List {
new_items.append(cursor.suffix(&()), &());
// Paint the visible items
- let mut item_origin = bounds.origin;
- item_origin.y -= scroll_top.offset_in_item;
- for item_element in &mut item_elements {
- let item_height = item_element.measure(available_item_space, cx).height;
- item_element.draw(item_origin, available_item_space, cx);
- item_origin.y += item_height;
- }
+ cx.with_content_mask(Some(ContentMask { bounds }), |cx| {
+ let mut item_origin = bounds.origin;
+ item_origin.y -= scroll_top.offset_in_item;
+ for item_element in &mut item_elements {
+ let item_height = item_element.measure(available_item_space, cx).height;
+ item_element.draw(item_origin, available_item_space, cx);
+ item_origin.y += item_height;
+ }
+ });
state.items = new_items;
state.last_layout_bounds = Some(bounds);
@@ -16,6 +16,7 @@ float gaussian(float x, float sigma);
float2 erf(float2 x);
float blur_along_x(float x, float y, float sigma, float corner,
float2 half_size);
+float4 over(float4 below, float4 above);
struct QuadVertexOutput {
float4 position [[position]];
@@ -108,21 +109,11 @@ fragment float4 quad_fragment(QuadFragmentInput input [[stage_in]],
color = input.background_color;
} else {
float inset_distance = distance + border_width;
-
- // Decrease border's opacity as we move inside the background.
- input.border_color.a *= 1. - saturate(0.5 - inset_distance);
-
- // Alpha-blend the border and the background.
- float output_alpha = input.border_color.a +
- input.background_color.a * (1. - input.border_color.a);
- float3 premultiplied_border_rgb =
- input.border_color.rgb * input.border_color.a;
- float3 premultiplied_background_rgb =
- input.background_color.rgb * input.background_color.a;
- float3 premultiplied_output_rgb =
- premultiplied_border_rgb +
- premultiplied_background_rgb * (1. - input.border_color.a);
- color = float4(premultiplied_output_rgb, output_alpha);
+ // Blend the border on top of the background and then linearly interpolate
+ // between the two as we slide inside the background.
+ float4 blended_border = over(input.background_color, input.border_color);
+ color = mix(blended_border, input.background_color,
+ saturate(0.5 - inset_distance));
}
return color * float4(1., 1., 1., saturate(0.5 - distance));
@@ -653,3 +644,12 @@ float4 distance_from_clip_rect(float2 unit_vertex, Bounds_ScaledPixels bounds,
position.y - clip_bounds.origin.y,
clip_bounds.origin.y + clip_bounds.size.height - position.y);
}
+
+float4 over(float4 below, float4 above) {
+ float4 result;
+ float alpha = above.a + below.a * (1.0 - above.a);
+ result.rgb =
+ (above.rgb * above.a + below.rgb * below.a * (1.0 - above.a)) / alpha;
+ result.a = alpha;
+ return result;
+}
@@ -1,6 +1,8 @@
use anyhow::Result;
use chrono::{Datelike, Local, NaiveTime, Timelike};
-use gpui::{actions, AppContext, ViewContext};
+use editor::scroll::autoscroll::Autoscroll;
+use editor::Editor;
+use gpui::{actions, AppContext, ViewContext, WindowContext};
use schemars::JsonSchema;
use serde::{Deserialize, Serialize};
use settings::Settings;
@@ -63,7 +65,7 @@ pub fn init(_: Arc<AppState>, cx: &mut AppContext) {
.detach();
}
-pub fn new_journal_entry(app_state: Arc<AppState>, cx: &mut AppContext) {
+pub fn new_journal_entry(app_state: Arc<AppState>, cx: &mut WindowContext) {
let settings = JournalSettings::get_global(cx);
let journal_dir = match journal_dir(settings.path.as_ref().unwrap()) {
Some(journal_dir) => journal_dir,
@@ -79,7 +81,7 @@ pub fn new_journal_entry(app_state: Arc<AppState>, cx: &mut AppContext) {
.join(format!("{:02}", now.month()));
let entry_path = month_dir.join(format!("{:02}.md", now.day()));
let now = now.time();
- let _entry_heading = heading_entry(now, &settings.hour_format);
+ let entry_heading = heading_entry(now, &settings.hour_format);
let create_entry = cx.background_executor().spawn(async move {
std::fs::create_dir_all(month_dir)?;
@@ -93,31 +95,30 @@ pub fn new_journal_entry(app_state: Arc<AppState>, cx: &mut AppContext) {
cx.spawn(|mut cx| async move {
let (journal_dir, entry_path) = create_entry.await?;
let (workspace, _) = cx
- .update(|cx| workspace::open_paths(&[journal_dir], &app_state, None, cx))?
+ .update(|_, cx| workspace::open_paths(&[journal_dir], &app_state, None, cx))?
.await?;
- let _opened = workspace
+ let opened = workspace
.update(&mut cx, |workspace, cx| {
workspace.open_paths(vec![entry_path], true, cx)
})?
.await;
- // todo!("editor")
- // if let Some(Some(Ok(item))) = opened.first() {
- // if let Some(editor) = item.downcast::<Editor>().map(|editor| editor.downgrade()) {
- // editor.update(&mut cx, |editor, cx| {
- // let len = editor.buffer().read(cx).len(cx);
- // editor.change_selections(Some(Autoscroll::center()), cx, |s| {
- // s.select_ranges([len..len])
- // });
- // if len > 0 {
- // editor.insert("\n\n", cx);
- // }
- // editor.insert(&entry_heading, cx);
- // editor.insert("\n\n", cx);
- // })?;
- // }
- // }
+ if let Some(Some(Ok(item))) = opened.first() {
+ if let Some(editor) = item.downcast::<Editor>().map(|editor| editor.downgrade()) {
+ editor.update(&mut cx, |editor, cx| {
+ let len = editor.buffer().read(cx).len(cx);
+ editor.change_selections(Some(Autoscroll::center()), cx, |s| {
+ s.select_ranges([len..len])
+ });
+ if len > 0 {
+ editor.insert("\n\n", cx);
+ }
+ editor.insert(&entry_heading, cx);
+ editor.insert("\n\n", cx);
+ })?;
+ }
+ }
anyhow::Ok(())
})
@@ -5,7 +5,7 @@ edition = "2021"
publish = false
[lib]
-path = "src/notification_store2.rs"
+path = "src/notification_store.rs"
doctest = false
[features]
@@ -30,7 +30,7 @@ use std::{
sync::Arc,
};
use theme::ThemeSettings;
-use ui::{prelude::*, v_stack, ContextMenu, IconElement, Label, ListItem};
+use ui::{prelude::*, v_stack, ContextMenu, IconElement, KeyBinding, Label, ListItem};
use unicase::UniCase;
use util::{maybe, ResultExt, TryFutureExt};
use workspace::{
@@ -1540,7 +1540,20 @@ impl Render for ProjectPanel {
} else {
v_stack()
.id("empty-project_panel")
+ .size_full()
+ .p_4()
.track_focus(&self.focus_handle)
+ .child(
+ Button::new("open_project", "Open a project")
+ .style(ButtonStyle::Filled)
+ .full_width()
+ .key_binding(KeyBinding::for_action(&workspace::Open, cx))
+ .on_click(cx.listener(|this, _, cx| {
+ this.workspace
+ .update(cx, |workspace, cx| workspace.open(&workspace::Open, cx))
+ .log_err();
+ })),
+ )
}
}
}
@@ -20,7 +20,7 @@ pub fn andromeda() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x2b2f39ff).into()),
- border_variant: Some(rgba(0x2b2f39ff).into()),
+ border_variant: Some(rgba(0x252931ff).into()),
border_focused: Some(rgba(0x183a34ff).into()),
border_selected: Some(rgba(0x183a34ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -59,7 +59,7 @@ pub fn andromeda() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf7f7f84c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x252931ff).into()),
scrollbar_thumb_border: Some(rgba(0x252931ff).into()),
- scrollbar_track_background: Some(rgba(0x1e2025ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x21232aff).into()),
editor_foreground: Some(rgba(0xf7f7f8ff).into()),
editor_background: Some(rgba(0x1e2025ff).into()),
@@ -122,7 +122,7 @@ pub fn andromeda() -> UserThemeFamily {
modified: Some(rgba(0xfee56dff).into()),
modified_background: Some(rgba(0x5c5015ff).into()),
modified_border: Some(rgba(0x796b26ff).into()),
- predictive: Some(rgba(0x96df72ff).into()),
+ predictive: Some(rgba(0x315f70ff).into()),
predictive_background: Some(rgba(0x194618ff).into()),
predictive_border: Some(rgba(0x306129ff).into()),
renamed: Some(rgba(0x11a793ff).into()),
@@ -21,7 +21,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x969585ff).into()),
- border_variant: Some(rgba(0x969585ff).into()),
+ border_variant: Some(rgba(0xd1d0c6ff).into()),
border_focused: Some(rgba(0xbbddc6ff).into()),
border_selected: Some(rgba(0xbbddc6ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x22221b4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xd1d0c6ff).into()),
scrollbar_thumb_border: Some(rgba(0xd1d0c6ff).into()),
- scrollbar_track_background: Some(rgba(0xf4f3ecff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xedece5ff).into()),
editor_foreground: Some(rgba(0x302f27ff).into()),
editor_background: Some(rgba(0xf4f3ecff).into()),
@@ -123,7 +123,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa59810ff).into()),
modified_background: Some(rgba(0xf0e9d1ff).into()),
modified_border: Some(rgba(0xe3d8adff).into()),
- predictive: Some(rgba(0x7d9728ff).into()),
+ predictive: Some(rgba(0x879a72ff).into()),
predictive_background: Some(rgba(0xe6e9d3ff).into()),
predictive_border: Some(rgba(0xd2d8b1ff).into()),
renamed: Some(rgba(0x38a166ff).into()),
@@ -486,7 +486,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x665f5cff).into()),
- border_variant: Some(rgba(0x665f5cff).into()),
+ border_variant: Some(rgba(0x3b3431ff).into()),
border_focused: Some(rgba(0x192e5bff).into()),
border_selected: Some(rgba(0x192e5bff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -525,7 +525,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf1efee4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x3b3431ff).into()),
scrollbar_thumb_border: Some(rgba(0x3b3431ff).into()),
- scrollbar_track_background: Some(rgba(0x1b1918ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x251f1dff).into()),
editor_foreground: Some(rgba(0xe6e2e0ff).into()),
editor_background: Some(rgba(0x1b1918ff).into()),
@@ -588,7 +588,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xc38419ff).into()),
modified_background: Some(rgba(0x371d0dff).into()),
modified_border: Some(rgba(0x4f2f12ff).into()),
- predictive: Some(rgba(0x7b9727ff).into()),
+ predictive: Some(rgba(0x8f5b71ff).into()),
predictive_background: Some(rgba(0x1d2110ff).into()),
predictive_border: Some(rgba(0x2e3516ff).into()),
renamed: Some(rgba(0x417ee6ff).into()),
@@ -951,7 +951,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x8b968eff).into()),
- border_variant: Some(rgba(0x8b968eff).into()),
+ border_variant: Some(rgba(0xc8d1cbff).into()),
border_focused: Some(rgba(0xbed4d6ff).into()),
border_selected: Some(rgba(0xbed4d6ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -990,7 +990,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x171c194c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xc8d1cbff).into()),
scrollbar_thumb_border: Some(rgba(0xc8d1cbff).into()),
- scrollbar_track_background: Some(rgba(0xecf4eeff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xe5ede7ff).into()),
editor_foreground: Some(rgba(0x232a25ff).into()),
editor_background: Some(rgba(0xecf4eeff).into()),
@@ -1053,7 +1053,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa07e3cff).into()),
modified_background: Some(rgba(0xeee4d5ff).into()),
modified_border: Some(rgba(0xdfcfb6ff).into()),
- predictive: Some(rgba(0x499963ff).into()),
+ predictive: Some(rgba(0x76958cff).into()),
predictive_background: Some(rgba(0xdaeadeff).into()),
predictive_border: Some(rgba(0xbedac5ff).into()),
renamed: Some(rgba(0x488c90ff).into()),
@@ -1416,7 +1416,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x56505eff).into()),
- border_variant: Some(rgba(0x56505eff).into()),
+ border_variant: Some(rgba(0x332f38ff).into()),
border_focused: Some(rgba(0x222953ff).into()),
border_selected: Some(rgba(0x222953ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -1455,7 +1455,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xefecf44c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x332f38ff).into()),
scrollbar_thumb_border: Some(rgba(0x332f38ff).into()),
- scrollbar_track_background: Some(rgba(0x19171cff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x201e24ff).into()),
editor_foreground: Some(rgba(0xe2dfe7ff).into()),
editor_background: Some(rgba(0x19171cff).into()),
@@ -1518,7 +1518,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa06e3bff).into()),
modified_background: Some(rgba(0x231a12ff).into()),
modified_border: Some(rgba(0x392a1aff).into()),
- predictive: Some(rgba(0x2c9292ff).into()),
+ predictive: Some(rgba(0x625887ff).into()),
predictive_background: Some(rgba(0x132020ff).into()),
predictive_border: Some(rgba(0x1a3434ff).into()),
renamed: Some(rgba(0x576ddaff).into()),
@@ -1881,7 +1881,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5d5c4cff).into()),
- border_variant: Some(rgba(0x5d5c4cff).into()),
+ border_variant: Some(rgba(0x3c3b31ff).into()),
border_focused: Some(rgba(0x1c3927ff).into()),
border_selected: Some(rgba(0x1c3927ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -1920,7 +1920,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf4f3ec4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x3c3b31ff).into()),
scrollbar_thumb_border: Some(rgba(0x3c3b31ff).into()),
- scrollbar_track_background: Some(rgba(0x22221bff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x2a2922ff).into()),
editor_foreground: Some(rgba(0xe7e6dfff).into()),
editor_background: Some(rgba(0x22221bff).into()),
@@ -1983,7 +1983,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa59810ff).into()),
modified_background: Some(rgba(0x25210dff).into()),
modified_border: Some(rgba(0x3b3612ff).into()),
- predictive: Some(rgba(0x7d9727ff).into()),
+ predictive: Some(rgba(0x5f724cff).into()),
predictive_background: Some(rgba(0x1e2110ff).into()),
predictive_border: Some(rgba(0x2f3516ff).into()),
renamed: Some(rgba(0x37a166ff).into()),
@@ -2346,7 +2346,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5c6485ff).into()),
- border_variant: Some(rgba(0x5c6485ff).into()),
+ border_variant: Some(rgba(0x363f62ff).into()),
border_focused: Some(rgba(0x203348ff).into()),
border_selected: Some(rgba(0x203348ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -2385,7 +2385,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf5f7ff4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x363f62ff).into()),
scrollbar_thumb_border: Some(rgba(0x363f62ff).into()),
- scrollbar_track_background: Some(rgba(0x202746ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x252d4fff).into()),
editor_foreground: Some(rgba(0xdfe2f1ff).into()),
editor_background: Some(rgba(0x202746ff).into()),
@@ -2448,7 +2448,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xc08b31ff).into()),
modified_background: Some(rgba(0x311e11ff).into()),
modified_border: Some(rgba(0x4b3218ff).into()),
- predictive: Some(rgba(0xac973aff).into()),
+ predictive: Some(rgba(0x58709aff).into()),
predictive_background: Some(rgba(0x252113ff).into()),
predictive_border: Some(rgba(0x3d351bff).into()),
renamed: Some(rgba(0x3e8fd0ff).into()),
@@ -2811,7 +2811,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x9a9fb6ff).into()),
- border_variant: Some(rgba(0x9a9fb6ff).into()),
+ border_variant: Some(rgba(0xccd0e1ff).into()),
border_focused: Some(rgba(0xc2d5efff).into()),
border_selected: Some(rgba(0xc2d5efff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -2850,7 +2850,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x2027464c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xccd0e1ff).into()),
scrollbar_thumb_border: Some(rgba(0xccd0e1ff).into()),
- scrollbar_track_background: Some(rgba(0xf5f7ffff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xe9ebf7ff).into()),
editor_foreground: Some(rgba(0x293256ff).into()),
editor_background: Some(rgba(0xf5f7ffff).into()),
@@ -2913,7 +2913,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xc08b31ff).into()),
modified_background: Some(rgba(0xf6e6d4ff).into()),
modified_border: Some(rgba(0xeed4b3ff).into()),
- predictive: Some(rgba(0xac973aff).into()),
+ predictive: Some(rgba(0x8599beff).into()),
predictive_background: Some(rgba(0xf1e9d6ff).into()),
predictive_border: Some(rgba(0xe4d8b7ff).into()),
renamed: Some(rgba(0x3f8fd0ff).into()),
@@ -3276,7 +3276,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x6c695cff).into()),
- border_variant: Some(rgba(0x6c695cff).into()),
+ border_variant: Some(rgba(0x3b3933ff).into()),
border_focused: Some(rgba(0x263056ff).into()),
border_selected: Some(rgba(0x263056ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -3315,7 +3315,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfefbec4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x3b3933ff).into()),
scrollbar_thumb_border: Some(rgba(0x3b3933ff).into()),
- scrollbar_track_background: Some(rgba(0x20201dff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x252521ff).into()),
editor_foreground: Some(rgba(0xe8e4cfff).into()),
editor_background: Some(rgba(0x20201dff).into()),
@@ -3378,7 +3378,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xae9515ff).into()),
modified_background: Some(rgba(0x2a200eff).into()),
modified_border: Some(rgba(0x413513ff).into()),
- predictive: Some(rgba(0x60ac3aff).into()),
+ predictive: Some(rgba(0x9c6262ff).into()),
predictive_background: Some(rgba(0x1a2413ff).into()),
predictive_border: Some(rgba(0x273c1bff).into()),
renamed: Some(rgba(0x6684e0ff).into()),
@@ -3741,7 +3741,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5c6c5cff).into()),
- border_variant: Some(rgba(0x5c6c5cff).into()),
+ border_variant: Some(rgba(0x333b33ff).into()),
border_focused: Some(rgba(0x102668ff).into()),
border_selected: Some(rgba(0x102668ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -3780,7 +3780,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf4fbf44c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x333b33ff).into()),
scrollbar_thumb_border: Some(rgba(0x333b33ff).into()),
- scrollbar_track_background: Some(rgba(0x131513ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x1d201dff).into()),
editor_foreground: Some(rgba(0xcfe8cfff).into()),
editor_background: Some(rgba(0x131513ff).into()),
@@ -3843,7 +3843,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0x98981cff).into()),
modified_background: Some(rgba(0x22210fff).into()),
modified_border: Some(rgba(0x373614ff).into()),
- predictive: Some(rgba(0x2ba32aff).into()),
+ predictive: Some(rgba(0x00788bff).into()),
predictive_background: Some(rgba(0x142310ff).into()),
predictive_border: Some(rgba(0x1b3917ff).into()),
renamed: Some(rgba(0x3e62f4ff).into()),
@@ -4206,7 +4206,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x8f8b96ff).into()),
- border_variant: Some(rgba(0x8f8b96ff).into()),
+ border_variant: Some(rgba(0xcbc8d1ff).into()),
border_focused: Some(rgba(0xc9c8f3ff).into()),
border_selected: Some(rgba(0xc9c8f3ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -4245,7 +4245,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x19171c4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xcbc8d1ff).into()),
scrollbar_thumb_border: Some(rgba(0xcbc8d1ff).into()),
- scrollbar_track_background: Some(rgba(0xefecf4ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xe8e5edff).into()),
editor_foreground: Some(rgba(0x26232aff).into()),
editor_background: Some(rgba(0xefecf4ff).into()),
@@ -4308,7 +4308,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa06e3cff).into()),
modified_background: Some(rgba(0xeee0d5ff).into()),
modified_border: Some(rgba(0xe0c9b5ff).into()),
- predictive: Some(rgba(0x2c9292ff).into()),
+ predictive: Some(rgba(0x887fafff).into()),
predictive_background: Some(rgba(0xd7e9e8ff).into()),
predictive_border: Some(rgba(0xb9d7d6ff).into()),
renamed: Some(rgba(0x586ddaff).into()),
@@ -4671,7 +4671,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x564e4eff).into()),
- border_variant: Some(rgba(0x564e4eff).into()),
+ border_variant: Some(rgba(0x352f2fff).into()),
border_focused: Some(rgba(0x2c2b45ff).into()),
border_selected: Some(rgba(0x2c2b45ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -4710,7 +4710,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf4ecec4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x352f2fff).into()),
scrollbar_thumb_border: Some(rgba(0x352f2fff).into()),
- scrollbar_track_background: Some(rgba(0x1b1818ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x231f1fff).into()),
editor_foreground: Some(rgba(0xe7dfdfff).into()),
editor_background: Some(rgba(0x1b1818ff).into()),
@@ -4773,7 +4773,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa06e3bff).into()),
modified_background: Some(rgba(0x231a12ff).into()),
modified_border: Some(rgba(0x392a1aff).into()),
- predictive: Some(rgba(0x4b8b8bff).into()),
+ predictive: Some(rgba(0x795369ff).into()),
predictive_background: Some(rgba(0x161f1fff).into()),
predictive_border: Some(rgba(0x203232ff).into()),
renamed: Some(rgba(0x7272caff).into()),
@@ -5136,7 +5136,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x675b67ff).into()),
- border_variant: Some(rgba(0x675b67ff).into()),
+ border_variant: Some(rgba(0x393239ff).into()),
border_focused: Some(rgba(0x1a2961ff).into()),
border_selected: Some(rgba(0x1a2961ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -5175,7 +5175,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf7f3f74c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x393239ff).into()),
scrollbar_thumb_border: Some(rgba(0x393239ff).into()),
- scrollbar_track_background: Some(rgba(0x1b181bff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x231e23ff).into()),
editor_foreground: Some(rgba(0xd8cad8ff).into()),
editor_background: Some(rgba(0x1b181bff).into()),
@@ -5238,7 +5238,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xbb8a36ff).into()),
modified_background: Some(rgba(0x2d1e12ff).into()),
modified_border: Some(rgba(0x463219ff).into()),
- predictive: Some(rgba(0x918b3bff).into()),
+ predictive: Some(rgba(0x765990ff).into()),
predictive_background: Some(rgba(0x211f12ff).into()),
predictive_border: Some(rgba(0x34321bff).into()),
renamed: Some(rgba(0x526aebff).into()),
@@ -5601,7 +5601,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x4f6b78ff).into()),
- border_variant: Some(rgba(0x4f6b78ff).into()),
+ border_variant: Some(rgba(0x2c3b42ff).into()),
border_focused: Some(rgba(0x1a2f3cff).into()),
border_selected: Some(rgba(0x1a2f3cff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -5640,7 +5640,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xebf8ff4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x2c3b42ff).into()),
scrollbar_thumb_border: Some(rgba(0x2c3b42ff).into()),
- scrollbar_track_background: Some(rgba(0x161b1dff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x1b2327ff).into()),
editor_foreground: Some(rgba(0xc1e4f6ff).into()),
editor_background: Some(rgba(0x161b1dff).into()),
@@ -5703,7 +5703,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0x8a8a11ff).into()),
modified_background: Some(rgba(0x201f0cff).into()),
modified_border: Some(rgba(0x333211ff).into()),
- predictive: Some(rgba(0x568c3bff).into()),
+ predictive: Some(rgba(0x427088ff).into()),
predictive_background: Some(rgba(0x171f12ff).into()),
predictive_border: Some(rgba(0x23321bff).into()),
renamed: Some(rgba(0x277fadff).into()),
@@ -6066,7 +6066,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xaaa3a1ff).into()),
- border_variant: Some(rgba(0xaaa3a1ff).into()),
+ border_variant: Some(rgba(0xd6d1cfff).into()),
border_focused: Some(rgba(0xc6cef7ff).into()),
border_selected: Some(rgba(0xc6cef7ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -6105,7 +6105,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x1b19184c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xd6d1cfff).into()),
scrollbar_thumb_border: Some(rgba(0xd6d1cfff).into()),
- scrollbar_track_background: Some(rgba(0xf1efeeff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xebe8e6ff).into()),
editor_foreground: Some(rgba(0x2c2421ff).into()),
editor_background: Some(rgba(0xf1efeeff).into()),
@@ -6168,7 +6168,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xc3841aff).into()),
modified_background: Some(rgba(0xf8e5d1ff).into()),
modified_border: Some(rgba(0xf0d1adff).into()),
- predictive: Some(rgba(0x7b9728ff).into()),
+ predictive: Some(rgba(0xbe899eff).into()),
predictive_background: Some(rgba(0xe5e9d3ff).into()),
predictive_border: Some(rgba(0xd1d8b1ff).into()),
renamed: Some(rgba(0x417ee6ff).into()),
@@ -6531,7 +6531,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xa8a48eff).into()),
- border_variant: Some(rgba(0xa8a48eff).into()),
+ border_variant: Some(rgba(0xd7d3beff).into()),
border_focused: Some(rgba(0xcdd1f5ff).into()),
border_selected: Some(rgba(0xcdd1f5ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -6570,7 +6570,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x20201d4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xd7d3beff).into()),
scrollbar_thumb_border: Some(rgba(0xd7d3beff).into()),
- scrollbar_track_background: Some(rgba(0xfefbecff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xf2eedcff).into()),
editor_foreground: Some(rgba(0x292824ff).into()),
editor_background: Some(rgba(0xfefbecff).into()),
@@ -6633,7 +6633,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xae9515ff).into()),
modified_background: Some(rgba(0xf2e8d1ff).into()),
modified_border: Some(rgba(0xe7d7aeff).into()),
- predictive: Some(rgba(0x61ac3aff).into()),
+ predictive: Some(rgba(0xc88a8aff).into()),
predictive_background: Some(rgba(0xe0eed6ff).into()),
predictive_border: Some(rgba(0xc9e1b7ff).into()),
renamed: Some(rgba(0x6784e0ff).into()),
@@ -6996,7 +6996,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x8e8989ff).into()),
- border_variant: Some(rgba(0x8e8989ff).into()),
+ border_variant: Some(rgba(0xcfc7c7ff).into()),
border_focused: Some(rgba(0xcecaecff).into()),
border_selected: Some(rgba(0xcecaecff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -7035,7 +7035,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x1b18184c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xcfc7c7ff).into()),
scrollbar_thumb_border: Some(rgba(0xcfc7c7ff).into()),
- scrollbar_track_background: Some(rgba(0xf4ececff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xede5e5ff).into()),
editor_foreground: Some(rgba(0x292424ff).into()),
editor_background: Some(rgba(0xf4ececff).into()),
@@ -7098,7 +7098,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa06e3cff).into()),
modified_background: Some(rgba(0xeee0d5ff).into()),
modified_border: Some(rgba(0xe0c9b5ff).into()),
- predictive: Some(rgba(0x4c8b8bff).into()),
+ predictive: Some(rgba(0xa27a91ff).into()),
predictive_background: Some(rgba(0xdae7e7ff).into()),
predictive_border: Some(rgba(0xbfd4d4ff).into()),
renamed: Some(rgba(0x7372caff).into()),
@@ -7461,7 +7461,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x8ea88eff).into()),
- border_variant: Some(rgba(0x8ea88eff).into()),
+ border_variant: Some(rgba(0xbed7beff).into()),
border_focused: Some(rgba(0xc9c4fdff).into()),
border_selected: Some(rgba(0xc9c4fdff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -7500,7 +7500,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x1315134c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xbed7beff).into()),
scrollbar_thumb_border: Some(rgba(0xbed7beff).into()),
- scrollbar_track_background: Some(rgba(0xf4fbf4ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xdff0dfff).into()),
editor_foreground: Some(rgba(0x242924ff).into()),
editor_background: Some(rgba(0xf4fbf4ff).into()),
@@ -7563,7 +7563,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0x98981dff).into()),
modified_background: Some(rgba(0xede9d2ff).into()),
modified_border: Some(rgba(0xddd8afff).into()),
- predictive: Some(rgba(0x2ba32bff).into()),
+ predictive: Some(rgba(0x00a2b5ff).into()),
predictive_background: Some(rgba(0xd9edd4ff).into()),
predictive_border: Some(rgba(0xbbdeb2ff).into()),
renamed: Some(rgba(0x3f62f4ff).into()),
@@ -7926,7 +7926,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x505e55ff).into()),
- border_variant: Some(rgba(0x505e55ff).into()),
+ border_variant: Some(rgba(0x2f3832ff).into()),
border_focused: Some(rgba(0x1f3233ff).into()),
border_selected: Some(rgba(0x1f3233ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -7965,7 +7965,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xecf4ee4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x2f3832ff).into()),
scrollbar_thumb_border: Some(rgba(0x2f3832ff).into()),
- scrollbar_track_background: Some(rgba(0x171c19ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x1e2420ff).into()),
editor_foreground: Some(rgba(0xdfe7e2ff).into()),
editor_background: Some(rgba(0x171c19ff).into()),
@@ -8028,7 +8028,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xa07e3bff).into()),
modified_background: Some(rgba(0x231d12ff).into()),
modified_border: Some(rgba(0x392e1aff).into()),
- predictive: Some(rgba(0x489963ff).into()),
+ predictive: Some(rgba(0x506d66ff).into()),
predictive_background: Some(rgba(0x162119ff).into()),
predictive_border: Some(rgba(0x203626ff).into()),
renamed: Some(rgba(0x478c90ff).into()),
@@ -8391,7 +8391,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xad9dadff).into()),
- border_variant: Some(rgba(0xad9dadff).into()),
+ border_variant: Some(rgba(0xcdbecdff).into()),
border_focused: Some(rgba(0xcac7faff).into()),
border_selected: Some(rgba(0xcac7faff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -8430,7 +8430,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x1b181b4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xcdbecdff).into()),
scrollbar_thumb_border: Some(rgba(0xcdbecdff).into()),
- scrollbar_track_background: Some(rgba(0xf7f3f7ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xe5dce5ff).into()),
editor_foreground: Some(rgba(0x292329ff).into()),
editor_background: Some(rgba(0xf7f3f7ff).into()),
@@ -8493,7 +8493,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0xbb8a36ff).into()),
modified_background: Some(rgba(0xf5e6d5ff).into()),
modified_border: Some(rgba(0xebd3b5ff).into()),
- predictive: Some(rgba(0x918b3cff).into()),
+ predictive: Some(rgba(0xa587bfff).into()),
predictive_background: Some(rgba(0xeae6d6ff).into()),
predictive_border: Some(rgba(0xd9d4b6ff).into()),
renamed: Some(rgba(0x526aebff).into()),
@@ -8856,7 +8856,7 @@ pub fn atelier() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x80a4b6ff).into()),
- border_variant: Some(rgba(0x80a4b6ff).into()),
+ border_variant: Some(rgba(0xb0d3e5ff).into()),
border_focused: Some(rgba(0xbacfe1ff).into()),
border_selected: Some(rgba(0xbacfe1ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -8895,7 +8895,7 @@ pub fn atelier() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x161b1d4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xb0d3e5ff).into()),
scrollbar_thumb_border: Some(rgba(0xb0d3e5ff).into()),
- scrollbar_track_background: Some(rgba(0xebf8ffff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xd3edfaff).into()),
editor_foreground: Some(rgba(0x1f292eff).into()),
editor_background: Some(rgba(0xebf8ffff).into()),
@@ -8958,7 +8958,7 @@ pub fn atelier() -> UserThemeFamily {
modified: Some(rgba(0x8a8a11ff).into()),
modified_background: Some(rgba(0xeae6d0ff).into()),
modified_border: Some(rgba(0xd8d3abff).into()),
- predictive: Some(rgba(0x578c3cff).into()),
+ predictive: Some(rgba(0x6a97b2ff).into()),
predictive_background: Some(rgba(0xdde7d5ff).into()),
predictive_border: Some(rgba(0xc2d5b6ff).into()),
renamed: Some(rgba(0x277fadff).into()),
@@ -21,7 +21,7 @@ pub fn ayu() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x3f4043ff).into()),
- border_variant: Some(rgba(0x3f4043ff).into()),
+ border_variant: Some(rgba(0x2d2f34ff).into()),
border_focused: Some(rgba(0x1b4a6eff).into()),
border_selected: Some(rgba(0x1b4a6eff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn ayu() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xbfbdb64c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x2d2f34ff).into()),
scrollbar_thumb_border: Some(rgba(0x2d2f34ff).into()),
- scrollbar_track_background: Some(rgba(0x0d1017ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x1b1e24ff).into()),
editor_foreground: Some(rgba(0xbfbdb6ff).into()),
editor_background: Some(rgba(0x0d1017ff).into()),
@@ -123,7 +123,7 @@ pub fn ayu() -> UserThemeFamily {
modified: Some(rgba(0xfeb454ff).into()),
modified_background: Some(rgba(0x572916ff).into()),
modified_border: Some(rgba(0x754221ff).into()),
- predictive: Some(rgba(0xaad84cff).into()),
+ predictive: Some(rgba(0x5b728cff).into()),
predictive_background: Some(rgba(0x294113ff).into()),
predictive_border: Some(rgba(0x405c1dff).into()),
renamed: Some(rgba(0x5ac2feff).into()),
@@ -465,7 +465,7 @@ pub fn ayu() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xcfd1d2ff).into()),
- border_variant: Some(rgba(0xcfd1d2ff).into()),
+ border_variant: Some(rgba(0xdfe0e1ff).into()),
border_focused: Some(rgba(0xc4daf6ff).into()),
border_selected: Some(rgba(0xc4daf6ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -504,7 +504,7 @@ pub fn ayu() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x5c61664c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xdfe0e1ff).into()),
scrollbar_thumb_border: Some(rgba(0xdfe0e1ff).into()),
- scrollbar_track_background: Some(rgba(0xfcfcfcff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xefeff0ff).into()),
editor_foreground: Some(rgba(0x5c6166ff).into()),
editor_background: Some(rgba(0xfcfcfcff).into()),
@@ -567,7 +567,7 @@ pub fn ayu() -> UserThemeFamily {
modified: Some(rgba(0xf1ae4aff).into()),
modified_background: Some(rgba(0xffeedaff).into()),
modified_border: Some(rgba(0xffe1beff).into()),
- predictive: Some(rgba(0x86b305ff).into()),
+ predictive: Some(rgba(0x9eb9d3ff).into()),
predictive_background: Some(rgba(0xe9efd2ff).into()),
predictive_border: Some(rgba(0xd7e3aeff).into()),
renamed: Some(rgba(0x3b9ee5ff).into()),
@@ -909,7 +909,7 @@ pub fn ayu() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x53565dff).into()),
- border_variant: Some(rgba(0x53565dff).into()),
+ border_variant: Some(rgba(0x43464fff).into()),
border_focused: Some(rgba(0x24556fff).into()),
border_selected: Some(rgba(0x24556fff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -948,7 +948,7 @@ pub fn ayu() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xcccac24c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x43464fff).into()),
scrollbar_thumb_border: Some(rgba(0x43464fff).into()),
- scrollbar_track_background: Some(rgba(0x242936ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x323641ff).into()),
editor_foreground: Some(rgba(0xcccac2ff).into()),
editor_background: Some(rgba(0x242936ff).into()),
@@ -1011,7 +1011,7 @@ pub fn ayu() -> UserThemeFamily {
modified: Some(rgba(0xfed073ff).into()),
modified_background: Some(rgba(0x584018ff).into()),
modified_border: Some(rgba(0x765a29ff).into()),
- predictive: Some(rgba(0xd5fe80ff).into()),
+ predictive: Some(rgba(0x6d839bff).into()),
predictive_background: Some(rgba(0x426118ff).into()),
predictive_border: Some(rgba(0x5d7e2cff).into()),
renamed: Some(rgba(0x73cffeff).into()),
@@ -21,7 +21,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xc9b99aff).into()),
- border_variant: Some(rgba(0xc9b99aff).into()),
+ border_variant: Some(rgba(0xddcca7ff).into()),
border_focused: Some(rgba(0xaec6cdff).into()),
border_selected: Some(rgba(0xaec6cdff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x2828284c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xddcca7ff).into()),
scrollbar_thumb_border: Some(rgba(0xddcca7ff).into()),
- scrollbar_track_background: Some(rgba(0xf9f5d7ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xefe2bcff).into()),
editor_foreground: Some(rgba(0x282828ff).into()),
editor_background: Some(rgba(0xf9f5d7ff).into()),
@@ -123,7 +123,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xb57616ff).into()),
modified_background: Some(rgba(0xf5e2d0ff).into()),
modified_border: Some(rgba(0xebccabff).into()),
- predictive: Some(rgba(0x797410ff).into()),
+ predictive: Some(rgba(0x7d9881ff).into()),
predictive_background: Some(rgba(0xe5e1ceff).into()),
predictive_border: Some(rgba(0xd1cba8ff).into()),
renamed: Some(rgba(0x0b6678ff).into()),
@@ -472,7 +472,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5b534dff).into()),
- border_variant: Some(rgba(0x5b534dff).into()),
+ border_variant: Some(rgba(0x494340ff).into()),
border_focused: Some(rgba(0x303a36ff).into()),
border_selected: Some(rgba(0x303a36ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -511,7 +511,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfbf1c74c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x494340ff).into()),
scrollbar_thumb_border: Some(rgba(0x494340ff).into()),
- scrollbar_track_background: Some(rgba(0x32302fff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x393634ff).into()),
editor_foreground: Some(rgba(0xebdbb2ff).into()),
editor_background: Some(rgba(0x32302fff).into()),
@@ -574,7 +574,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xf9bd30ff).into()),
modified_background: Some(rgba(0x582f10ff).into()),
modified_border: Some(rgba(0x754916ff).into()),
- predictive: Some(rgba(0xb8bb27ff).into()),
+ predictive: Some(rgba(0x717363ff).into()),
predictive_background: Some(rgba(0x332b11ff).into()),
predictive_border: Some(rgba(0x4a4516ff).into()),
renamed: Some(rgba(0x83a598ff).into()),
@@ -923,7 +923,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xc9b99aff).into()),
- border_variant: Some(rgba(0xc9b99aff).into()),
+ border_variant: Some(rgba(0xddcca7ff).into()),
border_focused: Some(rgba(0xaec6cdff).into()),
border_selected: Some(rgba(0xaec6cdff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -962,7 +962,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x2828284c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xddcca7ff).into()),
scrollbar_thumb_border: Some(rgba(0xddcca7ff).into()),
- scrollbar_track_background: Some(rgba(0xfbf1c7ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xefe1b8ff).into()),
editor_foreground: Some(rgba(0x282828ff).into()),
editor_background: Some(rgba(0xfbf1c7ff).into()),
@@ -1025,7 +1025,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xb57616ff).into()),
modified_background: Some(rgba(0xf5e2d0ff).into()),
modified_border: Some(rgba(0xebccabff).into()),
- predictive: Some(rgba(0x797410ff).into()),
+ predictive: Some(rgba(0x7d9881ff).into()),
predictive_background: Some(rgba(0xe5e1ceff).into()),
predictive_border: Some(rgba(0xd1cba8ff).into()),
renamed: Some(rgba(0x0b6678ff).into()),
@@ -1374,7 +1374,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5b534dff).into()),
- border_variant: Some(rgba(0x5b534dff).into()),
+ border_variant: Some(rgba(0x494340ff).into()),
border_focused: Some(rgba(0x303a36ff).into()),
border_selected: Some(rgba(0x303a36ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -1413,7 +1413,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfbf1c74c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x494340ff).into()),
scrollbar_thumb_border: Some(rgba(0x494340ff).into()),
- scrollbar_track_background: Some(rgba(0x282828ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x373432ff).into()),
editor_foreground: Some(rgba(0xebdbb2ff).into()),
editor_background: Some(rgba(0x282828ff).into()),
@@ -1476,7 +1476,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xf9bd30ff).into()),
modified_background: Some(rgba(0x582f10ff).into()),
modified_border: Some(rgba(0x754916ff).into()),
- predictive: Some(rgba(0xb8bb27ff).into()),
+ predictive: Some(rgba(0x717363ff).into()),
predictive_background: Some(rgba(0x332b11ff).into()),
predictive_border: Some(rgba(0x4a4516ff).into()),
renamed: Some(rgba(0x83a598ff).into()),
@@ -1825,7 +1825,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xc9b99aff).into()),
- border_variant: Some(rgba(0xc9b99aff).into()),
+ border_variant: Some(rgba(0xddcca7ff).into()),
border_focused: Some(rgba(0xaec6cdff).into()),
border_selected: Some(rgba(0xaec6cdff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -1864,7 +1864,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x2828284c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xddcca7ff).into()),
scrollbar_thumb_border: Some(rgba(0xddcca7ff).into()),
- scrollbar_track_background: Some(rgba(0xf2e5bcff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xeddeb5ff).into()),
editor_foreground: Some(rgba(0x282828ff).into()),
editor_background: Some(rgba(0xf2e5bcff).into()),
@@ -1927,7 +1927,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xb57616ff).into()),
modified_background: Some(rgba(0xf5e2d0ff).into()),
modified_border: Some(rgba(0xebccabff).into()),
- predictive: Some(rgba(0x797410ff).into()),
+ predictive: Some(rgba(0x7d9881ff).into()),
predictive_background: Some(rgba(0xe5e1ceff).into()),
predictive_border: Some(rgba(0xd1cba8ff).into()),
renamed: Some(rgba(0x0b6678ff).into()),
@@ -2276,7 +2276,7 @@ pub fn gruvbox() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x5b534dff).into()),
- border_variant: Some(rgba(0x5b534dff).into()),
+ border_variant: Some(rgba(0x494340ff).into()),
border_focused: Some(rgba(0x303a36ff).into()),
border_selected: Some(rgba(0x303a36ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -2315,7 +2315,7 @@ pub fn gruvbox() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfbf1c74c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x494340ff).into()),
scrollbar_thumb_border: Some(rgba(0x494340ff).into()),
- scrollbar_track_background: Some(rgba(0x1d2021ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x343130ff).into()),
editor_foreground: Some(rgba(0xebdbb2ff).into()),
editor_background: Some(rgba(0x1d2021ff).into()),
@@ -2378,7 +2378,7 @@ pub fn gruvbox() -> UserThemeFamily {
modified: Some(rgba(0xf9bd30ff).into()),
modified_background: Some(rgba(0x582f10ff).into()),
modified_border: Some(rgba(0x754916ff).into()),
- predictive: Some(rgba(0xb8bb27ff).into()),
+ predictive: Some(rgba(0x717363ff).into()),
predictive_background: Some(rgba(0x332b11ff).into()),
predictive_border: Some(rgba(0x4a4516ff).into()),
renamed: Some(rgba(0x83a598ff).into()),
@@ -21,7 +21,7 @@ pub fn one() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xc9c9caff).into()),
- border_variant: Some(rgba(0xc9c9caff).into()),
+ border_variant: Some(rgba(0xdfdfe0ff).into()),
border_focused: Some(rgba(0xcbcdf6ff).into()),
border_selected: Some(rgba(0xcbcdf6ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn one() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x383a414c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xdfdfe0ff).into()),
scrollbar_thumb_border: Some(rgba(0xdfdfe0ff).into()),
- scrollbar_track_background: Some(rgba(0xfafafaff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xeeeeeeff).into()),
editor_foreground: Some(rgba(0x383a41ff).into()),
editor_background: Some(rgba(0xfafafaff).into()),
@@ -123,7 +123,7 @@ pub fn one() -> UserThemeFamily {
modified: Some(rgba(0xdec184ff).into()),
modified_background: Some(rgba(0xfaf2e6ff).into()),
modified_border: Some(rgba(0xf5e8d2ff).into()),
- predictive: Some(rgba(0x669f59ff).into()),
+ predictive: Some(rgba(0x9c9fc7ff).into()),
predictive_background: Some(rgba(0xe0ebdcff).into()),
predictive_border: Some(rgba(0xc8dcc1ff).into()),
renamed: Some(rgba(0x5c79e2ff).into()),
@@ -472,7 +472,7 @@ pub fn one() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x464b57ff).into()),
- border_variant: Some(rgba(0x464b57ff).into()),
+ border_variant: Some(rgba(0x363c46ff).into()),
border_focused: Some(rgba(0x293c5bff).into()),
border_selected: Some(rgba(0x293c5bff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -511,7 +511,7 @@ pub fn one() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xc8ccd44c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x363c46ff).into()),
scrollbar_thumb_border: Some(rgba(0x363c46ff).into()),
- scrollbar_track_background: Some(rgba(0x282c34ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x2e333cff).into()),
editor_foreground: Some(rgba(0xacb2beff).into()),
editor_background: Some(rgba(0x282c34ff).into()),
@@ -574,7 +574,7 @@ pub fn one() -> UserThemeFamily {
modified: Some(rgba(0xdec184ff).into()),
modified_background: Some(rgba(0x41331dff).into()),
modified_border: Some(rgba(0x5d4c2fff).into()),
- predictive: Some(rgba(0xa1c181ff).into()),
+ predictive: Some(rgba(0x5b6b88ff).into()),
predictive_background: Some(rgba(0x222e1dff).into()),
predictive_border: Some(rgba(0x38482fff).into()),
renamed: Some(rgba(0x74ade8ff).into()),
@@ -21,7 +21,7 @@ pub fn rose_pine() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0xdcd6d5ff).into()),
- border_variant: Some(rgba(0xdcd6d5ff).into()),
+ border_variant: Some(rgba(0xe5e0dfff).into()),
border_focused: Some(rgba(0xc3d7dbff).into()),
border_selected: Some(rgba(0xc3d7dbff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn rose_pine() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x5752794c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xe5e0dfff).into()),
scrollbar_thumb_border: Some(rgba(0xe5e0dfff).into()),
- scrollbar_track_background: Some(rgba(0xfaf4edff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xfdf8f1ff).into()),
editor_foreground: Some(rgba(0x575279ff).into()),
editor_background: Some(rgba(0xfaf4edff).into()),
@@ -123,7 +123,7 @@ pub fn rose_pine() -> UserThemeFamily {
modified: Some(rgba(0xe99d35ff).into()),
modified_background: Some(rgba(0xffebd6ff).into()),
modified_border: Some(rgba(0xffdab7ff).into()),
- predictive: Some(rgba(0x3eaa8eff).into()),
+ predictive: Some(rgba(0xa2acbeff).into()),
predictive_background: Some(rgba(0xdbeee7ff).into()),
predictive_border: Some(rgba(0xbee0d5ff).into()),
renamed: Some(rgba(0x57949fff).into()),
@@ -479,7 +479,7 @@ pub fn rose_pine() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x504c68ff).into()),
- border_variant: Some(rgba(0x504c68ff).into()),
+ border_variant: Some(rgba(0x322f48ff).into()),
border_focused: Some(rgba(0x435255ff).into()),
border_selected: Some(rgba(0x435255ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -518,7 +518,7 @@ pub fn rose_pine() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xe0def44c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x322f48ff).into()),
scrollbar_thumb_border: Some(rgba(0x322f48ff).into()),
- scrollbar_track_background: Some(rgba(0x232136ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x27243bff).into()),
editor_foreground: Some(rgba(0xe0def4ff).into()),
editor_background: Some(rgba(0x232136ff).into()),
@@ -581,7 +581,7 @@ pub fn rose_pine() -> UserThemeFamily {
modified: Some(rgba(0xf5c177ff).into()),
modified_background: Some(rgba(0x50341aff).into()),
modified_border: Some(rgba(0x6d4d2bff).into()),
- predictive: Some(rgba(0x5dc2a3ff).into()),
+ predictive: Some(rgba(0x516b83ff).into()),
predictive_background: Some(rgba(0x182e23ff).into()),
predictive_border: Some(rgba(0x254839ff).into()),
renamed: Some(rgba(0x9cced7ff).into()),
@@ -937,7 +937,7 @@ pub fn rose_pine() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x423f55ff).into()),
- border_variant: Some(rgba(0x423f55ff).into()),
+ border_variant: Some(rgba(0x232132ff).into()),
border_focused: Some(rgba(0x435255ff).into()),
border_selected: Some(rgba(0x435255ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -976,7 +976,7 @@ pub fn rose_pine() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xe0def44c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x232132ff).into()),
scrollbar_thumb_border: Some(rgba(0x232132ff).into()),
- scrollbar_track_background: Some(rgba(0x191724ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x1c1a29ff).into()),
editor_foreground: Some(rgba(0xe0def4ff).into()),
editor_background: Some(rgba(0x191724ff).into()),
@@ -1039,7 +1039,7 @@ pub fn rose_pine() -> UserThemeFamily {
modified: Some(rgba(0xf5c177ff).into()),
modified_background: Some(rgba(0x50341aff).into()),
modified_border: Some(rgba(0x6d4d2bff).into()),
- predictive: Some(rgba(0x5dc2a3ff).into()),
+ predictive: Some(rgba(0x556b81ff).into()),
predictive_background: Some(rgba(0x182e23ff).into()),
predictive_border: Some(rgba(0x254839ff).into()),
renamed: Some(rgba(0x9cced7ff).into()),
@@ -20,7 +20,7 @@ pub fn sandcastle() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x3d4350ff).into()),
- border_variant: Some(rgba(0x3d4350ff).into()),
+ border_variant: Some(rgba(0x313741ff).into()),
border_focused: Some(rgba(0x223232ff).into()),
border_selected: Some(rgba(0x223232ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -59,7 +59,7 @@ pub fn sandcastle() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfdf4c14c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x313741ff).into()),
scrollbar_thumb_border: Some(rgba(0x313741ff).into()),
- scrollbar_track_background: Some(rgba(0x282c34ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x2a2f38ff).into()),
editor_foreground: Some(rgba(0xfdf4c1ff).into()),
editor_background: Some(rgba(0x282c34ff).into()),
@@ -122,7 +122,7 @@ pub fn sandcastle() -> UserThemeFamily {
modified: Some(rgba(0xa07e3bff).into()),
modified_background: Some(rgba(0x231d12ff).into()),
modified_border: Some(rgba(0x392e1aff).into()),
- predictive: Some(rgba(0x83a598ff).into()),
+ predictive: Some(rgba(0x5c6152ff).into()),
predictive_background: Some(rgba(0x1e2321ff).into()),
predictive_border: Some(rgba(0x303a36ff).into()),
renamed: Some(rgba(0x528b8bff).into()),
@@ -21,7 +21,7 @@ pub fn solarized() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x9faaa8ff).into()),
- border_variant: Some(rgba(0x9faaa8ff).into()),
+ border_variant: Some(rgba(0xdcdacbff).into()),
border_focused: Some(rgba(0xbfd3efff).into()),
border_selected: Some(rgba(0xbfd3efff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -60,7 +60,7 @@ pub fn solarized() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0x002b364c).into()),
scrollbar_thumb_hover_background: Some(rgba(0xdcdacbff).into()),
scrollbar_thumb_border: Some(rgba(0xdcdacbff).into()),
- scrollbar_track_background: Some(rgba(0xfdf6e3ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0xf5eedbff).into()),
editor_foreground: Some(rgba(0x002b36ff).into()),
editor_background: Some(rgba(0xfdf6e3ff).into()),
@@ -123,7 +123,7 @@ pub fn solarized() -> UserThemeFamily {
modified: Some(rgba(0xb58904ff).into()),
modified_background: Some(rgba(0xf5e6d0ff).into()),
modified_border: Some(rgba(0xebd3aaff).into()),
- predictive: Some(rgba(0x859904ff).into()),
+ predictive: Some(rgba(0x679aafff).into()),
predictive_background: Some(rgba(0xe9ead0ff).into()),
predictive_border: Some(rgba(0xd6d9abff).into()),
renamed: Some(rgba(0x298bd1ff).into()),
@@ -465,7 +465,7 @@ pub fn solarized() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x2b4f58ff).into()),
- border_variant: Some(rgba(0x2b4f58ff).into()),
+ border_variant: Some(rgba(0x063541ff).into()),
border_focused: Some(rgba(0x1c3249ff).into()),
border_selected: Some(rgba(0x1c3249ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -504,7 +504,7 @@ pub fn solarized() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xfdf6e34c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x063541ff).into()),
scrollbar_thumb_border: Some(rgba(0x063541ff).into()),
- scrollbar_track_background: Some(rgba(0x002b36ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x032f3bff).into()),
editor_foreground: Some(rgba(0xfdf6e3ff).into()),
editor_background: Some(rgba(0x002b36ff).into()),
@@ -567,7 +567,7 @@ pub fn solarized() -> UserThemeFamily {
modified: Some(rgba(0xb58903ff).into()),
modified_background: Some(rgba(0x2f1e0cff).into()),
modified_border: Some(rgba(0x473110ff).into()),
- predictive: Some(rgba(0x859904ff).into()),
+ predictive: Some(rgba(0x40728bff).into()),
predictive_background: Some(rgba(0x1f210cff).into()),
predictive_border: Some(rgba(0x323610ff).into()),
renamed: Some(rgba(0x288bd1ff).into()),
@@ -20,7 +20,7 @@ pub fn summercamp() -> UserThemeFamily {
styles: UserThemeStylesRefinement {
colors: ThemeColorsRefinement {
border: Some(rgba(0x312d21ff).into()),
- border_variant: Some(rgba(0x312d21ff).into()),
+ border_variant: Some(rgba(0x29251bff).into()),
border_focused: Some(rgba(0x193761ff).into()),
border_selected: Some(rgba(0x193761ff).into()),
border_transparent: Some(rgba(0x00000000).into()),
@@ -59,7 +59,7 @@ pub fn summercamp() -> UserThemeFamily {
scrollbar_thumb_background: Some(rgba(0xf8f5de4c).into()),
scrollbar_thumb_hover_background: Some(rgba(0x29251bff).into()),
scrollbar_thumb_border: Some(rgba(0x29251bff).into()),
- scrollbar_track_background: Some(rgba(0x1c1810ff).into()),
+ scrollbar_track_background: Some(rgba(0x00000000).into()),
scrollbar_track_border: Some(rgba(0x221e15ff).into()),
editor_foreground: Some(rgba(0xf8f5deff).into()),
editor_background: Some(rgba(0x1c1810ff).into()),
@@ -122,7 +122,7 @@ pub fn summercamp() -> UserThemeFamily {
modified: Some(rgba(0xf1fe29ff).into()),
modified_background: Some(rgba(0x556305ff).into()),
modified_border: Some(rgba(0x727f0aff).into()),
- predictive: Some(rgba(0x5dea5aff).into()),
+ predictive: Some(rgba(0x79434bff).into()),
predictive_background: Some(rgba(0x0a4d13ff).into()),
predictive_border: Some(rgba(0x1a6a20ff).into()),
renamed: Some(rgba(0x499befff).into()),
@@ -103,8 +103,6 @@ fn main() -> Result<()> {
let mut theme_families = Vec::new();
/// Whether VS Code themes should be imported.
- ///
- /// For the initial release of Zed2, we will just be using the Zed1 themes ported to Zed2.
const IMPORT_VS_CODE_THEMES: bool = false;
if IMPORT_VS_CODE_THEMES {
@@ -117,7 +117,11 @@ impl Zed1ThemeConverter {
.or(convert(lowest.accent.default.foreground)),
hint_background: convert(lowest.accent.default.background),
hint_border: convert(lowest.accent.default.border),
- predictive: convert(lowest.positive.default.foreground),
+ predictive: editor
+ .suggestion
+ .color
+ .map(zed1_color_to_hsla)
+ .or(convert(lowest.positive.default.foreground)),
predictive_background: convert(lowest.positive.default.background),
predictive_border: convert(lowest.positive.default.border),
conflict: convert(lowest.warning.default.foreground),
@@ -183,7 +187,7 @@ impl Zed1ThemeConverter {
Ok(ThemeColorsRefinement {
border: convert(lowest.base.default.border),
- border_variant: convert(lowest.variant.default.border),
+ border_variant: convert(middle.variant.default.border),
border_focused: convert(lowest.accent.hovered.border),
border_selected: convert(lowest.accent.default.border),
border_transparent: Some(gpui::transparent_black()),
@@ -226,7 +230,7 @@ impl Zed1ThemeConverter {
.map(|color| color_alpha(color, 0.3)),
scrollbar_thumb_hover_background: convert(middle.base.hovered.background),
scrollbar_thumb_border: convert(middle.base.default.border),
- scrollbar_track_background: convert(highest.base.default.background),
+ scrollbar_track_background: Some(gpui::transparent_black()),
scrollbar_track_border: convert(highest.variant.default.border),
editor_foreground: convert(editor.text_color),
editor_background: convert(editor.background),
@@ -1,4 +1,4 @@
-use client::{telemetry::Telemetry, TelemetrySettings};
+use client::telemetry::Telemetry;
use feature_flags::FeatureFlagAppExt;
use fs::Fs;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
@@ -7,7 +7,7 @@ use gpui::{
VisualContext, WeakView,
};
use picker::{Picker, PickerDelegate};
-use settings::{update_settings_file, Settings, SettingsStore};
+use settings::{update_settings_file, SettingsStore};
use std::sync::Arc;
use theme::{Theme, ThemeMeta, ThemeRegistry, ThemeSettings};
use ui::{prelude::*, v_stack, ListItem, ListItemSpacing};
@@ -181,9 +181,8 @@ impl PickerDelegate for ThemeSelectorDelegate {
let theme_name = cx.theme().name.clone();
- let telemetry_settings = TelemetrySettings::get_global(cx).clone();
self.telemetry
- .report_setting_event(telemetry_settings, "theme", theme_name.to_string());
+ .report_setting_event("theme", theme_name.to_string(), cx);
update_settings_file::<ThemeSettings>(self.fs.clone(), cx, move |settings| {
settings.theme = Some(theme_name.to_string());
@@ -1,25 +0,0 @@
-## Documentation priorities:
-
-These are the priorities to get documented, in a rough stack rank order:
-
-- [ ] label
-- [ ] button
-- [ ] icon_button
-- [ ] icon
-- [ ] list
-- [ ] avatar
-- [ ] panel
-- [ ] modal
-- [ ] palette
-- [ ] input
-- [ ] facepile
-- [ ] player
-- [ ] stacks
-- [ ] context menu
-- [ ] input
-- [ ] textarea/multiline input (not built - not an editor)
-- [ ] indicator
-- [ ] public actor
-- [ ] keybinding
-- [ ] tab
-- [ ] toast
@@ -1,6 +1,6 @@
use gpui::{AnyView, DefiniteLength};
-use crate::{prelude::*, IconPosition};
+use crate::{prelude::*, IconPosition, KeyBinding};
use crate::{
ButtonCommon, ButtonLike, ButtonSize, ButtonStyle, Icon, IconSize, Label, LineHeightStyle,
};
@@ -19,6 +19,7 @@ pub struct Button {
icon_size: Option<IconSize>,
icon_color: Option<Color>,
selected_icon: Option<Icon>,
+ key_binding: Option<KeyBinding>,
}
impl Button {
@@ -34,6 +35,7 @@ impl Button {
icon_size: None,
icon_color: None,
selected_icon: None,
+ key_binding: None,
}
}
@@ -76,6 +78,11 @@ impl Button {
self.selected_icon = icon.into();
self
}
+
+ pub fn key_binding(mut self, key_binding: impl Into<Option<KeyBinding>>) -> Self {
+ self.key_binding = key_binding.into();
+ self
+ }
}
impl Selectable for Button {
@@ -157,7 +164,7 @@ impl RenderOnce for Button {
self.base.child(
h_stack()
.gap_1()
- .when(self.icon_position.is_some(), |this| {
+ .when(self.icon_position == Some(IconPosition::Start), |this| {
this.children(self.icon.map(|icon| {
ButtonIcon::new(icon)
.disabled(is_disabled)
@@ -168,12 +175,18 @@ impl RenderOnce for Button {
}))
})
.child(
- Label::new(label)
- .color(label_color)
- .size(self.label_size.unwrap_or_default())
- .line_height_style(LineHeightStyle::UiLabel),
+ h_stack()
+ .gap_2()
+ .justify_between()
+ .child(
+ Label::new(label)
+ .color(label_color)
+ .size(self.label_size.unwrap_or_default())
+ .line_height_style(LineHeightStyle::UiLabel),
+ )
+ .children(self.key_binding),
)
- .when(!self.icon_position.is_some(), |this| {
+ .when(self.icon_position != Some(IconPosition::Start), |this| {
this.children(self.icon.map(|icon| {
ButtonIcon::new(icon)
.disabled(is_disabled)
@@ -24,11 +24,12 @@ impl IconSize {
#[derive(Debug, PartialEq, Copy, Clone, EnumIter)]
pub enum Icon {
Ai,
- ArrowLeft,
- ArrowUp,
ArrowDown,
+ ArrowLeft,
ArrowRight,
+ ArrowUp,
ArrowUpRight,
+ ArrowCircle,
AtSign,
AudioOff,
AudioOn,
@@ -39,25 +40,28 @@ pub enum Icon {
Bolt,
CaseSensitive,
Check,
- Copy,
ChevronDown,
ChevronLeft,
ChevronRight,
ChevronUp,
Close,
Collab,
+ Command,
+ Control,
Copilot,
- CopilotInit,
- CopilotError,
CopilotDisabled,
+ CopilotError,
+ CopilotInit,
+ Copy,
Dash,
Delete,
Disconnected,
Ellipsis,
Envelope,
- ExternalLink,
+ Escape,
ExclamationTriangle,
Exit,
+ ExternalLink,
File,
FileDoc,
FileGeneric,
@@ -78,30 +82,32 @@ pub enum Icon {
MagnifyingGlass,
MailOpen,
Maximize,
- Minimize,
Menu,
MessageBubbles,
Mic,
MicMute,
+ Minimize,
+ Option,
+ PageDown,
+ PageUp,
Plus,
Public,
Quote,
Replace,
ReplaceAll,
ReplaceNext,
+ Return,
Screen,
SelectAll,
- Split,
+ Shift,
Snip,
+ Space,
+ Split,
+ Tab,
Terminal,
+ Update,
WholeWord,
XCircle,
- Command,
- Control,
- Shift,
- Option,
- Return,
- Update,
ZedXCopilot,
}
@@ -109,40 +115,44 @@ impl Icon {
pub fn path(self) -> &'static str {
match self {
Icon::Ai => "icons/ai.svg",
+ Icon::ArrowDown => "icons/arrow_down.svg",
Icon::ArrowLeft => "icons/arrow_left.svg",
Icon::ArrowRight => "icons/arrow_right.svg",
Icon::ArrowUp => "icons/arrow_up.svg",
- Icon::ArrowDown => "icons/arrow_down.svg",
Icon::ArrowUpRight => "icons/arrow_up_right.svg",
- Icon::AtSign => "icons/at-sign.svg",
- Icon::AudioOff => "icons/speaker-off.svg",
- Icon::AudioOn => "icons/speaker-loud.svg",
+ Icon::ArrowCircle => "icons/arrow_circle.svg",
+ Icon::AtSign => "icons/at_sign.svg",
+ Icon::AudioOff => "icons/speaker_off.svg",
+ Icon::AudioOn => "icons/speaker_loud.svg",
Icon::Backspace => "icons/backspace.svg",
Icon::Bell => "icons/bell.svg",
- Icon::BellOff => "icons/bell-off.svg",
- Icon::BellRing => "icons/bell-ring.svg",
+ Icon::BellOff => "icons/bell_off.svg",
+ Icon::BellRing => "icons/bell_ring.svg",
Icon::Bolt => "icons/bolt.svg",
Icon::CaseSensitive => "icons/case_insensitive.svg",
Icon::Check => "icons/check.svg",
- Icon::Copy => "icons/copy.svg",
Icon::ChevronDown => "icons/chevron_down.svg",
Icon::ChevronLeft => "icons/chevron_left.svg",
Icon::ChevronRight => "icons/chevron_right.svg",
Icon::ChevronUp => "icons/chevron_up.svg",
Icon::Close => "icons/x.svg",
Icon::Collab => "icons/user_group_16.svg",
+ Icon::Command => "icons/command.svg",
+ Icon::Control => "icons/control.svg",
Icon::Copilot => "icons/copilot.svg",
- Icon::CopilotInit => "icons/copilot_init.svg",
- Icon::CopilotError => "icons/copilot_error.svg",
Icon::CopilotDisabled => "icons/copilot_disabled.svg",
+ Icon::CopilotError => "icons/copilot_error.svg",
+ Icon::CopilotInit => "icons/copilot_init.svg",
+ Icon::Copy => "icons/copy.svg",
Icon::Dash => "icons/dash.svg",
Icon::Delete => "icons/delete.svg",
Icon::Disconnected => "icons/disconnected.svg",
Icon::Ellipsis => "icons/ellipsis.svg",
Icon::Envelope => "icons/feedback.svg",
+ Icon::Escape => "icons/escape.svg",
Icon::ExclamationTriangle => "icons/warning.svg",
- Icon::ExternalLink => "icons/external_link.svg",
Icon::Exit => "icons/exit.svg",
+ Icon::ExternalLink => "icons/external_link.svg",
Icon::File => "icons/file.svg",
Icon::FileDoc => "icons/file_icons/book.svg",
Icon::FileGeneric => "icons/file_icons/file.svg",
@@ -159,34 +169,36 @@ impl Icon {
Icon::Hash => "icons/hash.svg",
Icon::InlayHint => "icons/inlay_hint.svg",
Icon::Link => "icons/link.svg",
- Icon::MagicWand => "icons/magic-wand.svg",
+ Icon::MagicWand => "icons/magic_wand.svg",
Icon::MagnifyingGlass => "icons/magnifying_glass.svg",
- Icon::MailOpen => "icons/mail-open.svg",
+ Icon::MailOpen => "icons/mail_open.svg",
Icon::Maximize => "icons/maximize.svg",
- Icon::Minimize => "icons/minimize.svg",
Icon::Menu => "icons/menu.svg",
Icon::MessageBubbles => "icons/conversations.svg",
Icon::Mic => "icons/mic.svg",
- Icon::MicMute => "icons/mic-mute.svg",
+ Icon::MicMute => "icons/mic_mute.svg",
+ Icon::Minimize => "icons/minimize.svg",
+ Icon::Option => "icons/option.svg",
+ Icon::PageDown => "icons/page_down.svg",
+ Icon::PageUp => "icons/page_up.svg",
Icon::Plus => "icons/plus.svg",
Icon::Public => "icons/public.svg",
Icon::Quote => "icons/quote.svg",
Icon::Replace => "icons/replace.svg",
Icon::ReplaceAll => "icons/replace_all.svg",
Icon::ReplaceNext => "icons/replace_next.svg",
+ Icon::Return => "icons/return.svg",
Icon::Screen => "icons/desktop.svg",
- Icon::SelectAll => "icons/select-all.svg",
- Icon::Split => "icons/split.svg",
+ Icon::SelectAll => "icons/select_all.svg",
+ Icon::Shift => "icons/shift.svg",
Icon::Snip => "icons/snip.svg",
+ Icon::Space => "icons/space.svg",
+ Icon::Split => "icons/split.svg",
+ Icon::Tab => "icons/tab.svg",
Icon::Terminal => "icons/terminal.svg",
+ Icon::Update => "icons/update.svg",
Icon::WholeWord => "icons/word_search.svg",
Icon::XCircle => "icons/error.svg",
- Icon::Command => "icons/command.svg",
- Icon::Control => "icons/control.svg",
- Icon::Shift => "icons/shift.svg",
- Icon::Option => "icons/option.svg",
- Icon::Return => "icons/return.svg",
- Icon::Update => "icons/update.svg",
Icon::ZedXCopilot => "icons/zed_x_copilot.svg",
}
}
@@ -21,9 +21,9 @@ impl RenderOnce for KeyBinding {
h_stack()
.flex_none()
.gap_0p5()
- .bg(cx.theme().colors().element_background)
.p_0p5()
.rounded_sm()
+ .text_color(cx.theme().colors().text_muted)
.when(keystroke.modifiers.function, |el| el.child(Key::new("fn")))
.when(keystroke.modifiers.control, |el| {
el.child(KeyIcon::new(Icon::Control))
@@ -70,6 +70,13 @@ impl KeyBinding {
"down" => Some(Icon::ArrowDown),
"backspace" => Some(Icon::Backspace),
"delete" => Some(Icon::Delete),
+ "return" => Some(Icon::Return),
+ "enter" => Some(Icon::Return),
+ "tab" => Some(Icon::Tab),
+ "space" => Some(Icon::Space),
+ "escape" => Some(Icon::Escape),
+ "pagedown" => Some(Icon::PageDown),
+ "pageup" => Some(Icon::PageUp),
_ => None,
}
}
@@ -100,7 +107,7 @@ impl RenderOnce for Key {
.h(rems(14. / 16.))
.text_ui()
.line_height(relative(1.))
- .text_color(cx.theme().colors().text)
+ .text_color(cx.theme().colors().text_muted)
.child(self.key.clone())
}
}
@@ -118,9 +125,11 @@ pub struct KeyIcon {
impl RenderOnce for KeyIcon {
fn render(self, _cx: &mut WindowContext) -> impl IntoElement {
- div()
- .w(rems(14. / 16.))
- .child(IconElement::new(self.icon).size(IconSize::Small))
+ div().w(rems(14. / 16.)).child(
+ IconElement::new(self.icon)
+ .size(IconSize::Small)
+ .color(Color::Muted),
+ )
}
}
@@ -2,15 +2,8 @@
//!
//! This crate provides a set of UI primitives and components that are used to build all of the elements in Zed's UI.
//!
-//! ## Work in Progress
-//!
-//! This crate is still a work in progress. The initial primitives and components are built for getting all the UI on the screen,
-//! much of the state and functionality is mocked or hard codeded, and performance has not been a focus.
-//!
-#![doc = include_str!("../docs/hello-world.md")]
#![doc = include_str!("../docs/building-ui.md")]
-#![doc = include_str!("../docs/todo.md")]
mod clickable;
mod components;
@@ -15,7 +15,7 @@ use anyhow::{anyhow, Context as _, Result};
use call::ActiveCall;
use client::{
proto::{self, PeerId},
- Client, Status, TelemetrySettings, TypedEnvelope, UserStore,
+ Client, Status, TypedEnvelope, UserStore,
};
use collections::{hash_map, HashMap, HashSet};
use dock::{Dock, DockPosition, Panel, PanelButtons, PanelHandle};
@@ -1095,19 +1095,21 @@ impl Workspace {
}
pub fn close_global(_: &CloseWindow, cx: &mut AppContext) {
- cx.windows().iter().find(|window| {
- window
- .update(cx, |_, window| {
- if window.is_window_active() {
- //This can only get called when the window's project connection has been lost
- //so we don't need to prompt the user for anything and instead just close the window
- window.remove_window();
- true
- } else {
- false
- }
- })
- .unwrap_or(false)
+ cx.defer(|cx| {
+ cx.windows().iter().find(|window| {
+ window
+ .update(cx, |_, window| {
+ if window.is_window_active() {
+ //This can only get called when the window's project connection has been lost
+ //so we don't need to prompt the user for anything and instead just close the window
+ window.remove_window();
+ true
+ } else {
+ false
+ }
+ })
+ .unwrap_or(false)
+ });
});
}
@@ -1250,10 +1252,9 @@ impl Workspace {
}
pub fn open(&mut self, _: &Open, cx: &mut ViewContext<Self>) {
- let telemetry_settings = TelemetrySettings::get_global(cx).clone();
self.client()
.telemetry()
- .report_app_event(telemetry_settings, "open project", false);
+ .report_app_event("open project", false, cx);
let paths = cx.prompt_for_paths(PathPromptOptions {
files: true,
directories: true,
@@ -144,6 +144,7 @@ fn main() {
cx.set_global(client.clone());
+ zed::init(cx);
theme::init(theme::LoadThemes::All, cx);
project::Project::init(&client, cx);
client::init(&client, cx);
@@ -158,7 +159,6 @@ fn main() {
cx,
);
assistant::init(cx);
- // component_test::init(cx);
cx.spawn(|_| watch_languages(fs.clone(), languages.clone()))
.detach();
@@ -172,19 +172,16 @@ fn main() {
.detach();
client.telemetry().start(installation_id, session_id, cx);
- let telemetry_settings = *client::TelemetrySettings::get_global(cx);
- client.telemetry().report_setting_event(
- telemetry_settings,
- "theme",
- cx.theme().name.to_string(),
- );
+ client
+ .telemetry()
+ .report_setting_event("theme", cx.theme().name.to_string(), cx);
let event_operation = match existing_installation_id_found {
Some(false) => "first open",
_ => "open",
};
client
.telemetry()
- .report_app_event(telemetry_settings, event_operation, true);
+ .report_app_event(event_operation, true, cx);
let app_state = Arc::new(AppState {
languages: languages.clone(),
@@ -64,6 +64,13 @@ actions!(
]
);
+pub fn init(cx: &mut AppContext) {
+ cx.on_action(|_: &Hide, cx| cx.hide());
+ cx.on_action(|_: &HideOthers, cx| cx.hide_other_apps());
+ cx.on_action(|_: &ShowAll, cx| cx.unhide_other_apps());
+ cx.on_action(quit);
+}
+
pub fn build_window_options(
bounds: Option<WindowBounds>,
display_uuid: Option<Uuid>,
@@ -130,7 +137,6 @@ pub fn initialize_workspace(app_state: Arc<AppState>, cx: &mut AppContext) {
status_bar.add_left_item(diagnostic_summary, cx);
status_bar.add_left_item(activity_indicator, cx);
status_bar.add_right_item(feedback_button, cx);
- // status_bar.add_right_item(copilot, cx);
status_bar.add_right_item(copilot, cx);
status_bar.add_right_item(active_buffer_language, cx);
status_bar.add_right_item(vim_mode_indicator, cx);
@@ -207,15 +213,6 @@ pub fn initialize_workspace(app_state: Arc<AppState>, cx: &mut AppContext) {
workspace
.register_action(about)
- .register_action(|_, _: &Hide, cx| {
- cx.hide();
- })
- .register_action(|_, _: &HideOthers, cx| {
- cx.hide_other_apps();
- })
- .register_action(|_, _: &ShowAll, cx| {
- cx.unhide_other_apps();
- })
.register_action(|_, _: &Minimize, cx| {
cx.minimize_window();
})
@@ -225,7 +222,6 @@ pub fn initialize_workspace(app_state: Arc<AppState>, cx: &mut AppContext) {
.register_action(|_, _: &ToggleFullScreen, cx| {
cx.toggle_full_screen();
})
- .register_action(quit)
.register_action(|_, action: &OpenZedURL, cx| {
cx.global::<Arc<OpenListener>>()
.open_urls(&[action.url.clone()])
@@ -451,10 +447,10 @@ fn about(_: &mut Workspace, _: &About, cx: &mut gpui::ViewContext<Workspace>) {
.detach();
}
-fn quit(_: &mut Workspace, _: &Quit, cx: &mut gpui::ViewContext<Workspace>) {
+fn quit(_: &Quit, cx: &mut AppContext) {
let should_confirm = WorkspaceSettings::get_global(cx).confirm_quit;
- cx.spawn(|_, mut cx| async move {
- let mut workspace_windows = cx.update(|_, cx| {
+ cx.spawn(|mut cx| async move {
+ let mut workspace_windows = cx.update(|cx| {
cx.windows()
.into_iter()
.filter_map(|window| window.downcast::<Workspace>())
@@ -463,14 +459,14 @@ fn quit(_: &mut Workspace, _: &Quit, cx: &mut gpui::ViewContext<Workspace>) {
// If multiple windows have unsaved changes, and need a save prompt,
// prompt in the active window before switching to a different window.
- cx.update(|_, cx| {
+ cx.update(|cx| {
workspace_windows.sort_by_key(|window| window.is_active(&cx) == Some(false));
})
.log_err();
- if let (true, Some(_)) = (should_confirm, workspace_windows.first().copied()) {
- let answer = cx
- .update(|_, cx| {
+ if let (true, Some(workspace)) = (should_confirm, workspace_windows.first().copied()) {
+ let answer = workspace
+ .update(&mut cx, |_, cx| {
cx.prompt(
PromptLevel::Info,
"Are you sure you want to quit?",
@@ -500,9 +496,7 @@ fn quit(_: &mut Workspace, _: &Quit, cx: &mut gpui::ViewContext<Workspace>) {
}
}
}
- cx.update(|_, cx| {
- cx.quit();
- })?;
+ cx.update(|cx| cx.quit())?;
anyhow::Ok(())
})
.detach_and_log_err(cx);