Change "Ok" to "OK" in UI (#58744)

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [ ] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #58543 and extends to all instances of "Ok" button labels.

Release Notes:

- N/A

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
This commit is contained in:
Albert Bogusz 2026-06-08 15:48:37 +01:00 committed by GitHub
parent e40e7e8b05
commit 1d1a4bee34
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 19 additions and 19 deletions

View file

@ -281,7 +281,7 @@ pub fn check(_: &Check, window: &mut Window, cx: &mut App) {
gpui::PromptLevel::Info,
"Zed was installed via a package manager.",
Some(&message),
&["Ok"],
&["OK"],
cx,
));
return;
@ -301,7 +301,7 @@ pub fn check(_: &Check, window: &mut Window, cx: &mut App) {
gpui::PromptLevel::Info,
"Could not check for updates",
Some("Auto-updates disabled for non-bundled app."),
&["Ok"],
&["OK"],
cx,
));
}

View file

@ -2275,7 +2275,7 @@ impl GitPanel {
return;
};
let error_spawn = |message, window: &mut Window, cx: &mut App| {
let prompt = window.prompt(PromptLevel::Warning, message, None, &["Ok"], cx);
let prompt = window.prompt(PromptLevel::Warning, message, None, &["OK"], cx);
cx.spawn(async move |_| {
prompt.await.ok();
})
@ -2952,7 +2952,7 @@ impl GitPanel {
PromptLevel::Warning,
"Unable to initialize a git repository",
Some("Open a directory first"),
&["Ok"],
&["OK"],
cx,
);
cx.background_executor()

View file

@ -272,7 +272,7 @@ impl Render for WindowDemo {
PromptLevel::Info,
"Are you sure?",
None,
&["Ok", "Cancel"],
&["OK", "Cancel"],
cx,
);

View file

@ -1796,7 +1796,7 @@ impl PromptButton {
impl From<&str> for PromptButton {
fn from(value: &str) -> Self {
match value.to_lowercase().as_str() {
"ok" => PromptButton::Ok("Ok".into()),
"ok" => PromptButton::Ok("OK".into()),
"cancel" => PromptButton::Cancel("Cancel".into()),
_ => PromptButton::Other(SharedString::from(value.to_owned())),
}

View file

@ -70,7 +70,7 @@ pub fn install_cli_binary(window: &mut Window, cx: &mut Context<Workspace>) {
PromptLevel::Warning,
"CLI should already be installed",
Some(LINUX_PROMPT_DETAIL),
&["Ok"],
&["OK"],
);
cx.background_spawn(prompt).detach();
return Ok(());

View file

@ -485,7 +485,7 @@ pub async fn handle_import_vscode_settings(
gpui::PromptLevel::Info,
&format!("Could not find or load a {source} settings file"),
None,
&["Ok"],
&["OK"],
);
return;
}
@ -501,7 +501,7 @@ pub async fn handle_import_vscode_settings(
truncate_and_remove_front(&vscode_settings.path.to_string_lossy(), 128),
),
None,
&["Ok", "Cancel"],
&["Import", "Cancel"],
);
let result = cx.spawn(async move |_| prompt.await.ok()).await;
if result != Some(0) {

View file

@ -348,7 +348,7 @@ pub fn init(cx: &mut App) {
Please note that Zed currently does not support opening network share folders inside wsl.
"#};
let _ = cx.prompt(gpui::PromptLevel::Critical, "Invalid path", Some(&message), &["Ok"]).await;
let _ = cx.prompt(gpui::PromptLevel::Critical, "Invalid path", Some(&message), &["OK"]).await;
return;
}
@ -492,7 +492,7 @@ pub fn init(cx: &mut App) {
gpui::PromptLevel::Critical,
"Cannot open Dev Container from remote project",
None,
&["Ok"],
&["OK"],
)
.await
.ok();

View file

@ -1780,7 +1780,7 @@ impl RemoteServerProjects {
gpui::PromptLevel::Critical,
"Failed to connect",
Some(&e.to_string()),
&["Ok"],
&["OK"],
)
.await
.ok();
@ -2075,7 +2075,7 @@ impl RemoteServerProjects {
gpui::PromptLevel::Critical,
"Failed to start Dev Container. See logs for details",
Some(&format!("{e}")),
&["Ok"],
&["OK"],
)
.await
.ok();
@ -2130,7 +2130,7 @@ impl RemoteServerProjects {
gpui::PromptLevel::Critical,
"Failed to connect",
Some(&e.to_string()),
&["Ok"],
&["OK"],
)
.await
.ok();

View file

@ -141,7 +141,7 @@ impl RenderOnce for AlertModal {
if let Some(footer) = self.footer {
modal = modal.child(footer);
} else if has_default_footer {
let primary_action = self.primary_action.unwrap_or_else(|| "Ok".into());
let primary_action = self.primary_action.unwrap_or_else(|| "OK".into());
let dismiss_label = self.dismiss_label.unwrap_or_else(|| "Cancel".into());
modal = modal.child(

View file

@ -1665,7 +1665,7 @@ where
display.push('.');
}
let detail = f(err, window, cx).unwrap_or(display);
window.prompt(PromptLevel::Critical, &msg, Some(&detail), &["Ok"], cx)
window.prompt(PromptLevel::Critical, &msg, Some(&detail), &["OK"], cx)
}) {
prompt.await.ok();
}

View file

@ -9640,7 +9640,7 @@ pub fn join_channel(
PromptLevel::Critical,
"Failed to join channel",
Some(&detail),
&["Ok"],
&["OK"],
cx,
)
})?

View file

@ -1533,7 +1533,7 @@ fn open_about_window(cx: &mut App) {
window.remove_window();
}))
.child(
Button::new("ok", "Ok")
Button::new("ok", "OK")
.full_width()
.style(ButtonStyle::OutlinedGhost)
.toggle_state(ok_is_focused)

View file

@ -105,7 +105,7 @@ impl MoveToApplicationsRequest {
PromptLevel::Critical,
"Failed to move Zed to Applications",
Some(&error.to_string()),
&["Ok"],
&["OK"],
)
.await
.log_err();