WordPress / WordPress/secure-custom-fields
Port ACF's schema select2 dropdown JS so GEO pickers get the styled dropdown
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 131
- Forks
- 64
- Avg merge
- 10m
- Merged PRs (30d)
- 1
Description
What
SCF's GEO feature (src/AI/GEO/FieldSettings.php, gated by enable_schema) renders the Schema.org Property and Schema.org Output Format selects with 'ui' => 1, but the select2 dropdowns render unstyled: upstream tags them with schema-property-select-results / schema-output-format-select-results / schema-type-select-results dropdown classes (plus a "Type to search…" placeholder) from assets/src/js/_acf-internal-post-type.js, and SCF's copy of that file predates the schema code entirely.
Why now
#506 synced the sass partials from ACF 6.8.5, so the CSS for those dropdown classes (_admin-inputs.scss) already ships — it's just inert until the JS applies the classes. Porting the JS lights up the styled dropdown with zero further CSS work.
Where upstream has it
Free ACF repo, tag 6.8.5, assets/src/js/_acf-internal-post-type.js (~lines 60–110): a select2_args filter that sets dropdownCssClass for the schema selects, and a select2_init action that sets the search placeholder.
Acceptance
With enable_schema on, opening the Schema.org Property / Output Format dropdowns in the field settings shows the field-type-picker-style dropdown (rounded, shadowed, styled search) instead of the generic select2 look.
Found while reviewing #506 (the "Schema/GEO picker styles" family of its CSS delta is currently inert).
🤖 Generated with Claude Code
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with assets/src/js/_acf-internal-post-type.js and compare it with the same file in the ACF 6.8.5 tag, focusing on the schema-related select2 behavior around lines 60–110. Confirm the local field-settings selectors use the existing schema dropdown classes and search placeholder behavior. Done means that, with enable_schema enabled, the Schema.org Property and Output Format dropdowns display the styled field-type-picker UI.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 88/100