feat: adding portfolio taxonomies and field names#11
Conversation
…nd project_type taxonomy
There was a problem hiding this comment.
Code Review
This pull request adds a new 'Client Name' field to the portfolio field group and introduces two new taxonomies for 'Project types' and 'Software'. The review feedback highlights a critical issue where the query_var property in both new taxonomy definitions is set to a duplicate value, which will cause collisions in WordPress query resolution. Additionally, it is recommended to update the 'Softwares' taxonomy labels to use the more idiomatic term 'Software'.
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
Note
|
| Layer / File(s) | Summary |
|---|---|
Portfolio Client Name Field scf-json/group_ls_plugin_portfolio_fields.json |
Adds a new Client Name text input field (field_ls_plugin_client_name / ls_plugin_client_name) to the portfolio field group with wrapper settings, default values, placeholder text, bindings support, and input constraints. |
Portfolio Project Type Taxonomy scf-json/taxonomy-portfolio-project-type.json |
Defines a new hierarchical taxonomy ls_plugin_portfolio_project_type attached to the portfolio object type, with full admin labels, capability mappings for term and post management, public visibility, REST exposure (base: portfolio-project-type), rewrite rules, and default term configuration. |
Portfolio Software Taxonomy scf-json/taxonomy-portfolio-software.json |
Adds a new hierarchical taxonomy ls_plugin_portfolio_software with menu labels, capability-based access control, public/UI visibility, REST API registration (base: portfolio-software), hierarchical rewrite, admin column display, and default term behavior. |
Estimated code review effort
🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related PRs
- lightspeedwp/ls-plugin#6: Introduced the initial portfolio field-group and taxonomy JSON structure that this PR extends with new fields and taxonomies.
🚥 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 accurately summarizes the main changes: adding two portfolio taxonomies and one client name field configuration across three JSON files. |
| 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. |
✏️ Tip: You can configure your own custom pre-merge checks in the settings.
✨ Finishing Touches
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Commit unit tests in branch
feature/portfolio-fields-taxonomies
Tip
💬 Introducing Slack Agent: The best way for teams to turn conversations into code.
Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
- Generate code and open pull requests
- Plan features and break down work
- Investigate incidents and troubleshoot customer tickets together
- Automate recurring tasks and respond to alerts with triggers
- Summarize progress and report instantly
Built for teams:
- Shared memory across your entire org—no repeating context
- Per-thread sandboxes to safely plan and execute work
- Governance built-in—scoped access, auditability, and budget controls
One agent for your entire SDLC. Right inside Slack.
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.
Comment @coderabbitai help to get the list of available commands and usage tips.
There was a problem hiding this comment.
🧹 Nitpick comments (1)
scf-json/taxonomy-portfolio-software.json (1)
3-3: ⚡ Quick winReconsider the term "Softwares" for better grammar.
"Software" is typically an uncountable noun in English, making "Softwares" grammatically incorrect. Consider using "Software" for both singular and plural contexts (common in WordPress taxonomies), or alternatives like "Software Tools" if plural distinction is needed.
📝 Example: Using "Software" consistently
- "title": "Softwares", + "title": "Software",This pattern would apply to all label properties in lines 11-34 where "Softwares" appears (e.g.,
"menu_name": "Software","all_items": "All Software", etc.).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@scf-json/taxonomy-portfolio-software.json` at line 3, The "title" value currently uses the ungrammatical plural "Softwares"; update the JSON to use the uncountable noun form "Software" (or an alternative like "Software Tools" if you need a plural distinction) and mirror this change across all related label properties where "Softwares" appears (e.g., "menu_name", "all_items", etc.) so labels in the taxonomy object are consistent and grammatically correct.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@scf-json/taxonomy-portfolio-software.json`:
- Line 3: The "title" value currently uses the ungrammatical plural "Softwares";
update the JSON to use the uncountable noun form "Software" (or an alternative
like "Software Tools" if you need a plural distinction) and mirror this change
across all related label properties where "Softwares" appears (e.g.,
"menu_name", "all_items", etc.) so labels in the taxonomy object are consistent
and grammatically correct.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yml
Review profile: CHILL
Plan: Pro
Run ID: da9991b6-1f81-4ada-8515-feca700da439
📒 Files selected for processing (3)
scf-json/group_ls_plugin_portfolio_fields.jsonscf-json/taxonomy-portfolio-project-type.jsonscf-json/taxonomy-portfolio-software.json
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Signed-off-by: Warwick Booth <krugazul@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Signed-off-by: Warwick Booth <krugazul@users.noreply.github.com>
General Pull Request
Linked issues
Closes #
Changelog
Added
taxonomy-portfolio-project-type.json, enabling hierarchical categorization of portfolio items with REST API support and custom labels.taxonomy-portfolio-software.json, enabling hierarchical categorization of portfolio items by software used, with REST API support and custom labels.ls_plugin_client_namelabeled “Client Name” togroup_ls_plugin_portfolio_fields.jsonfor storing associated client names on portfolio items.Risk Assessment
Risk Level: Low
Potential Impact:
Mitigation Steps:
How to Test
Test Steps
Verify Project Type taxonomy
Verify Software taxonomy
Verify Client Name field
Verify REST API support
Expected Results
Edge Cases to Verify
Checklist (Global DoD / PR)
References
Summary by CodeRabbit