fix(surveys): don't force the default placeholder on open text questions - #4725
Draft
bs1180 wants to merge 1 commit into
Draft
fix(surveys): don't force the default placeholder on open text questions#4725bs1180 wants to merge 1 commit into
bs1180 wants to merge 1 commit into
Conversation
The web and React Native SDKs both carried `placeholder: 'Start typing...'` in their default survey appearance, so an open text question showed that placeholder whenever the survey's appearance had no placeholder of its own — even though the field reads as empty in the survey editor. Drop the placeholder from both SDK defaults so the textarea only shows placeholder text the survey actually configures. Generated-By: PostHog Desktop Task-Id: 8acde03a-4423-45ce-951a-7df419ba6556
Contributor
Contributor
posthog-js Compliance ReportDate: 2026-09-01 14:44:46 UTC ✅ All Tests Passed!26/26 tests passed Capture Tests✅ 26/26 tests passed View Details
|
Contributor
|
Size Change: -270 B (0%) Total Size: 20.8 MB 📦 View Changed
ℹ️ View Unchanged
|
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.
Problem
An open text survey question always rendered the placeholder "Start typing..." when the survey's appearance had no placeholder of its own. In the survey editor the "Placeholder text" field looks empty in that case, so the survey doesn't match its config — reported via #cs.
Changes
Removed
placeholder: 'Start typing...'from the default survey appearance in both the web and React Native SDKs. The open text textarea now shows only placeholder text the survey actually configures; an empty (or unset) placeholder renders no placeholder at all. Added web unit tests covering both the cleared and unset cases.Note this intentionally diverges from
defaultSurveyAppearancein the main app, which still seeds new surveys with "Start typing..." — surveys that set a placeholder are unaffected.Release info Sub-libraries affected
Libraries affected
Checklist
If releasing new changes
pnpm changesetto generate a changeset file🤖 Agent context
Autonomy: Fully autonomous
appearance?.placeholderdirectly, and only the SDK-leveldefaultSurveyAppearancecan reintroduce a value; React Native spreads its defaults under the survey's appearance, so it substituted the default whenever the key was absent.packages/browsersurvey unit tests (all passing) and lint/typecheck on the changed files. No manual in-browser testing.Created with PostHog Desktop