Repository navigation
Studio: customizable new-chat greeting - #16408
Merged
Merged
Conversation
The Greeting setting now offers Icon and text (sloth, custom icon or none, plus optional custom words), Image (replaces the whole greeting) and Off. showGreetingSloth stays the on/off value, so the old switch maps onto the new choice without a rewrite. Uploads are PNG, JPEG, WebP or GIF only, re-encoded through a canvas and size capped on client and server. New fields sync through personalization, with greetingCustomSaved for legacy records.
The Greeting row now opens a single menu: Unsloth, Custom icon, Text only, Image or Off, with the upload and greeting text for the chosen mode underneath. The sloth option is labeled Unsloth.
The Greeting row now shows four tiles (Default, Custom, Image, Off) that preview each greeting, with the chosen mode's controls under them. Default gets a Sloth icon switch; Custom holds the user's icon, removable for text only, and their words.
The tiles now sit in the row's control slot beside the Greeting title, with a thinner selected outline. The sloth switch is gone (Default is always the sloth), an empty Image tile shows a small accent-coloured landscape, and the greeting image can be removed like the icon.
…efault The greeting's last tile reads None, its text hint now says a blank field uses the built-in greetings, and the Standard chat width is labeled Default, in all locales.
The greeting upload no longer lists file types under the button; only an upload error shows there. The Background image previews now say they show your current settings.
The None tile shows a muted stop sign instead of an empty box, and the Background image previews read "Here's how your chats will look." in all locales.
The separate caption is gone; the two boxes are labeled New chat preview and Conversation preview, in all locales.
…n empty Image tile
Member
Author
|
@codex review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
# Conflicts: # studio/frontend/src/components/assistant-ui/thread.tsx # studio/frontend/src/features/settings/tabs/appearance-tab.tsx
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
danielhanchen
added a commit
that referenced
this pull request
Nov 1, 2026
… their copy (#16431) ## Summary `Chat UI Tests (extra)` fails on PRs based on current main (#16418, #16421, #16413) in the chat width driver: ``` [chat-width] FAIL in step "measure the 'Standard' preset across 7 viewports" after 30.7s: TimeoutError: Locator.click: Timeout 30000ms exceeded. - waiting for get_by_role("option", name="Standard", exact=True) ``` #16408 (`8da4ba2f1c`, customizable new-chat greeting) renamed the chat width option label from "Standard" to "Default" (`settings.appearance.custom.chatWidth.standard`) in every locale. The product change is intended. `tests/studio/playwright_chat_width.py` clicked the option by its English text, so it waited for an option that no longer exists. ## Change - **`playwright_chat_width.py`:** the driver picks each preset by its position in the open listbox, not by its copy. The component lists the values as `["standard", "wide", "full"]`. The driver's own names for the presets (`CHAT_WIDTH_PRESETS`) are unchanged, so the measurements and messages read the same. I did not switch it to the `_en_catalog` reader, because `test_en_catalog.py` pins every catalog-reading driver to the composer workflow, and this one runs in `studio-ui-smoke.yml`. - **New `tests/studio/test_chat_width_driver_presets.py`:** checks that `appearance-custom-controls.tsx` still maps over `["standard", "wide", "full"]` in that order, and that the driver has one preset per option. A reorder or a new option then fails here instead of measuring the wrong preset. ## Testing - The new test, `test_en_catalog.py` and `test_playwright_suites_run_in_ci.py`: 54 passed. - Sabotage: with the component's order swapped to `["wide", "standard", "full"]`, the new test fails. - The driver itself needs a live Studio. It runs in this PR's own `Chat UI Tests (extra)` job, and I will only merge once that is green. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
The Greeting switch in Settings > Appearance > Preferences is now a row of four tiles beside the Greeting title. Each tile previews that greeting using your own uploads, and the chosen mode's controls sit underneath.
The composer stays exactly where it was in every mode: an image greeting grows upward from the text row's slot, and a row with no icon keeps the icon's height.
Two small wording changes nearby:
Storage, sync and migration
showGreetingSlothis still the on/off value, so the old switch maps straight onto the tiles (off shows as None, on as Default) and older builds keep reading it. No data rewrite is needed.greetingStyle,greetingIcon,greetingIconDataUrl,greetingText,greetingImageDataUrl. They sync through the personalization endpoint like the avatar.greetingCustomSavedon GET mirrorsgreetingSlothSaved: a record that predates the fields keeps and re-pushes the local customization instead of resetting it to server defaults.Upload safety
data:image/(png|jpeg|webp|gif);base64,...URLs, with length caps (96 KB icon, 512 KB image) and a 100-character text limit. The renderer drops anything else before it reaches an<img>.New and changed strings are translated in all 25 locales.
Verification
npm run typecheck,npm testandnpm run buildpass.pytest studio/backend/tests/test_personalization_settings.pypasses, with new cases for SVG andjavascript:rejection, the size caps, the legacy flag and the unknown-value fallback.Not testable here: the Desktop (Tauri/WebKit) shell. On Safari the WebP encode falls back to PNG through the existing helper.