diff --git a/src/app.cpp b/src/app.cpp index d8922ce..bc82151 100644 --- a/src/app.cpp +++ b/src/app.cpp @@ -2848,7 +2848,9 @@ void App::renderImportKeyDialog() ov.title = viewMode ? TR("import_viewkey_title") : TR("import_key_title"); ov.p_open = &show_import_key_; ov.style = m::OverlayStyle::BlurFloat; - ov.cardWidth = 640.0f; // wide enough that the one-line warning under the heading doesn't wrap + // Wide enough that the one-line care header under the heading doesn't wrap; the viewing-key note + // is longer, so that mode gets a wider card. + ov.cardWidth = viewMode ? 760.0f : 640.0f; ov.idSuffix = "importkey"; if (!m::BeginOverlayDialog(ov)) return; @@ -2878,19 +2880,9 @@ void App::renderImportKeyDialog() // Esc dismisses (this overlay has no built-in Esc handling). if (ImGui::IsKeyPressed(ImGuiKey_Escape)) show_import_key_ = false; - // Handle-with-care note. A spending key grants access to funds (strong warning); a viewing key - // is watch-only (milder, informational eye note). - if (viewMode) { - ImGui::PushFont(m::Type().iconSmall()); - ImGui::TextColored(ImGui::ColorConvertU32ToFloat4(m::OnSurfaceMedium()), ICON_MD_VISIBILITY); - ImGui::PopFont(); - ImGui::SameLine(0, 6.0f * dp); - ImGui::PushTextWrapPos(0.0f); - ImGui::TextColored(ImGui::ColorConvertU32ToFloat4(m::OnSurfaceMedium()), "%s", TR("import_viewkey_note")); - ImGui::PopTextWrapPos(); - } else { - m::DialogWarningHeader(TR("import_key_warn")); - } + // Handle-with-care header — same warning icon + color for both modes (the viewing dialog is wider + // so its longer watch-only note stays on one line, matching the private-key warning). + m::DialogWarningHeader(viewMode ? TR("import_viewkey_note") : TR("import_key_warn")); ImGui::Spacing(); // A running node is required — say so up front instead of failing only after Import.