Skip to content

fix(playground): hide default placeholders for explicit args - #4275

Merged
sxlijin merged 4 commits into
canaryfrom
agent/b-1061-default-arg-placeholder
Jul 29, 2026
Merged

sxlijin merged 4 commits into
canaryfrom
agent/b-1061-default-arg-placeholder

Conversation

@sxlijin

@sxlijin sxlijin commented Jul 29, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • hide a declared default expression once a default-capable argument is checked for an explicit value
  • keep the declared default visible while the argument is unchecked and using its default
  • preserve schema-specific placeholders for required arguments

Root cause

ArgsForm always forwarded param.defaultExpression as the native input placeholder, regardless of whether the argument was using its default or had been checked for an explicit value. An empty explicit string therefore looked like the declared default would be sent.

Playground UI

Before

Before: checked explicit argument still shows the declared default placeholder

After

After: checked explicit argument has an empty input without the declared default placeholder

Validation

  • pnpm exec biome check pkg-playground/src/ArgsForm.tsx
  • pnpm --filter @b/pkg-playground typecheck
  • pnpm --filter @b/pkg-playground test (145 tests)
  • pnpm --filter app-vscode-webview typecheck
  • pnpm --filter app-promptfiddle typecheck
  • pnpm --filter app-vscode-webview test:unit:run -- ExecutionPanel.strict-mode.test.tsx (22 tests)
  • git diff --check

Linear: https://linear.app/boundaryml2/issue/B-1061/default-arg-ui-when-default-args-are-checked-the-placeholder-in-the

Summary by CodeRabbit

  • Bug Fixes
    • Fixed parameter fields showing default-value placeholders even after an explicit value was entered.
    • Placeholders now correctly reflect whether a parameter is using its default or an explicitly provided value.
  • Documentation
    • Updated the issue status record with reproduction details, validation results, and review progress.

@linear

linear Bot commented Jul 29, 2026

Copy link
Copy Markdown

B-1061

@vercel

vercel Bot commented Jul 29, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
beps Ready Ready Preview, Comment Jul 29, 2026 9:24am
promptfiddle Ready Ready Preview, Comment Jul 29, 2026 9:24am
promptfiddle2 Ready Ready Preview, Comment Jul 29, 2026 9:24am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 29, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

💤 Files selected but had no reviewable changes (1)
  • issue-overview.md
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: b3a40dc8-1100-4df1-8e59-b2090ee9b19a

📥 Commits

Reviewing files that changed from the base of the PR and between cf0470d and 147a0df.

📒 Files selected for processing (1)
  • issue-overview.md

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

ParamRow now displays default expressions as placeholders only for omitted parameters, while explicit values receive an empty placeholder. The issue overview records the B-1061 investigation, implementation, validation, and PR status.

Changes

Argument placeholder update

Layer / File(s) Summary
Mode-aware placeholder behavior
typescript2/pkg-playground/src/ArgsForm.tsx, issue-overview.md
FieldInput receives a default-expression placeholder only when a parameter is omitted, an empty string for explicit values, and undefined when no default exists. The issue status records the root cause, implementation, validation, and PR details.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

  • BoundaryML/baml#4270: Related ArgsForm.tsx work conditionally displays default expressions for defaulted and omitted parameters.

Poem

A bunny spots a placeholder bright,
Then clears it when values come into sight.
Defaults appear when fields sleep still,
Explicit inputs show their will.
B-1061 hops toward done—
With tested changes, nearly won!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: hiding default placeholders for explicit arguments in the playground form.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch agent/b-1061-default-arg-placeholder

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

⏭️ Performance benchmarks were skipped

Perf benchmarks (CodSpeed) are opt-in on pull requests — they no longer run on every push. They always run automatically after merge to canary/main.

To run them on this PR, do any of the following, then push a commit (or re-run CI):

  • Add RUN_CODSPEED=1 to the PR description, or
  • Include run-perf or /perf in the PR title or any commit message.

@vercel
vercel Bot temporarily deployed to Preview – beps July 29, 2026 08:51 Inactive
@sxlijin

sxlijin commented Jul 29, 2026

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 29, 2026 •

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@vercel
vercel Bot temporarily deployed to Preview – promptfiddle2 July 29, 2026 08:58 Inactive
@vercel
vercel Bot temporarily deployed to Preview – beps July 29, 2026 09:02 Inactive
@vercel
vercel Bot temporarily deployed to Preview – beps July 29, 2026 09:03 Inactive
@sxlijin
sxlijin added this pull request to the merge queue Jul 29, 2026
@vercel
vercel Bot temporarily deployed to Preview – promptfiddle2 July 29, 2026 09:11 Inactive
Merged via the queue into canary with commit fc9cf16 Jul 29, 2026
38 of 39 checks passed
@sxlijin
sxlijin deleted the agent/b-1061-default-arg-placeholder branch July 29, 2026 09:16
@vercel
vercel Bot temporarily deployed to Preview – promptfiddle July 29, 2026 09:24 Inactive

This branch was previously deployed

3 inactive deployments
Preview – promptfiddle — 147a0df4 Deployed Jul 29, 2026 by vercel[bot]
Preview – promptfiddle2 — 147a0df4 Deployed Jul 29, 2026 by vercel[bot]
Preview – beps — 147a0df4 Deployed Jul 29, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant