Introduce a button to disable copilot integration
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
54a78d7024
commit
8610f3acf3
2 changed files with 16 additions and 2 deletions
|
@ -5,7 +5,7 @@ use gpui::{
|
||||||
platform::{WindowBounds, WindowKind, WindowOptions},
|
platform::{WindowBounds, WindowKind, WindowOptions},
|
||||||
AppContext, ClipboardItem, Element, Entity, View, ViewContext, ViewHandle,
|
AppContext, ClipboardItem, Element, Entity, View, ViewContext, ViewHandle,
|
||||||
};
|
};
|
||||||
use settings::Settings;
|
use settings::{settings_file::SettingsFile, Settings};
|
||||||
use theme::ui::modal;
|
use theme::ui::modal;
|
||||||
|
|
||||||
#[derive(PartialEq, Eq, Debug, Clone)]
|
#[derive(PartialEq, Eq, Debug, Clone)]
|
||||||
|
@ -199,6 +199,20 @@ impl CopilotCodeVerification {
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
.boxed(),
|
.boxed(),
|
||||||
|
theme::ui::cta_button_with_click(
|
||||||
|
"Disable Copilot Integration",
|
||||||
|
style.auth.content_width,
|
||||||
|
&style.auth.cta_button,
|
||||||
|
cx,
|
||||||
|
{
|
||||||
|
move |_, cx| {
|
||||||
|
SettingsFile::update(cx, move |settings| {
|
||||||
|
settings.features.copilot = Some(false);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
)
|
||||||
|
.boxed(),
|
||||||
])
|
])
|
||||||
.align_children_center()
|
.align_children_center()
|
||||||
.boxed()
|
.boxed()
|
||||||
|
|
|
@ -113,7 +113,7 @@ export default function copilot(colorScheme: ColorScheme) {
|
||||||
},
|
},
|
||||||
dimensions: {
|
dimensions: {
|
||||||
width: 280,
|
width: 280,
|
||||||
height: 280,
|
height: 320,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue