Skip to content

Fix createSelect() selected() documentation example - #9431

Merged
davepagurek merged 2 commits into
processing:mainfrom
pawan76542987:fix/9430-create-select-docs
Dec 2, 2026
Merged

davepagurek merged 2 commits into
processing:mainfrom
pawan76542987:fix/9430-create-select-docs

Conversation

@pawan76542987

Copy link
Copy Markdown
Contributor

Resolves #9430

Changes

  • Fixed the createSelect() documentation example to pass the option value (red) instead of the label (one) to selected().
  • Updated the accompanying comment to clarify that selected() accepts the option value.

No changes were made to the actual function implementation.

Testing

  • Reproduced the reported behavior and verified the correct selection using the p5.js Web Editor (v2.3.4).
  • npm run lint: 0 errors, 44 warnings.
  • npm run docs: Completed successfully.
  • git diff --check: Passed.
  • Unit tests: 2,987 passed, 1 failed.

The WebGPU shader test failure was also reproduced on the unchanged code, confirming that it is unrelated to this documentation change in my local environment.

AI Usage Disclosure

I used ChatGPT for guidance in understanding the issue, suggesting the documentation correction, troubleshooting tests, and preparing the PR. I reviewed the changes and performed the verification locally.

PR Checklist

  • npm run lint passes
  • Inline reference is updated

No new unit tests were added because this is a documentation-only change.

@davepagurek davepagurek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update!

@p5-bot

p5-bot Bot commented Dec 1, 2026

Copy link
Copy Markdown

Continuous Release

CDN link

Published Packages

Commit hash: ed81059

Previous deployments

This is an automated message.

@davepagurek
davepagurek merged commit f07abf5 into processing:main Dec 2, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[p5.js 2.0+ Bug Report]: createSelect().selected() documentation incorrect

2 participants