ui(gui): say 'window' instead of 'browser tab' in shutdown copy
Update the Close page intro, the shutdown overlay, and the toast so they all read "you can close this window" — clearer for users running the app in a dedicated browser window rather than a tab. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -105,7 +105,7 @@ _FAREWELL_SCRIPT = """
|
||||
'border-radius:12px;background:#161922;max-width:480px;">' +
|
||||
'<h1 style="margin:0 0 8px 0;font-weight:600;letter-spacing:-0.01em;">' +
|
||||
'DataTools has shut down</h1>' +
|
||||
'<p style="opacity:0.7;margin:0;">You can close this browser tab.</p>' +
|
||||
'<p style="opacity:0.7;margin:0;">You can close this window.</p>' +
|
||||
'</div>';
|
||||
return overlay;
|
||||
}
|
||||
@@ -143,7 +143,7 @@ def quit_button(label: str = "Quit app", *, key: str = "quit_app_button") -> Non
|
||||
if st.session_state.get("_app_shutting_down"):
|
||||
from streamlit.components.v1 import html as _components_html
|
||||
_components_html(_FAREWELL_SCRIPT, height=0)
|
||||
st.success("Shutting down… you can close this browser tab.")
|
||||
st.success("Shutting down… you can close this window.")
|
||||
st.stop()
|
||||
|
||||
if st.button(label, key=key, type="secondary"):
|
||||
|
||||
@@ -33,9 +33,8 @@ st.divider()
|
||||
|
||||
st.markdown(
|
||||
"Clicking the button below will terminate the DataTools server. "
|
||||
"Any unsaved work in other tools will be lost. The browser tab "
|
||||
"will show a connection-error message — that's expected; you can "
|
||||
"close the tab once it appears."
|
||||
"Any unsaved work in other tools will be lost. Once the app shuts "
|
||||
"down you can close this window."
|
||||
)
|
||||
|
||||
st.write("")
|
||||
|
||||
Reference in New Issue
Block a user